Steps to configure a NFS server

quarta-feira, 11 de janeiro de 2012

It's necessary few steps to configure your NFS server

Edit this file to enable the NFS auto startup:

#vi /etc/rc.config.d/nfsconf

Start the NFS server:

# /sbin/init.d/nfs.server start

Edit the follow file as the example adding the directories that will be shared:

#vi /etc/exports

/Directory -access=server1:server2:serverN
-access=server1:server2:serverN: Those are the servers who are able to access it.

Now refresh your changes in your shared list:

# exportfs -a

Check the shared file list:


Others NFS useful commands:

Shared a file directly (without add it in the  /etc/exports), if the server reboot it won't shared it again
# exportfs -i /directory

Unexport a specified directory:

# exportfs -u /directory

Stop the NFS server:

# /sbin/init.d/nfs.server stop