Tar Quick Reference

This post is intended to be a quick reference for the switches to extract and create tar archives.

Archive creation:

tar cvf filname.tar /files/to/include
tar cvzf filename.tar.gz /files/to/include
tar cvjf filename.tar.bz2 /files/to/include
tar cvJf filename.tar.xz /file/to/include

Archive extraction:

tar xvf filename.tar
tar xvzf filename.tar.gz
tar xvjf filename.tar.bz2
tar xvJf filename.tar.xz
Tagged , , , , , , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published.

Protected by WP Anti Spam