Linux Backup and Recovery how to use tar command

Using tar Command in almost all Linux Flavour's

The tar command is most often used to archive files. Its
command syntax is
where optionsis the list of commands and options for tar, and
filesis the list of files to add or extract from the archive.

For example, the command
# tar options files
# tar cvf backup.tar /etc

# tar cvf backup.tar /etc
packs all of the files in /etc into the tar archive backup.tar.
The first argument to tar, “cvf”
c tells tar to create a new archive file.

v forces tar to use verbose mode, printing each file name as it is

f option tells tar that the next argument, backup.tar, is the
name of the archive to create.

The rest of the arguments to tar are the file and directory names
to add to the archive.

# tar xvf backup.tar
Will extract the tar file backup.tar in the current directory.
Old files with the same name are overwritten when extracting files
into an existing directory.
Before extracting tar files it is important to know where the files
should be unpacked.

# tar tvf backup.tar
can be used to display a listing of the archive's files without
extracting them.
You can see what directory the files in the archive are stored
relative to, and extract the archive in the correct location.

Forex Trading