LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-25-2014, 09:34 AM   #16
JeremyBoden
Senior Member
 
Registered: Nov 2011
Distribution: Debian
Posts: 1,144

Rep: Reputation: 235Reputation: 235Reputation: 235

Perhaps you have a tape error - or perhaps you have the read-only tab set on the tape
 
Old 04-28-2014, 04:13 AM   #17
New_in_linux
LQ Newbie
 
Registered: Jan 2014
Posts: 24

Original Poster
Rep: Reputation: Disabled
@JeremyBoden
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

i don't know what is the error its tape-error or read-only tab set on the tape.
 
Old 04-28-2014, 05:07 AM   #18
JeremyBoden
Senior Member
 
Registered: Nov 2011
Distribution: Debian
Posts: 1,144

Rep: Reputation: 235Reputation: 235Reputation: 235
Did you get a response to your tape error question in your other thread?
https://www.linuxquestions.org/quest...pe-4175502942/

However,
Quote:
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
These are SCSI codes...
So "Medium Error" would indicate that you should try
1. Using a cleaning tape.
2. (re)-initialize your tape.
3. Try a new tape.
 
Old 04-28-2014, 07:12 AM   #19
New_in_linux
LQ Newbie
 
Registered: Jan 2014
Posts: 24

Original Poster
Rep: Reputation: Disabled
yes i got response but its not worked.

when i start cleaning tape using the following command:

mt -f /dev/nst0 erase

it will take time(around 3 hr) and not got anything on the screen but still facing the same issue .
 
Old 04-28-2014, 09:47 AM   #20
JeremyBoden
Senior Member
 
Registered: Nov 2011
Distribution: Debian
Posts: 1,144

Rep: Reputation: 235Reputation: 235Reputation: 235
When I said "cleaning tape", I meant a special cleaning tape that runs for a few minutes.
It has a very mild abrasive to clean the tape heads by removing any accumulated "oxide".
You have to buy these tapes and they should be run according to the recommended schedule.

One cleaning tape is good for several dozen cleaning cycles - probably at least a couple of years - depending on tape drive usage.
 
Old 04-28-2014, 10:12 AM   #21
New_in_linux
LQ Newbie
 
Registered: Jan 2014
Posts: 24

Original Poster
Rep: Reputation: Disabled
ok....but i think it is not a problem with header because when i take backup of some file even if it shows error the header moves forward.

#mt -f /dev/nst0 stat

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

#tar -cvzf /dev/nst0 xyz
xyz
tar (child): /dev/nst0: Cannot write: Input/output error
tar (child): Error is not recoverable: exiting now

# mt -f /dev/nst0 stat
SCSI 2 tape drive:
File number=1, 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 (81010000):
EOF ONLINE IM_REP_EN

# tar -czvf /dev/nst0 ltobackup_20140207

ltobackup_20140207
tar (child): /dev/nst0: Cannot write: Input/output error
tar (child): Error is not recoverable: exiting now

# mt -f /dev/nst0 stat

SCSI 2 tape drive:
File number=2, 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 (81010000):
EOF ONLINE IM_REP_EN
 
Old 05-21-2014, 02:09 AM   #22
New_in_linux
LQ Newbie
 
Registered: Jan 2014
Posts: 24

Original Poster
Rep: Reputation: Disabled
@JeremyBoden after "cleaning tape" and using new tape still is showing the same error. i can write file of size 15k but when i write file of around 1mb its showing me the same error.
 
Old 05-21-2014, 08:36 AM   #23
JeremyBoden
Senior Member
 
Registered: Nov 2011
Distribution: Debian
Posts: 1,144

Rep: Reputation: 235Reputation: 235Reputation: 235
Has this drive ever worked properly?
I'm pretty much out of ideas here.

How does reading a small file from the tape compare with what was written to it?
 
Old 05-22-2014, 06:00 AM   #24
New_in_linux
LQ Newbie
 
Registered: Jan 2014
Posts: 24

Original Poster
Rep: Reputation: Disabled
@JeremyBoden Has this drive ever worked properly?
NO.
How does reading a small file from the tape compare with what was written to it?
i did it and getting the correct data if the file size is less.


according to the HP LTO document To enable large transfers to tape under Linux (>64 KB per write),
i have to set the ST_BUFFER_BLOCKS for that i have to edit the file /usr/src/linux/drivers/scsi/st_options.h and change the definition of ST_BUFFER_BLOCKS but the file st_options.h is not present in my centos6.5
is there any other way through which i can set buffer block or it is having different name...???
 
Old 05-23-2014, 06:37 AM   #25
JeremyBoden
Senior Member
 
Registered: Nov 2011
Distribution: Debian
Posts: 1,144

Rep: Reputation: 235Reputation: 235Reputation: 235
Is this definitely for your model of tape drive?
SCSI covers a vast range of speeds - the last non-enterprise one I saw was 320 MBytes/sec
A 64KB buffer has to be way to small for a high speed streaming tape.

Since you are supposed to alter a source file, presumably you need to re-compile your tape driver?
I wouldn't have a clue on how to do this.
 
Old 05-23-2014, 07:08 AM   #26
New_in_linux
LQ Newbie
 
Registered: Jan 2014
Posts: 24

Original Poster
Rep: Reputation: Disabled
@jeremyBoden ya its written in HP LTO3 document.

we are using vmware hypervisior having ESXi 5.1.0 build-799733 as a host and 2 guest host running on it.

is there any driver problem in our host because our LTO physically connected to it...?????
 
Old 05-23-2014, 08:43 AM   #27
JeremyBoden
Senior Member
 
Registered: Nov 2011
Distribution: Debian
Posts: 1,144

Rep: Reputation: 235Reputation: 235Reputation: 235
Have you asked ESXi about this?
 
Old 05-23-2014, 03:29 PM   #28
jpollard
Senior Member
 
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 4,696

Rep: Reputation: 1261Reputation: 1261Reputation: 1261Reputation: 1261Reputation: 1261Reputation: 1261Reputation: 1261Reputation: 1261Reputation: 1261
That error usually only occurs at the end of tape, OR if the tape has a write error.
 
Old 05-23-2014, 04:23 PM   #29
JeremyBoden
Senior Member
 
Registered: Nov 2011
Distribution: Debian
Posts: 1,144

Rep: Reputation: 235Reputation: 235Reputation: 235
See
Quote:
Q. Has this drive ever worked properly?
A. NO.
 
Old 05-23-2014, 09:13 PM   #30
jpollard
Senior Member
 
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 4,696

Rep: Reputation: 1261Reputation: 1261Reputation: 1261Reputation: 1261Reputation: 1261Reputation: 1261Reputation: 1261Reputation: 1261Reputation: 1261
If it is a block under run (possible with streaming tapes I guess - I've only seen this on CDs personally) then have you tried using the device blocking options? like -b 2048 (1MB).

The problem may have nothing to do with the driver size, but just the amount of data provided by tar at one time.

Another option is to pipe the output of tar to dd and use dd for blocking huge records. (note: using large buffers on both wouldn't hurt, but this is only for testing. I would expect the tar buffer controls to be the better choice).

Last edited by jpollard; 05-23-2014 at 09:20 PM.
 
  


Reply

Tags
back-up, centos6, lto, newbie, tape drive


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
incremental backup on tape drive nayan123 Linux - Server 2 02-05-2012 01:37 PM
how to do backup on Tape Drive LinuxLover Linux - Hardware 4 01-17-2007 10:22 PM
Using a DDS5 tape drive to restore from a DDS3 backup tape. AndrewCAtWayofthebit Linux - Hardware 1 05-14-2006 09:15 AM
cannot backup to tape drive complus Linux - Newbie 5 10-01-2003 05:17 AM
Tape incremental backup to different tape tungaw2001 Linux - Software 0 08-13-2003 09:42 PM


All times are GMT -5. The time now is 01:19 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration