PDA

View Full Version : amrecover and chg-multi



skuali
April 23rd, 2007, 12:20 AM
Hi all,

I have configured amanda in order to use the changer chg-multi (tpchanger "chg-multi", amrecover_do_fsf yes, amrecover_check_label yes, amrecover_changer "chg_multi"). After making a backup I have some problems to restore files. This is the error that appears when I execute amrecover -C total.

AMRECOVER Version 2.4.5. Contacting server on localhost ...
220 swpa07 AMANDA index server (2.4.5) ready.
200 Access OK
Setting restore date to today (2007-04-23)
200 Working date set to 2007-04-23.
200 Config set to total.
501 Host swpa07 is not in your disklist.
Trying host swpa07.sw.ehu.es ...
501 Host swpa07.sw.ehu.es is not in your disklist.
Trying host swpa07 ...
501 Host swpa07 is not in your disklist.
amrecover> sethost prueba.sw.ehu.es
200 Dump host set to prueba.sw.ehu.es
amrecover> setdisk /data
200 Disk set to /data.
amrecover> ls
2007-04-20 .
2007-04-20 ayuela/
2007-04-20 linx/
amrecover> cd ayuela
/data/ayuela
amrecover> add fftw*
Added /ayuela/fftw-2.1.1-1.i386.rpm
Added /ayuela/fftw-2.1.5-4.1.fc2.dag.i386.rpm
Added /ayuela/fftw-3.0.1-6.rhfc2.at.i386.rpm
amrecover> settape chg-multi
Using tape "chg-multi" from server localhost.
amrecover> extract

Extracting files using tape drive chg-multi on host localhost.
The following tapes are needed: total01

Restoring files into directory /root/restore
Continue [?/Y/n]? y

Extracting files using tape drive chg-multi on host localhost.
Load tape total01 now
Continue [?/Y/n/s/t]? y
EOF, check amidxtaped.<timestamp>.debug file on localhost.
amrecover: short block 0 bytes
UNKNOWN file
amrecover: Can't read file header
extract_list - child returned non-zero status: 1
Continue [?/Y/n/r]?

Taking a look at the amidxtaped log I have found the following information:

amrestore: could not stat chg-multi: No such file or directory
amidxtaped: time 0.002: amrestore terminated normally with status: 2
amidxtaped: could not stat chg-multi: No such file or directory
amidxtaped: time 0.002: could not stat chg-multi: No such file or directory
amidxtaped: time 0.002: pid 14028 finish time Mon Apr 23 09:53:22 2007

As suggested in the wiki I have executed the command amadmin total version | grep TAPE_DEVICE, and indeed the default tape device is /dev/null. So if I executed amrecover -C total -d /dev/nst0 (which is my no-rewinding tape device) everything works properly.
How could I configure amanda to use the chager chg-multi to perform my backups?
The chg-multi.conf file:

multieject 0
gravity 0
needeject 0
ejectdelay 0
statefile /var/lib/amanda/total/changer-status
firstslot 1
lastslot 1
slot 1 /dev/nst0

Thanks in advance for your answer.

Skuali.

martineau
April 23rd, 2007, 02:55 AM
Hi all,

I have configured amanda in order to use the changer chg-multi (tpchanger "chg-multi", amrecover_do_fsf yes, amrecover_check_label yes, amrecover_changer "chg_multi"). After making a backup I have some problems to restore files. This is the error that appears when I execute amrecover -C total.

AMRECOVER Version 2.4.5. Contacting server on localhost ...

amrecover> settape chg-multi
Using tape "chg-multi" from server localhost.
amrecover> extract

Skuali.

You configured amrecover_changer to "chg_multi",
you must settape with the same device name
settape chg_multi # not chg-multi

skuali
April 23rd, 2007, 03:24 AM
It works!!!! I took a look at my configuration file several times and I didn't see anything strange....How blind I was........
Thank you for your help!!!


Skuali.