spotlight_如何通过重建索引来解决Spotlight问题

当Spotlight在Mac上表现不佳,如搜索结果消失、不准确或出现重复时,可以尝试重建其索引。操作包括将硬盘驱动器添加到Spotlight隐私设置,然后移除以触发重新索引,或在终端中输入命令手动重新索引。
摘要由CSDN通过智能技术生成
spotlight

spotlight

Is Spotlight being a little wonky on your Mac? Is it constantly indexing your drive, or become corrupted so it can’t search? With just a few quick steps, you can rebuild your Spotlight index and put your search woes to rest.

在Mac上,Spotlight有点不实用吗? 是不断索引您的驱动器,还是损坏了它以使其无法搜索? 仅需几个简单的步骤,您就可以重建Spotlight索引并消除搜索的麻烦。

Spotlight is great for finding stuff on your Mac, and once your learn how to use it, can quickly make short work of any search. But there are a lot of things that can make it go wonky. In such a case, the first thing you should do is reindex your hard drive, which means deleting the old index so Spotlight can crawl through your hard drive and re-catalog everything on it.

Spotlight非常适合在Mac上查找内容, 一旦您学会了如何使用它 ,就可以快速完成任何搜索工作。 但是,有很多事情可以使它变得古怪。 在这种情况下,您应该做的第一件事就是为硬盘驱动器重新索引,这意味着删除旧索引,以便Spotlight可以在您的硬盘驱动器中爬行并重新编录其中的所有内容。

There are a few reasons you may need to rebuild your Spotlight index. These include:

出于某些原因,您可能需要重建Spotlight索引。 这些包括:

  • Search results simply aren’t working, such as if search results disappear as you type in a name.

    搜索结果根本无法正常工作,例如,当您输入名称时搜索结果消失了。
  • Search results aren’t appearing even though you know for sure the files exist on your system.

    即使您确定系统上存在文件,也不会出现搜索结果。
  • You’re getting duplicate results and you’re certain you only have one instance of a file.

    您得到重复的结果,并且确定您只有一个文件实例。
  • You get conflicting data on how much hard drive space is being used and how much is available.

    在使用多少硬盘空间和多少可用空间时,您会得到相互矛盾的数据。
  • When you search for items and you get different results each time, using the same search query.

    搜索项目时,每次使用相同的搜索查询都会得到不同的结果。

If any or all of these things are happening, then it might be time to dump your old Spotlight index and start fresh. Like we said, this is really easy and shouldn’t take too long though that will depend entirely upon the speed of your system and the number of files.

如果这些事情中的任何一个或所有正在发生,那么可能是时候转储旧的Spotlight索引并重新开始了。 就像我们说的那样,这确实很容易,应该花很长时间,尽管这将完全取决于系统的速度和文件的数量。

To begin, first open the System Preferences and click on Spotlight, or open it from the Apple menu.

首先,首先打开系统偏好设置,然后单击Spotlight,或者从Apple菜单中将其打开。

In the Spotlight preferences, click on the “Privacy” tab. You may already have items here, but as you see in the following screenshot, ours is empty. Now, drag your hard drive onto the Privacy window.

在Spotlight偏好设置中,点击“隐私”标签。 您可能已经在这里有项目,但是如下面的屏幕截图所示,我们的项目为空。 现在,将硬盘驱动器拖到“隐私”窗口中。

Alternatively, if you want to simply reindex a folder or another volume, you can drag that over instead. For our purposes, however, we’re going to reindex our entire main system drive.

另外,如果您只想为文件夹或另一个卷重新编制索引,则可以将其拖移。 但是,出于我们的目的,我们将重新索引整个主系统驱动器。

When you attempt to add your system drive (or any other folder or volume), you’ll receive the following prompt. Go ahead and click “OK”.

当您尝试添加系统驱动器(或任何其他文件夹或卷)时,会出现以下提示。 继续并单击“确定”。

Now that your system drive is added to Spotlight’s Privacy window, it won’t be allowed to show you results from it and should remove them from the index. The next thing you then need to do is click the “-” at the bottom of the Privacy tab.

现在,您的系统驱动器已添加到Spotlight的“隐私”窗口中,将不再允许它显示结果,因此应将其从索引中删除。 接下来需要做的是单击“隐私”选项卡底部的“-”。

Doing this will cause Spotlight to reindex your entire drive and you should now hopefully start receiving accurate search results.

这样做将导致Spotlight重新索引整个驱动器,现在您应该希望开始获得准确的搜索结果。

If this doesn’t work, you can try spurring it to reindex manually. First open a Terminal window from the Applications > Utilities folder and type in the following command.

如果这不起作用,则可以尝试促使其手动重新编制索引。 首先从“应用程序”>“实用程序”文件夹中打开“终端”窗口,然后键入以下命令。

sudo mdutil -E /

You will be prompted to enter your system password. Once you do so, hit “Enter” and Spotlight should be reindexed.

系统将提示您输入系统密码。 完成后,点击“ Enter”,Spotlight应该重新编制索引。

Hopefully once done, Spotlight will start to return accurate results and your search woes will be a thing of the past.

希望一旦完成,Spotlight将开始返回准确的结果,而您的搜索难题将成为过去。

翻译自: https://www.howtogeek.com/246664/how-to-fix-spotlight-problems-by-rebuilding-the-index/

spotlight

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值