Google Plus

Make NFS in RHEL/Centos and Fedora

Written by Mel Kham on . Posted in Linux tutorials

This tutorial shows you how to use nfs successfully, you have to configure the server and the client. In this example, the client is 10.10.0.3 and the server is 10.10.0.1. The folder to be shared is

 

/home/sharing, and to be mounted to /mnt on the client

On the server

1: make   this  diretory :

[root@unixmen_net ~]# mkdir /home/sharing

2:Edit /etc/exports, insert the client computer  ip

 vi /etc/exports

and  add  this line:

/home/sharing 10.10.0.3/255.255.255.255(rw,sync)

 save  and  exit

3:  Edit /etc/hosts.allow

vi  /etc/hosts.allow

add  :  portmap: 10.10.0.0/255.255.255.0

save  and  exit.

 4:  start nfsand  portmap :

[root@unixmen_net ~]#  /etc/init.d /nfs start

[root@unixmen_net ~]#  /etc/init.d /portmap start

On the client

 start 

/etc/init.d/portmap start

Mount the nfs folder

mount 10.10.0.1:/home/sharing /mnt

 Check /var/log/messages for any error that might occur

tailf /var/log/messages

Use mount to check if the folder is mounted properly

the  output  should  be  like :

10.10.0.1:/home/sharing on /mnt type nfs (rw,addr=10.10.0.1)

Edit /etc/fstab to mount the shared folder on boot  :

vi /etc/fstab

add

10.10.0.1:/home/sharing mnt nfs rw,hard,intr 0 0

 save  and  exit .

 Voila :”)

 

 Greets unixmen team 

 You can post your comment for this article below , we want to inform you that we don`t answer the comments , issues and problems please report them on the forum.

 

For questions please refer to our Q/A forum at : http://ask.unixmen.com

Mel Kham

Founder of Unixmen, Living in Amsterdam. Am working in my free time to help people to understand the Opensource and to explain them in easy way how to make the fist steps to the the light. Working day and night with my Co-founder Zinovsky to keep this website live even with less resources.

Like us on Facebook

This week Top Posts

Write for us

Recent Comments

Lolman

|

in cmd

Oliver

|

Do you think that it works on a Macbook Air 1,1?… ohh and, it must be installed in a different partition than Mac OS X, right?… can´t have i installed only Ubuntu on my hard drive?

Nova

|

I wonder if there is a way to create your own themes.

Red Adaya

|

Thank you! This worked for me!!!

 
IDG Tech Network
Copyright © 2008-2013 Unixmen.com .
Maintained by Anblik .