cancel
Showing results for 
Search instead for 
Did you mean: 

Unexpected problem with tar

raiden
Regular Advisor

Unexpected problem with tar

HI ,

When I am trying to put some files through tar on the tape, the files reduce to 0 byte from 2GB .

-rw-rw---- 1 oesinit users 2147479552 Mar 7 13:42 eris1.001
-rw-rw---- 1 oesinit users 2147479552 Mar 7 13:42 eris1.002
-rw-rw---- 1 oesdba users 2147479552 Mar 7 13:42 eris1.003
-rw-rw---- 1 oesdba users 531709952 Mar 7 13:42 eris1.004

tar -cvf /dev/rmt/0m /essdb/extensions/eris1.00*

ll

-rw-rw---- 1 oesinit users 0 Mar 7 13:42 eris1.001
-rw-rw---- 1 oesinit users 2147479552 Mar 7 13:42 eris1.002
-rw-rw---- 1 oesdba users 2147479552 Mar 7 13:42 eris1.003
-rw-rw---- 1 oesdba users 531709952 Mar 7 13:42 eris1.004

What can be the problem .This is a 11.00 System
6 REPLIES
Robert-Jan Goossens
Honored Contributor

Re: Unexpected problem with tar

Hi Raiden,

Have a look at this tar patch.

http://www11.itrc.hp.com/service/patch/patchDetail.do?patchid=PHCO_29229&sel={hpux:11.00,}&BC=main|search|

Regards,
Robert-Jan
raiden
Regular Advisor

Re: Unexpected problem with tar

BUt his problem doesnt seem to be for the problem I am facing.

I dont believe how can tar command reduce a file to 0 byte.. Is anything wrong with the system

But I am able tar small files without any problem then why is this problem occuring for 2Gb files and they are reducing to 0 byte.
raiden
Regular Advisor

Re: Unexpected problem with tar

BUt this patch doesnt seem to be for the problem I am facing.

I dont believe how can tar command reduce a file to 0 byte.. Is anything wrong with the system

But I am able tar small files without any problem then why is this problem occuring for 2Gb files and they are reducing to 0 byte.
Dennis Handly
Acclaimed Contributor

Re: Unexpected problem with tar

>But this patch doesn't seem to be for the problem I am facing.

Why do you say that without reading or installing the tar patch?
tar has been enhanced to support backup of files upto 8GB from the earlier 2GB

>I don't believe how can tar command reduce a file to 0 byte?

Yes, that's strange but try the patch. Or you could make the file readonly.
Johnson Punniyalingam
Honored Contributor

Re: Unexpected problem with tar

Hi Raiden,

I would suspect the while you tar file as per below command. with 1.00* checks while creating 1.001 "creats 0 bytes"

tar -cvf /dev/rmt/0m /essdb/extensions/eris1.00

You either rename "eris1.001" to "eris1.001a"

Than try again,

Patch for "Tar patch" to handle

Thanks,
Johnson

Problems are common to all, but attitude makes the difference
Avinash20
Honored Contributor

Re: Unexpected problem with tar

$ ll
total 64
-rw-rw-rw- 1 siva users 10 Mar 8 13:52 eris1.001
-rw-rw-rw- 1 siva users 12 Mar 8 13:53 eris1.002
-rw-rw-rw- 1 siva users 15 Mar 8 13:53 eris1.003
-rw-rw-rw- 1 siva users 11 Mar 8 13:53 eris1.004

$ tar -cfv /dumps/avi/eris.tar /dumps/zafar/ercis/eris1.00*
a /dumps/zafar/ercis/eris1.001 1 blocks
a /dumps/zafar/ercis/eris1.002 1 blocks
a /dumps/zafar/ercis/eris1.003 1 blocks
a /dumps/zafar/ercis/eris1.004 1 blocks

$ ll
total 64
-rw-rw-rw- 1 siva users 10 Mar 8 13:52 eris1.001
-rw-rw-rw- 1 siva users 12 Mar 8 13:53 eris1.002
-rw-rw-rw- 1 siva users 15 Mar 8 13:53 eris1.003
-rw-rw-rw- 1 siva users 11 Mar 8 13:53 eris1.004


## Here the tar command works fine

$ /usr/sbin/swlist -l product| grep tar
PHCO_13542 1.0 tar(1) exit code for nonfatal errors.

## Please check for the latest patched as advised above
"Light travels faster than sound. That's why some people appear bright until you hear them speak."