Package: amanda-server
Version: 1:2.5.2p1-4
Severity: normal

If amverify runs and there is no tape in the streamer, it will loop forever.

I started the script with -set x:

+ echo 'Using device tape:/dev/nst0'
+ echo 'Waiting for device to go ready...'
Waiting for device to go ready...
+ count=1800
+ eval '$MT' '$MTF' '$DEVICE' stat
        => here it hangs for 120 seconds
+ '[' count -lt 0 ']'
/usr/sbin/amverify: line 380: [: count: integer expression expected
+ sleep 3
++ expr 1800 - 3
+ count=1797
+ eval '$MT' '$MTF' '$DEVICE' stat

The command evaluates to "ammt -f /dev/nst0 stat":

# ammt -df /dev/nst0 stat
debug mode!
syntax: eof                  -> e
syntax: weof                 -> w
syntax: fsf                  -> f
syntax: asf                  -> a
syntax: bsf                  -> b
syntax: rewind               -> rewi
syntax: offline              -> o
syntax: rewoffl              -> rewo
syntax: status               -> s
tapename is "/dev/nst0"
calling tape_open("/dev/nst0",0)
        => here it hangs for 120 seconds

I changed [ count -lt 0 ] to [ $count -lt 0 ] in lines 380 and 438, this fixes 
the infinite loop problem.
It doesn't help with the long delay which causes the script to run for more 
than 24 hours until it breaks though.

-- System Information:
Debian Release: 5.0.1
  APT prefers stable
  APT policy: (500, 'stable')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.26-2-xen-amd64 (SMP w/8 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages amanda-server depends on:
ii  amanda-common      1:2.5.2p1-4           Advanced Maryland Automatic Networ
ii  bsd-mailx [mailx]  8.1.2-0.20071201cvs-3 A simple mail user agent
ii  libc6              2.7-18                GNU C Library: Shared libraries
ii  libncurses5        5.7+20081213-1        shared libraries for terminal hand
ii  libreadline5       5.2-3.1               GNU readline and history libraries
ii  mailx              1:20071201-3          Transitional package for mailx ren

amanda-server recommends no packages.

Versions of packages amanda-server suggests:
ii  amanda-client                1:2.5.2p1-4 Advanced Maryland Automatic Networ
ii  cpio                         2.9-13      GNU cpio -- a program to manage ar
ii  gnuplot                      4.2.2-1.2   A command-line driven interactive 
ii  mt-st                        1.1-2       Linux SCSI tape driver aware magne
ii  perl [perl5]                 5.10.0-19   Larry Wall's Practical Extraction 

-- no debconf information



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to