LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   extracting .bz2 files (https://www.linuxquestions.org/questions/linux-newbie-8/extracting-bz2-files-103655/)

mjkramer 10-13-2003 11:47 PM

extracting .bz2 files
 
So, how does one extract .bz2 files?

rahulsundaram 10-14-2003 12:11 AM

tar jxvf packagename.tar.bz2

for .gz files

tar cxvf packagename.tar.gz


regards
rahul sundaram

miknight 10-14-2003 03:23 AM

Quote:

Originally posted by rahulsundaram

for .gz files

tar cxvf packagename.tar.gz

Umm, I'm pretty sure that for tar.gz files you go

tar zxvf packagename.tar.gz

See 'tar --help' for more info.

Also it's useful to remember that what you're actually doing is decompressing the tar file, and THEN unpacking the tar file.

If you see a file like readme.txt.bz2 then it's probably a text file that has been bzipped (not packed into a tar file). So in this case you decompress the file by going

bzip2 -d readme.txt.bz2 which will leave you with readme.txt (readme.txt.bz2 will be gone).

Crashed_Again 10-14-2003 04:14 AM

Yeah. The -c switch is for creating a tar archive.

rahulsundaram 10-16-2003 09:23 PM

hi

oops i goofed up sorry

regards
rahul sundaram


All times are GMT -5. The time now is 07:00 AM.