Solaris, NFS & OS X

At home I use ZFS+NFS on a Solaris box to make a file server that provides disk space to all the other machines at home, which are mostly MACs. I use NFS to access the files instead of AFS because it's so much faster. A friend and I were talking about this over the weekend and he was surprised: OS X is notoriously tricky to configure to use NFS. They have a nonstandard way to manage automount maps and, unusual for Apple: no easy-to-use front end. So lots of folks stay away from using NFS on OSX. It turns out that there's a trick that not many folks know about that makes it easy: (almost) no configuration required. The default NFS configuration contains a default automount map based on hostnames: /net/hostname/filepath. The tricky bit is that the finder suppresses the "/net" directory so you can only see it from the Unix shell. From the shell on OS X, /net references work with no effort:
ls /net/10.0.0.123/tank/photos
Lists all the files in /tank/photos on the host with IP address 10.0.0.123 (if you're feeling adventurous, you can associate a name with the address by appropriate configuration of the naming environment, but that can be a pain, so I often just use naked static addresses). To make this work with finder in OS X, just do this from the shell:
sudo ln -s /net/10.0.0.123 /tank
Then "tank" will show up on the root filesystem, and "photos" will be visible within it. The only configuration I do is this one symlink, then all the filesystems on the server appear. Easy.
Comments:

Excellent. Thanks for the tip. I just tried it at home and that works fine for me exchanging between OpenSolaris and iMac

Posted by Dominique Merle on October 06, 2008 at 05:52 AM PDT #

The biggest "gotcha" for NFS on OS X is that the automounter is basically broken except in Leopard.

For NFS automounts, Leopard implements autofs, and not surprisingly is based on the OpenSolaris "fork:"

http://managingosx.wordpress.com/2007/12/11/autofs-in-leopard/

My favorite part about Leopard Server automounts? They're resharable. Why do I care? Well, AFP is basically an "Apple only" play (yeah, I'm aware of Helios and other providers - not worth the effort or expense). Also, Solaris' integration with Active Directory is dicey. Apple's OD plugin for Active Directory is well implemented (despite all the headaches we had back in early 10.3 days).

I'd love to use Samba to share our X4500 SAMFS volumes, but AD integration just doesn't work. However, if I share this via NFS to our Xserves, then reshare from there, it works well (we have 10GigE and LACP everywhere).

Posted by Charles Soto on October 06, 2008 at 06:28 AM PDT #

Actually, there is a graphical utility to manage NFS mounts on Mac OS X (Leopard). Its the Directory Utility in Applications > Utilities.

Posted by veri on October 06, 2008 at 09:48 PM PDT #

And here I thought everything on OS X "just worked"?

Posted by Wise To Apple on October 06, 2008 at 11:47 PM PDT #

Psst...MAC..O..SuX! Like, HP...sUX! And, LIN...sUX! And, ArmanI...suX! You get the picture....I created Sun, just for such a reson....Because, I've tried EVERYTHING, and Sun was the best. SOLARis BEST! Get it? Grok it? :) Don't make have to come to HQ and kick your butt. :) SuNNDMT File System. codename: NFS. Perhaps, we'll meet, again, some day, in person. :) Hint: We've already passed, met, each other, a million times, already. :)

Posted by TheSunInventor on October 09, 2008 at 04:22 AM PDT #

You can also select "Go to folder" from the Finder's Go menu and type "/net/foobar" if you like.

Posted by Boob on October 11, 2008 at 01:20 PM PDT #

Post a Comment:
Comments are closed for this entry.
About

jag

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today