Tuesday, March 18, 2008

Mounting Linux NFS shares in Solaris 10

First, export a filesystem on your Linux box (add it to the exports file, and exportfs). Make sure the kernel-nfs server service is started.

# /etc/init.d/nfs-kernel-server start
Edit your exports file:
# ed /etc/exports
i
/home/cmihai 192.168.1.13/24(rw,no_root_squash,subtree_check,async)
w
q
Export the filesystem:
# exportfs
/home/cmihai 192.168.1.13/24
# showmount -e
Export list for loonix:
/home/cmihai 192.168.1.13/24

On your Solaris 10 box, run:
# showmount -e loonix
export list for loonix:
/home/cmihai 192.168.1.13/24
It should give you results consistent with the results you got on your Linux machine.
Trying to mount the share as NFSv4 will fail (Linux NFSv4 isn't compatible with Solaris NFSv4).
# mount loonix:/home/cmihai /storage
nfs mount: mount: /storage: Not owner
So we're going to mount the share as NFSv3:
# mount -o vers=3 loonix:/home/cmihai /storage
# mount
/storage on loonix:/home/cmihai remote/read/write/setuid/devices/vers=3/xattr/dev=4840010 on Tue Mar 18 14:59:06 2008

5 comments:

The Chopper said...

I ran into the same problem and the above didn't help. However, the problem and it's cure are quite nicely explained here (setting sec=sys was the only option I was missing):
http://blogs.sun.com/tdh/entry/some_nasty_nfsv3_interactions_at

Cheers

Anonymous said...

Nice post.. it helped. I didn't click on any of your ads though.

Cheers!

cmihai said...

There should be no ads on the site (at least none that I enabled). Check for adware? :-).

Kevin said...

I was very glad to find this post. Even though it was from 2008, it solved my problem.

Thanks

sugarboy said...

Is it possible to mount NFS soft link on Solaris? am getting error "No Such or Directory exists" when tried?