tape tar error


 
Thread Tools Search this Thread
Operating Systems Solaris tape tar error
# 1  
Old 10-11-2012
tape tar error

Hi,

I am trying to determine if a tape is full because on 2 different tapes, im receiving 2 different kind of errors:

Code:
# uname
SunOS
# /bin/tar cvf /dev/rmt/0n /export/home
a /export/home/jerry/wlserver_10.0.tar.gz 28528 tape blocks
tar: write error: unexpected EOF

#  mt -f /dev/rmt/0n status
HP DDS-4 DAT (Sun) tape drive:
   sense key(0x13)= EOT   residual= 0   retries= 0
   file no= 8   block no= 0
#


Code:
provadm@01:provadm/tmp%tar cvf /dev/rmt/0n add.sh
a add.sh 1 tape blocks
tar: close error: I/O error

provadm@01:provadm/tmp%mt -f /dev/rmt/0n status
HP DAT-72 tape drive:
   sense key(0x13)= EOT   residual= 0   retries= 0
   file no= 3778   block no= 0
provadm@01:provadm/tmp%

Both status shows "sense key(0x13)= EOT" unfortunately, the tar error on both append are different. any suggestion if both actually meant that the tape is full?

Many Thanks!

Last edited by mosies; 10-12-2012 at 06:22 AM..
# 2  
Old 10-11-2012
I am not an Solaris expert, but the first error is most definitely a "tape full" error. In disks you have a fixed amount of space you know in advance. So the OS can keep track of the decreasing number of free space during a write operation and once this number hits zero it can tell you "disk full".

There is no such thing with a tape: a tape is of indefinite length (at least from the OS point of view) and therefore of indefinite capacity. For the running tar it is like this: it writes a piece of data, then further winds the tape, then writes the next piece, ... . At the end of the tape the tape drive will tell the OS (tar) that there is no more tape to wind - but for the OS this will be "unexpected", because it can't expect the end of tape like it could expect the exhaustion of disk space.

The second error more looks like a tape error: the magnetic coating of the tape might be damaged or the head of the drive might be dirty or nearing their end-of-life or whatever - the data haven't been written for some reason and it was the fault of something between the tape drive and the tape.

I hope this helps.

bakunin
# 3  
Old 10-11-2012
unfortunately, when i check the /var/adm message, i see the following for the 2nd tape:

Code:
Oct 11 13:31:19 01 scsi: [ID 107833 kern.warning] WARNING: /pci@1f,700000/pci@0/scsi@2/st@0,0 (st0):
Oct 11 13:31:19 01        Error for Command: write file mark         Error Level: Fatal
Oct 11 13:31:19 01 scsi: [ID 107833 kern.notice]  Requested Block: 1                         Error Block: 1
Oct 11 13:31:19 01 scsi: [ID 107833 kern.notice]  Vendor: HP                                 Serial Number:    9   $DR-1
Oct 11 13:31:19 01 scsi: [ID 107833 kern.notice]  Sense Key: Volume Overflow
Oct 11 13:31:19 01 scsi: [ID 107833 kern.notice]  ASC: 0x0 (end of partition/medium detected), ASCQ: 0x2, FRU: 0x0
Oct 11 13:31:19 01 scsi: [ID 107833 kern.notice]  End-of-Media Detected

is this still io error? or tape full? because both tapes shows EOT....

Last edited by mosies; 10-12-2012 at 06:23 AM..
# 4  
Old 10-11-2012
Normally you would tell tar the capacity of the tape drive using a switch on the tar command depending on which Unix O/S it is.

See the man page for your respective tar command.

For example, if your man page tells you the switch is -L and your tape capacity (with compression) is, say, 80GB then you would include -L 80000000 in the command. Tar would then write 80000000 1k blocks before asking for the next tape volume.
# 5  
Old 10-11-2012
The 2 tapes are on 2 different servers. What i would like to confirm is, although the errors are different, both are showing EOT when i did the status check.
Just want to know if both means End of Tape? because the 2nd tape shows an IO error..
# 6  
Old 10-12-2012
Yes, "EOT" is "End of Tape". Rewind the tape to clear that condition.

I hope this helps.

bakunin
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

tar to tape drive command

I want to use this command to tar to tape: tar cf - DIR | compress > `hostname`_`date +%m-%d-%y`.DIR.tar.Z this of course goes to the FS. How do I modify this to go directly to tape? My tape device is /dev/rmt/0 thanks. Having so many posts you should be familiar using code tags.... (7 Replies)
Discussion started by: djehresmann
7 Replies

2. UNIX for Advanced & Expert Users

tar and vdump on same tape?

Hello, This might be a dumb question, but I havent been able to find the answer anywhere. I currently have a backup script that uses 'tar' to backup some files to tape. I need to add a directory to the backup script, but I want to use 'vdump' to back it up to tape. So my question is can I... (3 Replies)
Discussion started by: xadamz23
3 Replies

3. UNIX for Dummies Questions & Answers

Writing tar file to tape

Hi Guy`s I`m a newbie to Unix and I`m starting to love it I got stuck donig backups of tar files to tape I use this to find all tar files find . -name '*.tar.*' > output in output there would be n of file eg. 6 the size output is 156 but tar files are: 9.3M Jul 18 09:48... (1 Reply)
Discussion started by: donovan
1 Replies

4. UNIX for Advanced & Expert Users

tar: tape blocksize error

Hi, I have tar: tape blocksize error when launching # gunzip < TierDB.tar.gz |tar -xvf /data/ora/DREC tar: tape blocksize error Can you please help me ? It is urgent. Many thanks. (1 Reply)
Discussion started by: big123456
1 Replies

5. UNIX for Advanced & Expert Users

Does tar do crc checking on a tape or tar file?

Trying to answer a question about whether tar table-of-contents is a good tool for verifying tape data. (1 Reply)
Discussion started by: tjlst15
1 Replies

6. Solaris

Error tar'ing files to tape

I'm trying to tar a bunch of files off to a tape, but for one specific file (it is fairly large, roughly 10Gb) I get the error: too large to archive Does tar have a limit of the size of file it can write off to tape? I'm using SunOS 5.8. Thanks! -Fred (6 Replies)
Discussion started by: FredSmith
6 Replies

7. UNIX for Advanced & Expert Users

dump and tar backup in one tape

Hi all! I'm new in this forum. I need to ask a few question. I would like to know if it is possible to use dump and tar command for backup in one tape. If it is possible, how do I restore it back? Fyi, I'm using the Digital Unix 4.0E OSF/1 box. (old box) :-) Thank you. :) (0 Replies)
Discussion started by: apokobondo
0 Replies

8. UNIX for Advanced & Expert Users

Tar: tape blocksize error

When trying to extract a tar file in HP-UX using tar -xvf command it exits with the following error :"Tar: tape blocksize error". Tar file is created using the following command with MKS toolkit(Unix Simulation Kit for Windows env) under Windows 2000 Professional: "$tar -cvf test.tar test.txt... (1 Reply)
Discussion started by: ramkumar
1 Replies

9. UNIX for Advanced & Expert Users

tar to remote tape

I tried to buckup some oracle archive logs (from a solaris machine) to a remote tape (in a HP-UX machine). I added the solaris machine name and user to .rhosts, and i tried to use this commande : tar cvf HPhost:/dev/rmt/0mn /u01/* The probleme that it gives: HPhost:/dev/rmt/0mn : No such... (1 Reply)
Discussion started by: lasgaa
1 Replies

10. UNIX for Dummies Questions & Answers

tar to tape and back

Howdy, I'm trying to tar some directories to tape and then extract them from tape on another machine. I was hoping someone could help me with the syntax of the tar commands. Both machines are running Solaris 8. Need to get all files and directories under the following: ... (6 Replies)
Discussion started by: pmetal
6 Replies
Login or Register to Ask a Question