Using tar for Backups and Restores

In Archiving and Compressing Files, you learned the basics of tar. As it turns out, you already know nearly all you need in order to do manual backups. If you want a comprehensive list of tar options, you can look at the (gigantic) GNU info documents. However, the good news is that you don't need to know very many options, and after reading this section, you should only need tar --help every now and then as a refresher.

Creating Archives

With processors as fast as they are now, and disks getting ever larger, it doesn't make much sense to omit compression for any archive. Recall that you can create a compressed archive of a directory with one command:

tar zcvf archive directory

A large part of making a backup is ...

Get How Linux Works now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.