Jump to content


Register a free account to unlock additional features at BleepingComputer.com
Welcome to BleepingComputer, a free community where people like yourself come together to discuss and learn how to use their computers. Using the site is easy and fun. As a guest, you can browse and view the various discussions in the forums, but can not create a new topic or reply to an existing one unless you are logged in. Other benefits of registering an account are subscribing to topics and forums, creating a blog, and having no ads shown anywhere on the site.

Click here to Register a free account now! or read our Welcome Guide to learn how to use this site.

Photo
- - - - -

How To Create An Archive Using Tar In Linux


  • Please log in to reply
No replies to this topic

#1 Grinler

Grinler

    Bleep Bleep!


  • Admin
  • 40,253 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:USA
  • Local time:04:30 PM

Posted 24 January 2006 - 09:29 AM

How to create an archive using tar in Linux



Guide Overview

This guide explains how to create an archive of files using the Linux/Unix tar command.

Requirements

Shell Access or Console

Instructions
  • Connect to a shell or open a terminal/console on your Linux/Unix machine.

  • To create an archive of a directory and its contents you would type the following and press enter:
    • tar -cvf name.tar /path/to/directory

      Substitute the name.tar with the name of the tar file you would like to create and substitute the directory name for the full path to the directory you would like to archive.
  • To create an archive of certfain files you would type the following and press enter:
    • tar -cvf name.tar /path/to/file1 /path/to/file2 /path/to/file3

      Substitute the name.tar with the name of the tar file you would like to create and substitute the the various files for the full path to the files you would like to archive. Each file you would like included in the archive should be seperated by a space.


BC AdBot (Login to Remove)

 





5 user(s) are reading this topic

0 members, 5 guests, 0 anonymous users