Windows 7 Search Problem Solved!!!

Daniel Q. Naiman - 6/22/2010


When I switched over to Windows 7 about a year ago, I soon found that one key feature I was interested in making use of, the index search, didn't work as expected. I would search for certain files I knew existed in my Documents folder/library but these files would not be found. I searched the internet for fixes to the problem, followed all of the standard instructions I could find, including rebuilding the index, trying windows troubleshooting, etc etc., all to no avail.

Recently I discovered the source of the problem by comparing the permissions of a folder in Documents that was searchable with one that was not. It appears that in order for the search tool to work for a given folder/file, the "SYSTEM" user needs to have read access to that file. I haven't found any online documentation that explains this requirement, so I thought it would be helpful to make this fix available to others by publishing this web page.

The fix below was worked out with the help of Sancar Adali, a graduate student here at Johns Hopkins Applied Mathematics and Statistics department.

CAVEAT: I am not an IT professional. This works/worked for me, but it is possible that this "fix" will affect your system in ways that I do not completely understand.

Open a command prompt, navigate to the folder that contains the folder (called "foldername" here) you want to be searchable, and give the command:

icacls foldername /T /grant SYSTEM:(R)

Here we are granting read permission (hence the (R)) to user named "SYSTEM". The /T causes the changes to be made recursively in the folder called "foldername" and all of its subfolders.

I found that before this step I had to run "takeown" to take ownership of certain files and folders, so you might have to precede the above command by doing the following:

Start up a command terminal as Administrator (go to All Programs -> Accessories and right click on Command Prompt)

Navigate to the folder that contains the folder you with to take ownership of

Type the command:

takeown /F foldername /R

(Here the /R causes the changes to be done recurisively in the folder called "foldername" and all of its subfolders.)

Hopefully, people needing a solution to this annoying problem willl find this beneficial.