Ubuntu + NFS

June 24th, 2008  | Tags:

I’ve moved my Ubuntu webserver to a VMWARE platform, as i’ve done this i now have a spare machine, with 3 hdd’s in it.  So i figured i’d use this as a backup server.  now what’s the best way to do this?  samba? rsync over ssh?  Nah i’m going to use NFS.  Here’s how i did it.  Thanks to Ubuntu Geek

On the Server

  1. sudo apt-get install nfs-kernel-server nfs-common portmap
  2. make a folder where you want to mount, mine was /backup_nfs
  3. sudo vi /etc/exports
  4. add the line - /backup_nfs 192.168.1.1/24(rw,no_root_squash,async)   obviously change your IP range and backup folder location
  5. sudo /etc/init.d/nfs-kernel-server restart
  6. sudo exportfs -a  [ you need to run this every time you add something to /etc/export

On the Desktop/Other Server

  1. sudo apt-get install portmap nfs-common
  2. sudo mount <ipaddress>:/backup_nfs /backup_nfs
  3. Alternatively you can add the following to the /etc/fstab and then reboot - <ipaddress>:/backup_nfs /backup_nfs nfs rw 0 0
No comments yet.


TOP