Amanda-Users

chg-manual problem

2004-01-23 04:45:18
Subject: chg-manual problem
From: "Toomas Aas" <toomas.aas AT raad.tartu DOT ee>
To: amanda-users AT amanda DOT org
Date: Fri, 23 Jan 2004 11:42:48 +0200
Hello!

I'm using Amanda 2.4.4 with chg-manual. Here's the piece of 
amanda.conf:

tpchanger "chg-manual"  # the tape-changer glue script
tapedev "/dev/nsa0"     # the no-rewind tape device to be used
rawtapedev "/dev/rsa0"  # the raw device to be used (ftape only)
changerfile "/usr/adm/amanda/changer"

I've modified /usr/local/libexec/amanda/chg-manual so that if the 
correct tape is not loaded when amdump (or amcheck) starts, Amanda 
sends me mail to load the tape. This was done simply by commenting out 
the original request() function and replacing the comments from 
alternate function provided in the script.

With Amanda 2.4.2p2 it worked very well - I got the mail asking to load 
the tape, I went and loaded the tape and things proceeded as normal.

However, when I upgraded to 2.4.3b4, a problem appeared which now also 
exists with 2.4.4. When the correct tape is not loaded, Amanda sends me 
mail to load the correct tape. I do it, but Amanda ejects the tape and 
sends me the mail again. This cycle seems to repeat itself infinitely.

I'm sure there is no problem with the tape itself, because when the 
tape is loaded before amdump (or amcheck) starts, Amanda never 
complains and does her job just fine. 

Looking at /tmp/amanda/changer.debug it seems that the changer itself 
works OK. But after it loads the tape, "something" seems to tell it 
that it doesn't like the tape and could it please load the next tape.

Here's an excrept of changer.debug:

-------------------------------< cut >-------------------------------
MT -> /usr/local/sbin/ammt -f
DD -> /usr/local/sbin/amdd
Args -> -slot current
     -> rewind /dev/nsa0
/dev/nsa0 rewind failed: Device not configured
     -> status /dev/nsa0
/dev/nsa0 status failed: Device not configured
     -> loaded <>
     -> load   13
     -> rewind /dev/nsa0
/dev/nsa0 rewind failed: Device not configured
     -> status /dev/nsa0
/dev/nsa0 status failed: Device not configured
     -> loaded <>
     -> rewind /dev/nsa0
     -> status /dev/nsa0
/dev/nsa0 status: ONLINE ds == 0x0001 er == 0x0000
     -> loaded </dev/nsa0 status: ONLINE ds == 0x0001 er == 0x0000>
     -> rewind /dev/nsa0
     -> status /dev/nsa0
/dev/nsa0 status: ONLINE ds == 0x0001 er == 0x0000
     -> loaded </dev/nsa0 status: ONLINE ds == 0x0001 er == 0x0000>
AMANDA: TAPESTART DATE 20040114 TAPE PAEV04

[ --- LOT OF BINARY STUFF --- ]

1+0 in
1+0 out
Exit -> 13 /dev/nsa0
MT -> /usr/local/sbin/ammt -f
DD -> /usr/local/sbin/amdd
Args -> -slot next
     -> rewind /dev/nsa0
     -> status /dev/nsa0
/dev/nsa0 status: ONLINE ds == 0x0001 er == 0x0000
     -> loaded </dev/nsa0 status: ONLINE ds == 0x0001 er == 0x0000> 
     -> offline /dev/nsa0 
     -> load   14 
     -> rewind /dev/nsa0
/dev/nsa0 rewind failed: Device not configured
-------------------------------< cut >-------------------------------

This was generated when I left the tape out of the drive and ran 
amcheck -m. Basically the same thing happens when the tape is not in 
drive while nightly amdump starts.

Here's the corresponding amcheck.debug:

-------------------------------< cut >-------------------------------
amcheck: debug 1 pid 50148 ruid 1000 euid 0: start at Thu Jan 22
15:41:17 2004 
amcheck: dgram_bind: socket bound to 0.0.0.0.980 
changer: got exit: 0 str: 0 99 1 
changer_query: changer return was 99 1
changer_query: searchable = 0 
changer_find: looking for PAEV04 changer is searchable = 0 
changer: got exit: 0 str: No $home variable set.
-------------------------------< cut >-------------------------------

Does this 'no $home variable set' hint at something? Or am I barking 
under entirely wtong tree here?
--
Toomas Aas | toomas.aas AT raad.tartu DOT ee | http://www.raad.tartu.ee/~toomas/
* War doesn't determine who's right. War determines who's left.


<Prev in Thread] Current Thread [Next in Thread>
  • chg-manual problem, Toomas Aas <=