linux:tar
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| linux:tar [2022/06/04 09:08] – levor | linux:tar [2024/03/23 16:59] (current) – levor | ||
|---|---|---|---|
| Line 3: | Line 3: | ||
| ^Example^Explanation / Remarks^ | ^Example^Explanation / Remarks^ | ||
| - | |tar -czvf / | + | |tar -czvf / |
| |tar -xzvf / | |tar -xzvf / | ||
| + | |**Using find:**|| | ||
| + | |find /var/log -iname ' | ||
| + | |find . -type f > list_of_files.txt && tar -czf bu_file.tar.gz -T list_of_files.txt|| | ||
| + | |find . -type f -exec tar -czf {}.tar.gz {} \;|!<- TODO! FIXME| | ||
| - | + | ^Flag^Same as^Explanation / Remarks^ | |
| - | ^Flag^Explanation / Remarks^ | + | |c| |create a new archive file| |
| - | |c|create a new archive file| | + | |f| |next parameter is the filename| |
| - | |z|use gzip compress or uncompress| | + | |r|%%--%%append|append file(s) to tar file| |
| - | |v|verbose output | + | |t|%%--%%list|list contents of file| |
| - | |f|next parameter | + | |T| |next param is filename |
| - | |x|extract compressed file| | + | |v| |verbose output - show details while running| |
| + | |x| |extract compressed file| | ||
| + | |z| |use gzip compress or uncompress| | ||
| + | |-| |dash, as last symbol -> use stdin as input. usually, together with another program like **find**| | ||
linux/tar.1654333706.txt.gz · Last modified: 2022/06/04 09:08 by levor
