tar -zcvf website.tar.gz /var/www
tar xfz foo.tar.gz
To untar in verbose mode, add v to the list of arguments.
Remove the z if it is not a zipped tar
tar -xzf foo.tar.gz -C /tmp/foo/;
To tar all *.txt files into foo.tar.gz
tar cfz foo.tar.gz *.txt
To tar without compressing, remove the
z
from the list of arguments.
tar cf foo.tar.gz some_directory/
tar tvf foo.tar
To gzip a file
gzip filename
uncompress filename.tar.Z
You will need to have installed rpmforge repository on you computer.
yum install p7zip
You can then use 7zip with the command 7za
adds all files from directory “dir1” to archive archive.7z using “ultra settings”
7za -t7z -m0=lzma -mx=9 -mfb=64 -md=32m -ms=on archive.7z dir1
7za x zrchive.7z