Using amrecover command to restore data on the client from the backup server:
1. amrecover DailySet1 -t tapeserver.example.com -s indexserver.example.com #run on client while in restore directory to enter the amrecover interface
[root@vmclient restore]# amrecover disk -t vmserver -s vmserver AMRECOVER Version 2.5.0. Contacting server on vmserver ... 220 vmserver AMANDA index server (2.5.0) ready. 200 Access OK Setting restore date to today (2006-05-03) 200 Working date set to 2006-05-03. 200 Config set to disk. 200 Dump host set to vmclient.zmanda.com. Trying disk / ... Trying disk rootfs ... Use the setdisk command to choose dump disk to recover amrecover>
Commands while logged in to amrecover interface:
2. sethost "client_hostname" #specifies which host to look at backup files for
3. setdate YYYY-MM-DD #file listing commands like "ls" only return information on backup images for this day
3. listdisk #lists all the file systems backed up on the client host on the date set in the prviuos command
amrecover> listdisk 200- List of disk for host vmclient.zmanda.com 201- /boot 200 List of disk for host vmclient.zmanda.com amrecover>
4. history #show all backup history like "date of backup", "bakup level", "tape label" for a particular file system previously set with command setdisk
amrecover> sethost vmclient 501 Host vmclient is not in your disklist. Trying host vmclient.zmanda.com ... 200 Dump host set to vmclient.zmanda.com. amrecover> sethost vmclient.zmanda.com 200 Dump host set to vmclient.zmanda.com. amrecover> setdisk /boot 200 Disk set to /boot. amrecover> history 200- Dump history for config "disk" host "vmclient.zmanda.com" disk /boot 201- 2006-05-03-12-52-00 1 disk-2:1 201- 2006-05-03-08-53-14 1 disk-1:1 201- 2006-05-03-08-49-40 0 disk-25:1 200 Dump history for config "disk" host "vmclient.zmanda.com" disk /boot
5. add file1 file2 #adds the specified files or directories to the restore list
6. lwd #shows the amrecover working directory and all files will be restored under this directory
7. extract #restores the files or dirs that were added to the restore list (make sure you have set the correct local working directory
8. settape amandaserver:/dev/nst0 #sets the tape drive and tape host to restore from
9. settape amandaserver:file:/var/lib/amanda/vtapes/DailySet1/vtape1 #sets the virtual tape drive and tape host to restore from