From 0e8152b651a0f05744f6abad6f05b2a62be15778fa37342942ed5975b9b7ff13 Mon Sep 17 00:00:00 2001 From: kappuchino Date: Mon, 27 Jan 2025 17:18:38 +0000 Subject: [PATCH] Added the Tips --- MacOS-Spotlight-Tips.md | 45 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 MacOS-Spotlight-Tips.md diff --git a/MacOS-Spotlight-Tips.md b/MacOS-Spotlight-Tips.md new file mode 100644 index 0000000..193a329 --- /dev/null +++ b/MacOS-Spotlight-Tips.md @@ -0,0 +1,45 @@ +## Commands + +Disable the index: + + mdutil -i off / + +Enable the index: + + mdutil -i on / + +Erase the current Spotlight index: + + mdutil -E / + +## Help + + Usage: mdutil -pEsa -i (on|off) -d volume ... + Utility to manage Spotlight indexes. + -p Publish metadata. + -i (on|off) Turn indexing on or off. + -d Disable Spotlight activity for volume (re-enable using -i on). + -E Erase and rebuild index. + -s Print indexing status. + -a Apply command to all volumes. + -V vol Apply command to all stores on the specified volume. + -v Display verbose information. + NOTE: Run as owner for network homes, otherwise run as root. + +## Sources: + +* http://developer.apple.com/library/mac/#documentation/Darwin/Reference/ManPages/man1/mdutil.1.html +* http://www.mikesel.info/disable-spotlight/ +* http://osxdaily.com/2007/03/22/how-to-completely-disable-spotlight/ + +## Special files: + +There is a thorough recent non-ai article here: https://eclecticlight.co/2024/07/09/excluding-folders-and-files-from-time-machine-spotlight-and-icloud-drive/ + +### Special Files still working in Sequoia + +* Ending an file or folder in `.noindex` will disable indexing of the folder. Example `mkdir private-folder.noindex`. In former times it was .no_index, so beware the change. Similar is .nosync for keeping files out of sync with icloud. + +### Special Files working until ventura +* On the root `/` directory of a internal or external Volume `.metadata-never-index` will turn of indexing for the whole drive. Use the terminal to `sudo touch \.metadata-never-index` for the root drive. Or use `\Volumes\NAMEOFVOLUME\.metadata-never-index` for another drive. +* On the root `/` directory of a (competing) boot drive with a version of OS X you can intelligently disable indexing by using `.metadata_never_index_unless_rootfs` to prevent the data from the drive to appear unless it is the boot drive. Use the terminal to `sudo touch \.metadata_never_index_unless_rootfs`. Or use `\Volumes\NAMEOFVOLUME\.metadata_never_index_unless_rootfs` for another drive.