Amanda-Users

Re: Can't do amlabel

2003-06-16 12:11:32
Subject: Re: Can't do amlabel
From: Gene Heskett <gene.heskett AT verizon DOT net>
To: Junaidi <junaidi AT securecirt DOT com>, Paul Bijnens <paul.bijnens AT xplanation DOT com>
Date: Mon, 16 Jun 2003 12:08:40 -0400
On Monday 16 June 2003 09:22, Junaidi wrote:
>On Monday 16 June 2003 15:18, Paul Bijnens wrote:
>> Junaidi wrote:
>> > i'm currently stuck. I cant do any backup, amcheck says it's not
>> > an amanda tape. I tried to label the tape but amlabel says that
>> > the label is already on the tape. So i did a amrmtape. Now i'm
>> > having trouble labelling the tape again. These tapes have been
>> > used before for amanda.. abt six mths ago, so now i'm doing a
>> > new installation, that's why the labels are still there.
>> >
>> > This is my "dmesg"
>> >
>> > blk: queue f7e16e18, I/O limit 4095Mb (mask 0xffffffff)
>> >   Vendor: BNCHMARK  Model: DLT1              Rev: 5032
>> >   Type:   Sequential-Access                  ANSI SCSI revision:
>> > 02 blk: queue c8eaa218, I/O limit 4095Mb (mask 0xffffffff)
>> > (scsi0:A:5): 20.000MB/s transfers (10.000MHz, offset 15, 16bit)
>> > Attached scsi tape st0 at scsi0, channel 0, id 5, lun 0
>>
>> What is the output of "mt -f /dev/nst0 status"?
>
>luke root # mt -f /dev/nst0 status
>SCSI 2 tape drive:
>File number=0, block number=0, partition=0.
>Tape block size 0 bytes. Density code 0x40 (DLT1 40 GB, or Ultrium).
>Soft error count since last status=0
>General status bits on (41010000):
> BOT ONLINE IM_REP_EN
>
>> > amanda@luke amanda $ amlabel tuesday tuesday2
>> > amlabel: label tuesday2 already on a tape
>>
>> That's because amanda has this tape in the tapelist file, the file
>> that contains all the tape(-label)s and dates when last used.
>> This file is consulted to tell you which tape is expected next.
>>
>> > ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>> > amanda@luke tuesday $ amrmtape tuesday tuesday2
>> > amrmtape: preserving original database in curinfo.orig.28037
>> > (exported).
>> >
>> > ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>> > amanda@luke tuesday $ amlabel tuesday tuesday2
>> > rewinding, reading label, not an amanda tape
>> > rewinding, writing label tuesday2, checking label
>> > amlabel: no label found, are you sure /dev/nst0 is
>> > non-rewinding?
>>
>> So amanda relabeled the tape, but when checking if it wrote it
>> correctly, it failed.  You have to find out why that is.
>> Bad tape?  Wrong blocksize?  Bad karma?
>
>Bad tape i doubt, i have abt 30 tapes.. so far i have tested abt 5
> tapes.. they can't be all bad. On my "mt status" it says "Tape
> block size 0 bytes" , should i do a setblk? Anyway i did. Here's
> the output.
>
>amanda@luke amanda $ mt -f /dev/nst0 tell
>At block 1.
>amanda@luke amanda $ mt -f /dev/nst0 setblk 512
>/dev/nst0: Input/output error

This (setblk, defblksize) is a root only command.  The user amanda has 
no rights to run that.

And I'm finding out that the defblksize must be the same at read time 
as it was at write time here, else amanda cannot read the labels at 
all.  Also, I'm noteing that the above reported blocksize is 0, but 
here on a linux box, I cannot set it below 1 byte unless I use that 
specifically.  And empty number arguement sets it to 1.   Kernel is 
2.4.21.

>Please please dont let it be bad karma, tell me i got it wrong
> somewhere.

-- 
Cheers, Gene
AMD K6-III@500mhz 320M
Athlon1600XP@1400mhz  512M
99.26% setiathome rank, not too shabby for a WV hillbilly
Yahoo.com attornies please note, additions to this message
by Gene Heskett are:
Copyright 2003 by Maurice Eugene Heskett, all rights reserved.


<Prev in Thread] Current Thread [Next in Thread>