Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

NFS - how to share a directory

Status
Not open for further replies.

gfunk123

IS-IT--Management
May 22, 2001
143
GB
I am setting up some additional space on a remote server for one of the users - I am quite new to solaris and have been advised to 'create a directory , share it ready for mounting and then mount it from the client machine.

I am fine with creating the directory and even the last step of mounting the folder on the clients fs, but how the hell do I share the foder, is there a command to do this ? do I need to do this at all?.

If anybody knows the commands that would be great

thanks
 
Well to make it permanent you will probably want to make an entry in your /etc/dfs/dfstab on the server that is sharing, and in the /etc/vfstab in the one that will be mounting it. Those changes won't take place until the next boot. To do it one time from the command line is through the share command on one server and mount on the other. Check out the man pages on share, dfstab and vfstab.
 
Something to watch for...

If you are going to share it using autofs
(automounting) do not put an entry in /etc/vfstab. This could cause problems.


Jamie
 
Use "share" command to share the folder on your solaris machine. To permanantly share a folder (after each reboot), u have got to add the FS entry in /etc/dfs/dfstab file and on each client, addd the FS entry to /etc/vfstab file.

Cheers!

Hemant
 
Hi try this,

# vi /etc/dfs/dfstab

share -F nfs -o rw -d "home dirs" /export

#wq!

#/etc/init.d/nfs.server stop
#/etc/init.d/nfs.server start

On client machine,

#mount systemname:/export /mnt (mount point on client)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top