2

When I try to take backup of data more than 1MB in a tape (LTO3) using tar command it showing me the following error.

xyz@localhost# tar -cvf /dev/nst0 file1.tar
file1.tar
tar: /dev/nst0: Cannot write: Input/output error
tar: Error is not recoverable: exiting now

Output of mt -f /dev/st0 status:

SCSI 2 tape drive:
File number=0, block number=0, partition=0.
Tape block size 0 bytes. Density code 0x44 (LTO-3).
Soft error count since last status=0
General status bits on (41010000):
BOT ONLINE IM_REP_EN

Output of dmesg:

st0: Sense Key : Aborted Command [current]
st0: Add. Sense: Information unit iuCRC error detected

and

st0: <<vendor>> ASC=0xff ASCQ=0xffASC=0xff <<vendor>> ASCQ=0xff
Errata on LSI53C1030 occurredsc->req_bufflen=0x2800, xfer_cnt=0x00,difftransfer= 0x1400
st0: Sense Key : Medium Error [current]
Info fld=0x1400

Output of cat /proc/scsi/scsi:

Attached devices:
Host: scsi1 Channel: 00 Id: 00 Lun: 00
Vendor: NECVMWar Model: VMware IDE CDR10 Rev: 1.00
Type: CD-ROM ANSI SCSI revision: 05
Host: scsi2 Channel: 00 Id: 00 Lun: 00
Vendor: VMware Model: Virtual disk Rev: 1.0
Type: Direct-Access ANSI SCSI revision: 02
Host: scsi2 Channel: 00 Id: 01 Lun: 00
Vendor: HP Model: Ultrium 3-SCSI Rev: G54W
Type: Sequential-Access ANSI SCSI revision: 03
Host: scsi2 Channel: 00 Id: 02 Lun: 00
Vendor: HP Model: 1x8 autoloader Rev: 1.50
Type: Medium Changer ANSI SCSI revision: 03
3

From this line in the log:

st0: Sense Key : Medium Error [current]

it looks like either the tape is damaged or dirty, or the drive head is dirty or misaligned or damaged. First thing to try is to run a cleaning tape through the drive, then try writing to that tape again. If you get media errors again, try writing to a known good tape, or to a brand new tape. Do not put tapes with valuable data into the drive until you've found a solution - the drive might damage any tape put into it.

This drive appears to be part of a library. The library may provide additional information it has retrieved from the drive about the error (in particular, whether it thinks it was a drive error or a tape error). The info should be visible on the front panel and/or over the network.

  • thanks For your reply. after clean the tape still i am facing the same issue..!!!! – Vinay Gupta Apr 28 '14 at 7:10
  • now i am using new tape but again facing the same issue. Till 128KB its working fine but after that its showing input output error. – Vinay Gupta May 21 '14 at 5:10
  • I'd like to see exactly how much gets written before the error occurs. tar doesn't give that kind of info. Instead of tar cvf /dev/nst0 file, can you instead run tar cvf - file | dd of=/dev/nst0 bs=64k. See whether it fails on the first 64KB record or whether it writes one or more successfully. Also, does your library's front panel show any errors on the drive? – Mark Plotnick May 21 '14 at 5:23
  • does your library's front panel show any errors on the drive? NO, but i can write file of size 15k in tape and also able to retirieve. – Vinay Gupta May 21 '14 at 6:20
  • output of the following command tar cvf - xyz.tar.gz | dd of=/dev/nst0 bs=64k xyz.tar.gz dd: writing `/dev/nst0': Input/output error 3+0 records in 2+0 records out 131072 bytes (131 kB) copied, 2.87548 s, 45.6 kB/s – Vinay Gupta May 21 '14 at 6:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.