How to Tar a Directory

|

The most common way to deliver a batch of files from a Linux system is by using the “Tar” command. When you tar a directory, you can easily roll up a group of files. This eases the delivery of a group of files in precession-intensive applications such as the File Transfer Protocol and peer-to-peer applications, as well as simply archiving

Step1 Open a terminal session on your Linux PC by clicking on the terminal icon at the bottom bar or by clicking on the "Home" button and looking for “Xterm.”

Step2 Once in the terminal, type “tar -cf”; do not press "Enter." The “c” indicates that you are creating a tar file, and the “f” indicates that the tar is to be given the name you specify

Step3 Press the spacebar and type in the full name (with extension) you want for the file. If you’re tarballing pictures, for example, you might want to type “pictures.tar.”

Step4 Press the spacebar and enter the path of the directory. Remember that the path should be relative to the location you’re issuing the command from. For example, if the full path of the directory is “hdd0\home\user\pictures” and you issued the command from the “User” directory, then you’d simply have to put “pictures\” in this area.

Step5 Press "Enter" to complete the tar of the directory. Make sure all your commands are accurate before pressing "Enter."

0 comment:

Post a Comment

 

©2009 computer technology World | Template Blue by TNB