answersLogoWhite

0


Best Answer

in a linux machine :

tar -cvf FileOrDirectory.tar FileOrDirectory

# or to gzip it at the same time...

tar -czvf FileOrDirectory.tgz FileOrDirectory

User Avatar

Wiki User

11y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: How do you create a tar file from the command line?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

How do you extract a tar file from the command line?

tar -zxvf <tarball-file>


How directories can be imported and exported in Linux?

The usual way of copying or moving directories is to use the tar command. The resulting tar file (called a tarball) can also be compressed to save time in moving it to another system. To create a tar file for export, use a command such as: cd directory tar cvf export.tar . This will create a file called export.tar that contains all of the elements of that directory. You could also compress that tar file by: gzip export.tar Which creates an export.tar.gz file. Then, copy or move the file to another place or system. To import it: gunzip export tar if the file was compressed, then use tar to extract the contents: cd directory tar xvf export tar


What is tar command in Linux?

tar is one of the basic commands in Unix. tar command in unix is used for achriving purpose, you can create archive, update or extract from archieve using tar command in unix.you can also create compressed archieve by combining bzip2 and gzip along with unix tar command


How do you install packages with tar?

The 'tar' utility is not usually used to install packages; it would consist of a source package that has to be configured, compiled, and then installed. The tar file you receive usually is in a compressed format as well.The sequence of events with a tar file (sometimes called a tarball) is to do the following:Uncompress the tar file if it is compressedExtract all of the files into a directory with 'tar xvf filename'Run the ./configure command in the root directory of the package if it existsRun the 'make' command on the resultRun the 'make install' command if everything compiled and linked successfully.


How do you use tar command of UNIX in vi editor?

You don't. The 'tar' command has nothing to do with the 'vi' editor; it creates an archive files and the vi editor modifies the content of a file.


How do you create archive file in UNIX or Linux Operating System?

For TAR archives, you use tar -cvf .


How do you create a tar a file?

in a linux machine : tar -cvf FileOrDirectory.tar FileOrDirectory # or to gzip it at the same time... tar -czvf FileOrDirectory.tgz FileOrDirectory


Where can one learn more about Linux's TAR command?

The TAR command is Create Tape ARchives and is used by Linux and Unix. Information and explanations can be found on the linfo and computerhope websites.


How do you compress a folder in AIX?

The usual approach is to create a 'tar' file first of the directory and then compress the tar file. This is also safer because it leaves the original directory intact.


How do you open targz files?

In linux command line : tar -zxvf /path_to_your_file/filename.tar.gz


What mode do you ftp tar files in?

Transfer tar files in binary mode.WARNING: some ftp clients go back to ascii mode when you enter an ls or dir command. To be safe, always use the binary command before getting a binary file.


Tbz extension refer to which file type?

It is a tar file file compressed using BZIP. "Bzipped-tar-file"