1848746 Members
4452 Online
104036 Solutions
New Discussion

Re: tar error

 
Sarjerao
Frequent Advisor

tar error

Hello
When I trying tar -tvf/xvf to tar file i am getting "An error occurred while reading from the media." There are many tar files in my system and all giving same error. Is there block size issue?
12 REPLIES 12
Ludovic Derlyn
Esteemed Contributor

Re: tar error

Hi

What is your command used?

Regards

L-DERLYN
Yogeeraj_1
Honored Contributor

Re: tar error

hi,

do you get the same error message when you create the tar on the file system?

e.g.
tar -cvf /tmp/MYFILES.TAR ./dir/*


kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Rasheed Tamton
Honored Contributor

Re: tar error

Hello,

It usually relates to the block size. Is the tar archive made on hp-ux or any other OS.
You might have to play with the block size. The default on hp-ux is 20.

man tar
Apai
Occasional Advisor

Re: tar error

if you are using tape, is the tape is writable? maybe someone might have lock it . :p
V. Nyga
Honored Contributor

Re: tar error

Hi,
(copied from you second thread)

why do you mean that's a block size issue?
I think it could be only if this files are not created by yourself (from SGI for example).

"An error occurred while reading from the media."

From your first message it seems like you want to read from tape, but if you say: 'There are many tar files in my system'
then you've maybe not given the right path for the tar-file.

What's your command?
And how big are your tar files and which path does they have?

Volkmar
*** Say 'Thanks' with Kudos ***
Rasheed Tamton
Honored Contributor

Re: tar error

Hello,

Try with the below block sizez
tar tvbf 10 tarfile (block size 10)
tar xvbf 1 tarfile (block size 1)
Sarjerao
Frequent Advisor

Re: tar error

i am not unsing any tape drive. All files received from software vendors and giving error while untar. Sendor also don't know how files are created.
Sarjerao
Frequent Advisor

Re: tar error

i am not using any tape drive. All files received from software vendors and giving error while untar. Sendor also don't know how files are created.
Rasheed Tamton
Honored Contributor

Re: tar error

Run the above command on the tarfiles.
For example, the tar file name is tarfile;
run the command :

tar tvbf 1 tarfile (give us the output)

if it does not work
do the file command

file tarfile

give us the output of both the commands.
V. Nyga
Honored Contributor

Re: tar error

Hi again,

so what is your command you use?
Please more infos.

Use 'file ' to check if it is zip (or winzip) instead.
You also could try with winzip (at a pc) to read tar-file.

The vendor don't know how it was created?
Strange ...

Volkmar
*** Say 'Thanks' with Kudos ***
Sarjerao
Frequent Advisor

Re: tar error

Thanks for help.
my vendor resend tar files and which are working fine.
Sarjerao
Frequent Advisor

Re: tar error

Thanks