查询任意卷宗的聚焦(Spotlight)索引状态(mdutil -s)

检查系统盘或外接硬盘的聚焦索引是已启用、已停用还是正在建立。

macOSmacOS搜索聚焦搜索磁盘低风险
运行 mdutil -s /(外接盘用 mdutil -s /Volumes/磁盘名),输出会显示索引是否启用及重建进度。

01命令

命令
$ mdutil -s / && mdutil -s /Volumes/ExternalDisk

02作用说明

mdutil -s 会报告每个卷宗的聚焦状态:'Indexing enabled' 表示搜索应该可用,'Indexing disabled' 表示该卷不会被搜索,若刚启用或刚插入硬盘,还会显示正在建立索引的进度行——这就是搜索不到结果的原因。排查时应先看状态,再考虑重建:关闭/开启索引(mdutil -i off/on)或抹掉重建(mdutil -E)都需要 sudo,且会触发耗时的全盘重新抓取。

03风险

风险低风险

04撤销

✓无需撤销——该命令不会改变持久状态。

05来源

  • mdutil - Manage Spotlight indexer store
    SS64 · technical · 2026-09-17
    依据: Documents `-s`: 'Display the indexing status of the listed volumes', with the volume (e.g. / or /Volumes/Name) as the argument.
  • mdutil(1) man page
    Xcode Man Pages (keith.github.io) · technical · 2026-09-17
    依据: Man page for mdutil listing the -s flag: show the indexing status of the given volume, including whether it is enabled or disabled.

最后验证: 2026-09-19 · 分类: 文件与文件夹

06相关方案