View Full Version : Locking the chg-robot script error

April 29th, 2010, 01:10 PM

I am new to Amanda and have tried to configure Amanda 3.1.0 beta 2 to use the Overland NEO2000e tape library. When I run the backup, amdump exits 16 and the following line is in my logfile for the run:

ERROR taper no-tape [Error locking '/usr/local/amanda-3.1.0beta2/libexec/lib/amanda/chg-robot-dev-sg7']

The changer configuration looks like this:
tapedev "neo2k"

define changer neo2k {
tpchanger "chg-robot:/dev/sg7"
property "tape-device" "0=tape:/dev/nst0" "1=tape:/dev/nst1"
device_property "BLOCK_SIZE" "128m"
device_property "DRIVE-CHOICE" "lru" # Round Robin drive wear!

The device files look like this:

crw-rw---- 1 root disk 21, 7 2010-04-21 18:02 /dev/sg7
crw-rw---- 1 root disk 9, 128 2010-04-21 18:02 /dev/nst0
crw-rw---- 1 root disk 9, 224 2010-04-21 18:02 /dev/nst0a
crw-rw---- 1 root disk 9, 160 2010-04-21 18:02 /dev/nst0l
crw-rw---- 1 root disk 9, 192 2010-04-21 18:02 /dev/nst0m
crw-rw---- 1 root disk 9, 129 2010-04-21 18:02 /dev/nst1
crw-rw---- 1 root disk 9, 225 2010-04-21 18:02 /dev/nst1a
crw-rw---- 1 root disk 9, 161 2010-04-21 18:02 /dev/nst1l
crw-rw---- 1 root disk 9, 193 2010-04-21 18:02 /dev/nst1m

I believe that I read that all of the drivers exist in -amandadir-/libexec/amanda/ but I don't see chg-robot but the documentation here
and here
clearly states that this driver is included with Amanda however, I don't see it in the libexec dir.

Finally, amtape also triggers this error, and when I strace it I see the following:
open("/usr/local/amanda-3.1.0beta2/libexec/lib/amanda/chg-robot-dev-sg7", O_RDWR|O_CREAT, 0666) = -1 ENOENT (No such file or directory)
Maybe this is spurious.

I'm not really sure what to look for to resolve this.
I am thankful for any advise.


April 29th, 2010, 01:14 PM
The directory doesn't exists.

try: mkdir -p /usr/local/amanda-3.1.0beta2/libexec/lib/amanda

April 29th, 2010, 02:02 PM
This solved the problem of course.
Thank you for your time, Martineau.

April 29th, 2010, 03:31 PM
We are glad things are working on your end. It will be great if you can share your overall experience with Amanda 3.1. Any details on your tape drives/library, time/size of backup will be very useful for other Amanda users.


April 30th, 2010, 09:49 AM
hello zbackup and all,

After getting through this relatively minor problem, I ran into a different problem.

When I would run amdump it would fail and the logs and email would report the following:

FAILURE DUMP SUMMARY: taper: FATAL Can't use string ("") as a subroutine ref while "strict refs" in use at/usr/local/lib/perl5/site_perl/5.10.0/Amanda/Changer.pm line 981.

I discovered that amtape would also generate this error so I simply edited the Changer.pm and added print statement so I could see what the error was.
I decided that if there were problems at this level that I should probably revert to the most recent stable release, 2.6.1p2. I need to implement this in a production environment and I am concerned about the opinions of my colleagues if a failure occurs and it's known that I was using beta software in this capacity that exhibited problems at this level.
In truth, I had not intended to use the beta version in this capacity but I was having trouble understanding why the 2.6.1p2 version I had wasn't working with the configuration I had assembled from the wiki documentation. If i had been able to run through the entire configuration and tests with minor errors like the one Martineau had helped me with, I think I would've continued to work with the beta, but this problem has given me cold feet.

Thank you,

April 30th, 2010, 11:01 AM
To followup,

In regard to the problems that I've experienced and that I indicate below as the reason that I am reverting to the stable release, I believe that my system has problems with the Amanda perl components that affect both the 3.1 beta version as well as the 2.6.1.p2 stable version. Specifically, I don't now know which version of the Amanda perl libraries are now installed on the system. When I built the software (both versions) from source, I missed the configuration option for the perl libraries and I have reason to believe that both versions have been installed into "installsitelib", one on top of the other, perhaps even in the wrong order, (although I believe that I installed 2.6.1p2 first, and then installed 3.1.0beta2 on top of it).

Thank you for your time,