Contribute
Register

[Solved] Problem with Mail Search in Sierra after 10.12.4 upg

Status
Not open for further replies.
Joined
Nov 12, 2013
Messages
25
Motherboard
GA Z87MX-D3H
CPU
Intel i7-4770k
Graphics
Nvidia GTX 780 3GB
Mobile Phone
  1. iOS
Hi to all,

I'm facing the problem with the lack of search feature inside the Mail App in MacOS Sierra after updating to the 10.12.4.

I've searched the net and found several solutions, including removing 'envelope' files and rebuilding databases.
Also resetting the spotlight search too.

I even deleted the account and recreated it, with no success at all, including another user that I have on the machine, created during the OS installation, prior to the migration of my own user from TimeMachine backup.

Does anyone have any suggestions/solutions?

Thanks in advance.

JG
 
I have the same problem
 
Hi to all,

I'm facing the problem with the lack of search feature inside the Mail App in MacOS Sierra after updating to the 10.12.4.

I've searched the net and found several solutions, including removing 'envelope' files and rebuilding databases.
Also resetting the spotlight search too.

I even deleted the account and recreated it, with no success at all, including another user that I have on the machine, created during the OS installation, prior to the migration of my own user from TimeMachine backup.

Does anyone have any suggestions/solutions?

Thanks in advance.

JG
Hi, I wonder if you found a fix for this? I have tried everything bar a clean system install.
 
Hi, I wonder if you found a fix for this? I have tried everything bar a clean system install.

Hi, unfortunately no, and me too everything but a clean install.
I moved to use Postbox, since its a bit better than Thunderbird, but its paid.

Cheers.
 
Thanks for the speedy reply. Wow, I just tried this and it WORKED! In Terminal

Turn off indexing
sudo defaults write /Library/Preferences/com.apple.security.appsandbox UnrestrictSpotlightContainerScope -bool true

Then turn it on, and give it a minute
sudo mdutil -a -i on
 
Thanks for the speedy reply. Wow, I just tried this and it WORKED! In Terminal

Turn off indexing
sudo defaults write /Library/Preferences/com.apple.security.appsandbox UnrestrictSpotlightContainerScope -bool true

Then turn it on, and give it a minute
sudo mdutil -a -i on

My dear friend,
After so many months you're a life saver.
Based on your findings I was able to sort it out.
For some reason, my '/' was disabled for indexing, so when I ran your commands I got:

$ sudo mdutil -a -i on
/:
Indexing and searching disabled.
/Volumes/Mav2:
Indexing enabled.

So, I have it on the 2nd disk but not on mi primary...

I found another blog post, I think I can't post the link for it, I'll reproduce the steps I took for enable it, mention, I have previously removed all drives from "System Preferences->Spotlight->Privacy", as that was already done on previous atempts.

Bold is for my comments
So I ran this on Terminal:

$ locate .metadata_never_index

Got this message:
WARNING: The locate database (/var/db/locate.database) does not exist.
To create the database, run the following command:


sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.locate.plist

Please be aware that the database can take some time to generate; once
the database has been created, this message will no longer appear.

I run the command suggested:
sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.locate.plist

Then run again:
sudo locate .metadata_never_index

Was found on:
/.metadata_never_index

Then I run:
sudo rm -rf /.metadata_never_index

Then:
sudo mdutil -i on /

Resulting in:
/:
Indexing enabled.

Conclusion:
I opened mail app, and done a search and this time it return result for the email addresses, SO A BIG TAHNK YOU for the answer.
I swear that I have searched a lot on this, and for somehow I didn't found the correct answer for it, until you pointed to the right direction.

Many thanks and best regards.
JG
 
My dear friend,
After so many months you're a life saver.
Based on your findings I was able to sort it out.
For some reason, my '/' was disabled for indexing, so when I ran your commands I got:

$ sudo mdutil -a -i on
/:
Indexing and searching disabled.
/Volumes/Mav2:
Indexing enabled.

So, I have it on the 2nd disk but not on mi primary...

I found another blog post, I think I can't post the link for it, I'll reproduce the steps I took for enable it, mention, I have previously removed all drives from "System Preferences->Spotlight->Privacy", as that was already done on previous atempts.

Bold is for my comments
So I ran this on Terminal:


$ locate .metadata_never_index

Got this message:
WARNING: The locate database (/var/db/locate.database) does not exist.
To create the database, run the following command:


sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.locate.plist

Please be aware that the database can take some time to generate; once
the database has been created, this message will no longer appear.

I run the command suggested:
sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.locate.plist

Then run again:
sudo locate .metadata_never_index

Was found on:
/.metadata_never_index

Then I run:
sudo rm -rf /.metadata_never_index

Then:
sudo mdutil -i on /

Resulting in:
/:
Indexing enabled.

Conclusion:
I opened mail app, and done a search and this time it return result for the email addresses, SO A BIG TAHNK YOU for the answer.
I swear that I have searched a lot on this, and for somehow I didn't found the correct answer for it, until you pointed to the right direction.

Many thanks and best regards.
JG
Thanks for the tip. I was having the same problem with 10.12.5 and the first few 10.12.6 PB. BTW, search was broken in Apple Mail and Outlook. I went through almost all of the fixes described above (except creating and then deleting .metadata_never_index), with no luck. However, with the latest 10.12.6 PB, search started working again. It would appear that somehow the .metadata_never_index file or flag gets messed up, so will keep this in mind if it happens again.
 
sudo mdutil -a -i on
I had suddenly encountered problems with Mail not searching, and almost all mailboxes (VIPs, Flagged, etc.) went empty and non-responsive, on El Capitan, prior to updating to 10.12.6--don't know why...
Tried many 'fixes' shown in different forums--then I thought to look here.
I should have come here FIRST!
ANYWAYS,

THANK YOU! ;)
the 'turning back on' via

sudo mdutil -a -i on

after the "sudo defaults write /Library/Preferences/com.apple.security.appsandbox UnrestrictSpotlightContainerScope -bool true"

...JUST Works; other posts in other places (e.g., Apple ETC.) merely had the first command--which obviously doesn't work to enable search/index. Apparently, Mail uses Spotlight searching (who woulda thought...?)

Anyways, after rebuilding and fiddling for days, your solution did indeed allow search again in MAIL...and Spotlight shows Mail messages again...
thx bro.
 
Last edited:
Thanks for the speedy reply. Wow, I just tried this and it WORKED! In Terminal

Turn off indexing
sudo defaults write /Library/Preferences/com.apple.security.appsandbox UnrestrictSpotlightContainerScope -bool true

Then turn it on, and give it a minute
sudo mdutil -a -i on
HI There,

THANX A LOT

I solved to with your procedure. I have Mojave, the spotlight worked perfectly, only if I searched an email in the Mail App I didn't find anythin (blank). Now after it, The Mail App works perfectly.

WOW
CIAO
 
Status
Not open for further replies.
Back
Top