Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Spotlight: How to Index an AFP Share Point

The following example details how to index a share point named "share" for Spotlight searching.

1. Log in to a client computer as a local administrator.

2. Mount share via Connect to Server by a user who has read & write access to the share point.

3. Open Terminal and issue sudo -s then the following commands as root:

a. Create the index for the share point: mdutil -i on /Volumes/share

b. Publish that index so that it resides on the share point: mdutil -p /Volumes/share

4. Unmount share. Then ssh into your server as root and switch to the path for share. Use chmod and chown to set the permissions of the .Spotlight-V100 folder accordingly:

chown -R root:admin /<path to>/share/.Spotlight-V100
chmod -R 755 /<path to>/share/.Spotlight-V100

5. Now remount the share and test a Spotlight search.

Note that this procedure does not work for static network automounts (to /private/var/automount/Network, the Network globe in the Finder) with Mac OS X 10.4 and 10.4.1.

--Gerrit DeWitt
Apple Certified System Administrator

Posted on Jun 2, 2005 8:27 PM

Reply
18 replies

Jul 27, 2005 3:52 AM in response to Gerrit DeWitt

Hmm,

I wonder why Apple leaves us with a command-line "switch on for shared volumes", which has to be explained by very tech-savy users and is not so easy to understand, if you are not very familiar with the terminal.

As for myself, I would expect a GUI-Click at least, or a "indexing on on all shared volumes for clients by default".

Strange, strange: For "decades" we were hating Microsoft, for their Un-GUI-Windows-Quirks and now we are more and more loving Apple for going the same way... :-/

Sorry, I dont want affend anyone, but these things (Apple Quirks) annoy me

my two cents
Rob

Aug 3, 2005 2:03 PM in response to O-|

So far, no, I have found no way to have Spotlight search a static automount, even if it is first indexed with the procedure outlined above.

I think the problem lies with the static mount method. In Tiger, all static mounts appear to be accessed by Guest on the server, which is expected; however typing "mount" at the Terminal on a client shows that the static mounts are mounted by the currently-logged in user. (This looks like masked AFP permissions as if you would simply connect to a server volume. That is, the currently-logged in user, either local or in a directory domain, is the owner of the mount point for any connected-to share point.) The exception is that /Network/Library appears to be mounted as securityagent (UID 92); so I think there's some strange masking going on with shared Libraries, new to Tiger.

Spotlight will search dynamic automounts, such as those that contain a network-based home.

--Gerrit

Aug 4, 2005 8:08 AM in response to P. Savelberg (DKV)

The metadata server process (mds) running on your server will keep the Spotlight index of the share point up-to-date when new files are added. This requires that your server be running Mac OS X Server 10.4 (version 10.4.2 recommended).

When correctly configured, you can search share points via the Spotlight menu or via the Finder's find field.

--Gerrit

Aug 9, 2005 6:09 PM in response to P. Savelberg (DKV)

Patrick:

I'd check the following:

1. List the share point's contents with "ls -a": do you have the .Spotlight-V100 folder therein? Is root the owner of the folder and can root read and write?

2. With Mac OS X Server 10.4, indexing is disabled for any mount points in /Volumes/* by default, so mdutil -s /Volumes/* should return an "Indexing Disabled" message. Even so, you should have a "mds" process running as root on the server.

3. Have you tried a search of the share point in question? (The mdutil might be returning a disabled message incorrectly.)

4. Log out all users on the client and only log in as one user at a time. I've had trouble with some Spotlight searches when more than one user is logged in simultaneously via Fast User Switching.

5. Sometimes the client-side mds process stops responding with Mac OS X 10.4 and 10.4.1. Fortunately, the Mac OS X 10.4.2 update has increased the reliability of same in my experience.

6. Make sure you're using Mac OS X Server 10.4.2 as well. Version 10.3 and earlier doesn't have a server-side mds process to update the index.

Hope this helps. Let me know... 🙂

--Gerrit

Aug 11, 2005 6:57 AM in response to Gerrit DeWitt

Hi Gerrit,

Here are the results .. 🙂
1) sharepoint : drwxr-xr-x 13 root admin 398 Aug 11 12:23 .Spotlight-V100 --> so no problem

2) yes it is running

3) tryed for search, but only just after indexing it works with the search field not with the spotlight icon

4) done .. no result

5) Running 10.4.2

6) Server runs 10.4.2 Server version

So if i do the trick it only works for a moment .. not the whole time ...

Tryed trashing .spotlight trashing with mdutil -E .. and start over again ...

I think we have to wait on 10.4.3 ... or something .. 😟

Aug 25, 2005 1:39 AM in response to P. Savelberg (DKV)

New Try, same result ....
My Sharepoints and disk have spaces in de name ..Is it possible that is causing the problems .. ?

In thes spotlight menu it is not working, only in the search bar when i selct te server ...

All commands where excuted without any error's
So what is going wrong ..? It would be very handy if it works ....

Spotlight: How to Index an AFP Share Point

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.