// you’re reading...

Technology

Linux NFS and Heartbeat Tutorial

This is a great tutorial: http://www.howtoforge.com/high_availability_nfs_drbd_heartbeat

However, if you wanna setup a simple NFS configuration, here are the steps. I’ll break it down to SERVER and CLIENT. For the sake of this tutorial, we’ll assume we’re on the 10.0.10.0/24 LAN. We’ll also assume the following info:
10.0.10.10 server1 (IP & host name for SERVER)
10.0.10.11 client1 (IP & host name for CLIENT)

SERVER
#service nfs start
#mkdir /exports
#mkdir /exports/www
#echo "Can you read this" > /exports/www/test.txt
#chmod -R o+w /exports/www
#vi /etc/hosts

Add the client and server to this file. Enter these lines:
10.0.10.10 server1
10.0.10.11 client1
#vi /etc/exports
Enter this line:
/exports/www 10.0.10.0/24(rw)
#exportfs -a

CLIENT
#vi /etc/hosts
Add the client and server to this file. Enter these lines:
10.0.10.10 server1
10.0.10.11 client1
#mkdir /home/www
#mount server1:/exports/www /home/www -o rw

That should do it. Please comment as you see fit.

Discussion

One comment for “Linux NFS and Heartbeat Tutorial”

  1. Hmm should mention that only clients on 10.0.10.0/24 have access, and the client doesn’t NEED to have the client ipaddress in the hosts file.

    Posted by wenzi | March 8, 2007, 4:21 am

Post a comment