Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
wiki:tar [2011/05/11 02:28] – [.rar] Guy | wiki:tar [2011/08/07 00:23] (current) – [tinycore.gz, and microcore.gz] Guy | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== Extract tgz, tar.gz, tbz, tar.bz2, and tar.xz | + | ====== Extract |
+ | |||
+ | If the file is owned by root, you may need to use sudo. | ||
+ | |||
+ | ==== tgz, tar.gz, tbz, tar.bz2, and tar.xz ==== | ||
To extract a tgz, tar.gz, tbz, tar.bz2, or tar.xz file, open the terminal and type | To extract a tgz, tar.gz, tbz, tar.bz2, or tar.xz file, open the terminal and type | ||
Line 6: | Line 10: | ||
tar -xvf filename</ | tar -xvf filename</ | ||
- | If the file is owned by root, you may need to use sudo. | ||
- | ==== Other File Types ==== | + | ==== .bz2 ==== |
- | ==== .zip ==== | + | < |
- | + | ||
- | < | + | |
==== .gz ==== | ==== .gz ==== | ||
Line 18: | Line 19: | ||
< | < | ||
- | ==== .bz2 ==== | + | Note: Files such as tinycore.gz and microcore.gz are different. See below. |
- | + | ||
- | < | + | |
==== .rar ==== | ==== .rar ==== | ||
< | < | ||
+ | |||
+ | ==== .xz ==== | ||
+ | |||
+ | < | ||
==== .Z ==== | ==== .Z ==== | ||
Line 30: | Line 33: | ||
< | < | ||
- | ==== .xz ==== | + | ==== .zip ==== |
- | < | + | < |
==== .7z ==== | ==== .7z ==== | ||
Line 45: | Line 48: | ||
.tlz is equivalent to .tar.lz | .tlz is equivalent to .tar.lz | ||
.txz is equivalent to .tar.xz | .txz is equivalent to .tar.xz | ||
+ | |||
+ | ==== tinycore.gz and microcore.gz ==== | ||
+ | |||
+ | To extract files such as tinycore.gz and microcore.gz, | ||
+ | |||
+ | < | ||
+ | zcat tinycore.gz | sudo cpio -i -H newc -d</ | ||
+ | |||
+ | For more information, | ||
+ | |||
+ | ==== .deb ==== | ||
+ | |||
+ | To extract a .deb file, use | ||
+ | |||
+ | < | ||
+ | ar vx filename.deb | ||
+ | tar -xzvf data.tar.gz</ | ||
+ | |||
+ | Another option is to use | ||
+ | |||
+ | < | ||
+ | ar p filename.deb data.tar.gz | tar xz</ | ||
+ | |||
+ | ==== .rpm ==== | ||
+ | |||
+ | To extract an .rpm file, use | ||
+ | |||
+ | < | ||
+ | rpm2cpio filename.rpm | cpio -vid</ | ||
+ |