Saturday, October 28, 2006

How to do backup with tar?

You can mantain a list of files that you with to backup into a file and tar
it when you wish.

tar czvf tarfile.tar.gz -T list_file

where list_file is a simple list of what you want to include into the tar

i.e:

/etc/smb.conf
/root/myfile
/etc/ppp (all files into the /etc/ppp directory)
/opt/gnome/html/gnome-dev-info.html

1 comment:

Anonymous said...

Commonly Used TAR Switches
Switch Explanation
x Extract the contents of the TAR file
c Create a TAR file
z Gunzip(uncompress) it before extracting, used on file ending in .tar.gz or .tgz
v Verbose - display contents as it is tarring or extracting
f Filename to follow
t List contents of TAR file

Example Explanation
tar -xvf example.tar Extract the contents of example.tar and display the files as they are extracted
tar -cf backup.tar /home/ftp/pub Create a TAR file named backup.tar from the contents of the directory /home/ftp/pub
tar -zxvf example.tgz Gunzip(uncompress) example.tgz and then extract the contents displaying the files as they are extracted
tar -tvf example.tar List contents of example.tar to the screen

Basics of Kubernetes

 Kubernetes, often abbreviated as K8s , is an open-source platform designed to automate the deployment, scaling, and management of container...