HOWTO Restore Files From Amanda: Difference between revisions

From Research
Jump to navigation Jump to search
Line 17: Line 17:


== Restoring Files ==
== Restoring Files ==
Looking at the file-listing, you are interested in the '''most-recent''' level0 backup (to begin with), and the most-recent level1.  None of the others (ie  xxx ) are of any interest at all.
<br>
Now that you know what tape the files are on, insert the tape into the drive and ask for the files. Note: ''The files will be extracted into the current directory.''
Now that you know what tape the files are on, insert the tape into the drive and ask for the files. Note: ''The files will be extracted into the current directory.''
  # mkdir restore; cd restore
  # mkdir restore; cd restore

Revision as of 04:34, 5 May 2007

How to restore files from an Amanda tape backup.

SSH to musashi for recovering files from a machine, and SSH to yamato to recover files from users or projects.

Finding Where the Files you want to Restore are Located

# su - amanda
$ amadmin $backupname find $hostname/$ipaddress $directorypath
$ amadmin DailyMusashi find 209.87.56.16 /etc

You should see something like this:

2006-04-07 209.87.56.16 /etc/  0 DailyMusashi20   24 OK
2006-04-10 209.87.56.16 /etc/  1 DailyMusashi21   16 OK
2006-04-11 209.87.56.16 /etc/  1 DailyMusashi22   19 OK
2006-04-12 209.87.56.16 /etc/  1 DailyMusashi23   23 OK
2006-04-13 209.87.56.16 /etc/  1 DailyMusashi24   29 OK
2006-04-18 209.87.56.16 /etc/  1 DailyMusashi25   23 OK

Restoring Files

Looking at the file-listing, you are interested in the most-recent level0 backup (to begin with), and the most-recent level1. None of the others (ie xxx ) are of any interest at all.
Now that you know what tape the files are on, insert the tape into the drive and ask for the files. Note: The files will be extracted into the current directory.

# mkdir restore; cd restore
# amrestore -p /dev/nst0 209.87.56.16 /etc | tar xvf -

This process will output the files and directories in the current folder. You can aboard the process at anytime when your file has been recovered (CTRL-C).

Finish Up

Rewind a tape:

# mt -f /dev/nst0 rewind
# mt -f /dev/nst0 eject