PDA

View Full Version : Strange problems with virtual tapes



useless
March 29th, 2006, 07:43 AM
Hello,

I exactly followed the HOWTO-FILE-DRIVER tutorial, but there are strange problems with labeling the virtual tapes. I'm quite sure that there isn't a permission problem.

Used Version: 2.4.4p2
OS: FreeBSD 4.11

Some relevant configuration lines


dumpcycle 7
tapecycle 7
tapetype VTAPES
tpchanger "chg-disk"
changerfile "/xxx/adm/changer"
tapedev "file:/backup-hd/slots"
bumpsize 20 MB
bumpdays 1
bumpmult 4

labelstr "^backup-[0-9][0-9]*$"


Directory listening:


drwxr-x--- 9 operator operator 512 Mar 29 16:18 ./
drwxr-x--- 3 operator wheel 512 Mar 28 13:51 ../
lrwx------ 1 operator operator 27 Mar 29 16:18 [email protected] -> /backup-hd/slots/slot1
-rw-r--r-- 1 operator operator 11 Mar 29 16:18 info
drwxr-xr-x 2 operator operator 512 Mar 29 16:17 slot1/
drwxr-xr-x 2 operator operator 512 Mar 29 16:17 slot2/
drwxr-xr-x 2 operator operator 512 Mar 29 16:17 slot3/
drwxr-xr-x 2 operator operator 512 Mar 29 16:17 slot4/
drwxr-xr-x 2 operator operator 512 Mar 29 16:18 slot5/
drwxr-xr-x 2 operator operator 512 Mar 29 16:18 slot6/
drwxr-xr-x 2 operator operator 512 Mar 29 16:18 slot7/


Labeling the first virtual tape works w/o problems:


[email protected]:/xxx/adm> amlabel festplatte backup-1 slot 1
labeling tape in slot 1 (file:/backup-hd/slots):
rewinding, reading label, not an amanda tape
rewinding, writing label backup-1, checking label, done.


But then it's getting funny:



[email protected]:/xxx/adm> amlabel festplatte backup-2 slot 2

labeling tape in slot [: ($[ACCESSCOUNT+1]: bad number):
rewinding
amlabel: tape_rewind: tape open: $[ACCESSCOUNT+1]: bad number: No such file or directory
Exit 1

After the second execution of the amlabel command:

[email protected]:/xxx/adm> amlabel festplatte backup-2 slot 2
labeling tape in slot 2 (file:/backup-hd/slots):
rewinding, reading label, not an amanda tape
rewinding, writing label backup-2, checking label, done.
(... and so on)


Looks fine, but it doesn't work:



[email protected]:/backup-hd/slots> amtape festplatte show
amtape: scanning all 7 slots in tape-changer rack:
slot 7: date X label backup-7
slot [:: tape_rdlabel: tape open: $[7+1]: bad number: No such file or directory
slot [:: tape_rdlabel: tape open: $[$[7+1]+1]: bad number: No such file or directory
slot [:: tape_rdlabel: tape open: $[$[$[7+1]+1]+1]: bad number: No such file or directory
slot [:: tape_rdlabel: tape open: $[$[$[$[7+1]+1]+1]+1]: bad number: No such file or directory
slot [:: tape_rdlabel: tape open: $[$[$[$[$[7+1]+1]+1]+1]+1]: bad number: No such file or directory
slot [:: tape_rdlabel: tape open: $[$[$[$[$[$[7+1]+1]+1]+1]+1]+1]: bad number: No such file or directory


Any hints?

Thanks for helping.

useless
April 3rd, 2006, 10:22 AM
Fixed in 2.4.5 Release.

ppragin
May 18th, 2006, 12:05 PM
can you post the debug logs from /tmp/amanda so i can examine them?
Pavel