Recently an mdworker
process was pegging my CPU and cooking my lap.
From its man page description: "mdworker is the metadata server worker process. It is used by mds to scan and index files as a volume is mounted or a file changes."
What's mds
? "mds is the metadata server. It serves all clients of the metadata APIs, including Spotlight."
mdfind
uses the builtin metadata index and can be a faster alternative to recursive grep
or find
and an easy way to search all the files on a mac (assuming the index is up to date):
$ find . -name '*.js'
$ mdfind -onlyin . -name .js
$ grep -Rl window *
$ mdfind -onlyin . window
Some Links: