How To:Backup Partitions Mounted via NFS

From wiki.zmanda.com
Revision as of 23:26, 9 September 2006 by Paddy (talk | contribs)
Jump to navigation Jump to search

NFS troubleshooting

We recently got a SnapServer on our network and wanted to use our existing Amanda install to back it up via NFS. None of the NFS directories got backed up. There were no errors in the log files.

Solution
Dump works on devices, not filesystems, so it won't work on an NFS mount. Tar works on filesystems, but Amanda calls it with the option to not cross filesystem boundaries, so a backup of /nfs in your case will just give you the local files in /nfs and not mounts under /nfs. If you are trying to backup /nfs/remotedir, add /nfs/remotedir to your disklist and it will do what you want.

Ahh... so simple, so elegant. I never knew you could just add directories to the disklist. For years we added and removed various machines, always defining the actual /dev/ device:

 machinename /dev/aacd0s2e comp-user

But... clearly you can add them by actual path name too:

 machinename  /nfs/snap comp-user-tar

If you have several nfs mounts under /nfs and want them all backed up as a single DLE, you could do a set of include directives in the dumptype. Example: Line in disklist file:

 host NFSDIRS /nfs {
   user-tar
   include file        "./rmtdir1"
   include file append "./rmtdir2" "./rmtdir3"
   include file append "./rmtdir4"
 }