1748038 Members
5310 Online
108757 Solutions
New Discussion юеВ

Tar not working properly

 
Broflowsky
Occasional Advisor

Tar not working properly

I wanted to do an Ignite but I got the following error,

* Checking Versions of Ignite-UX filesets
ERROR: Write test failed!
ERROR: Check tape device failed.

So I tried a simple tar to see if the tape drive works, but I found this.

[root]:/root # mt -t /dev/rmt/0m rew
[root]:/root # echo $?
0
[root]:/root # tar cvf /dev/rmt/0m /etc/passwd
a /etc/passwd 6 blocks
Tar: end of tape
Tar: to continue, enter device/file name when ready or null string to quit.

User entered a null name for next device file.
[root]:/root #

You know that /etc/passwd is a tiny file, there is no way it could be filling the entire tape.

Any idea what could be wrong?
18 REPLIES 18
Steven E. Protter
Exalted Contributor

Re: Tar not working properly

Shalom,

Do an ignite? Make an ignite backup?

Your tar is failing because the tape is full. Im think tar can't span multiple tapes. There may be a command line option in the man page for tar that will let you get around this.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
TTr
Honored Contributor

Re: Tar not working properly

The "end of tape" is either a generic error that tar outputs when it can't write to the tape or the tape drive reports the end of tape condition because of a bad tape or bad drive. Have you tried a different tape or drive?

PS. Unless you have a very old IgniteUX version, igniteUX has been using pax instead of tar for a while now.

Try some more test with with different tapes and drives.
James R. Ferguson
Acclaimed Contributor

Re: Tar not working properly

Hi:

I suggest that you clean your tape drive and test with a new tape. Your simple 'tar' of the password file should NOT have performed as it did.

Regards!

...JRF...
Patrick Wallek
Honored Contributor

Re: Tar not working properly

>>Your tar is failing because the tape is full.

Doubtful, given the errors shown.

>>Im think tar can't span multiple tapes.

Baloney! Tar has always had the ability to span multiple tapes.

Given the errors above, the things I would try are:

1) Clean the tape drive. Do this 2 or 3 times.

2) Try a new/different tape. A bad tape can cause issues like this.

3) Check SCSI cables and terminators.

4) If all else fails, you may been to replace the tape drive.
Ganesan R
Honored Contributor

Re: Tar not working properly

Hi,

Most suspect part would be media. Also make sure that the tape is not write protected.
Best wishes,

Ganesh.
Steven E. Protter
Exalted Contributor

Re: Tar not working properly

Dirty tape heads can lead the tar utility to falsely indicate the tape is full.

>>
Tar: end of tape
<<

For tar to span multiple tapes, the process must be interactive, so the operator can tell the job when to resume. Run in the background tar can not span multiple tapes.

tar is not able without some kind of input to know when the next tape is ready.

Here it asks for input:
>>
Tar: to continue, enter device/file name when ready or null string to quit.
<<

It would be helpful to know what type of tape drive we are talking about. There are multi tape libraries that can be beyond the built in abilities of tar.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Torsten.
Acclaimed Contributor

Re: Tar not working properly

If you rewind the tape and store 6 blocks and receive a "tape full" message, you have either a bad tape or more likely a bad drive.

Try another tape or better change the drive.

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Broflowsky
Occasional Advisor

Re: Tar not working properly

The /etc/password file I'm trying to send to tape is only 6 blocks, I tried a new tape and got the same error message.

The tape I tried is new and empty.
OldSchool
Honored Contributor

Re: Tar not working properly

ok, so a "new" tape failed. Did you do any of the other things mentioned, like:

clean the drive,
check the cabling / terminators

*before* you tried the new tape?

also, most drives now have a "clean me" light now. Is it on now? Was it on before you cleaned it?