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!

Tar question

Status
Not open for further replies.

babeo

Technical User
Mar 30, 2000
398
CA
Hi
I want to do the backup FileA on my Solaris directory (not tape) /MyhomeDir using “tar”, and here is my command, but it seems like it does not work properly, could someone tell me what I am doing wrong. Thanks

/MyhomeDir% Tar cvf NewTarFile FileA

thanks
 
is ok, tar is lowercase, a convention is to use a .tar extention (but this is in unix not necessary), is tar in your path? what's the err msg ?
tar cfv xxx.tar filea -----------
when they don't ask you anymore, where they are come from, and they don't tell you anymore, where they go ... you'r getting older !
 
Hi jamisar,

No error at all, however, when I try to look at the file, it seems the file is not compact, I am still able to read the file through. Maybe I am confuse here:

I try to tar bunch of files together into one single file(eg: 10 files, each of them about > 800MB, and each of them has been prezip)

1) The 'tar' is to "glue" all the file together and it also packs/compress the file too?
2) or 'tar' is just to 'glue' all the file together, but no compression? If this is the case, then that is why I tar them, add up all files size and have it equal to the size of the tar file.

thanks
 
Tar doesn't compress automatically (though there are versions which will). Following the creation of the 'tarball' (which is where the word tar comes from in this context), you can use compress, gzip or similar to compress your file. I think GNU tar does have an autocompression switch. HTH.
 
In GNU tar, use tar czf filename.tar.gz files to compress with gzip, and tar cZf filename.tar.Z files to use compress. Use xzf and xZf respectively to extract the files again.

If you're only doing one file, just leave the tar step out and simply do gzip filename and it will automatically replace it with the compressed file filename.gz. Annihilannic.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top