Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Steve48

Status
Not open for further replies.

gzip

Programmer
Jan 4, 2008
1
US

I copied a directory with the following command.

tar cvfE - /dir_name | gzip | rsh hostname dd of=/dev/tape/tape0 bs=20b

How can I restore this back.

I tried

rsh hostname dd if=/dev/tape/tape0 bs=20b | gunzip | tar tvf -

Where am I making the mistake.

Thanks.

 
What is the problem ?
What happens with the command you tried ?
 
You're using tar tvf - Is this what you want, ie just to list the contents of the tape? To actally restore them use tar xvf -

HTH.
 
Thanks for the reply.

I have another problem now.

I have a file copied with

tar cvfE - /XXX/yyy | rsh hostname dd of=/dev/tape/tape0 bs=20b

Now I want to restore this into /ZZZ and not onto /XXX

To restote this in /ZZZ

I changed the directory to /ZZZ and issued the following command.
rsh hostname dd if=/dev/tape/tape0 bs=20b | tar xvf -

This restores back to /XXX. (not in /ZZZ)

Pl help !!

Thanks.




 
Hallo Steve48,

sorry but I can't offer a simple solution for your question.
Bur perhaps you could need some piece of advice for further use?
It is wise NOT to use absolute path names in a tar -c

So next time try this:
cd /xxx
tar cvfE - ./yyy | rsh ...

and to restore:
cd /zzz
rsh ... | tar xvf -

hope this helps
 
Thanks for all your help.,

Does any one know where I can down load "gtar" for tru unix .

Thanks.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top