help on tar command and its syntax.

help on tar command and its syntax.

Post by Duke » Sun, 22 Jun 2003 15:10:12



Hi,
I want to create a tarball of a filesystem. I am specifically refering
to GNU Tar.

I was just going through the man'ual and found that there is one
option called
--atime-preserve

could someone elaborate more on this. I am a bit confused.
I mean is this supposed to be used during a tarball creation or a
tarball extraction.
and what exactly does that command really mean and do?

and what is this
--checkpoint
and what it really does?

--modification-time
??

--record-number
??

--verify
?? is is while creating or extracting??

Since the man and info are really very brief, I would prefer if the
explanation was a little more detailed.

 
 
 

help on tar command and its syntax.

Post by Robert Newso » Sun, 22 Jun 2003 18:43:09



> Hi,
> I want to create a tarball of a filesystem. I am specifically refering
> to GNU Tar.

> I was just going through the man'ual and found that there is one
> option called
> --atime-preserve

> could someone elaborate more on this. I am a bit confused.
> I mean is this supposed to be used during a tarball creation or a
> tarball extraction.

$ man tar
...
        --atime-preserve
               don't change access times on dumped files

I suspect it means don't change the access time on the files that are being
dumped - every time a file is accessed its atime gets updated with the
current time (for tracking which files have been recently accessed; however,
if you're backing up the [entire] system it makes sense that you may not
want this time updated - every file would end up with a last access time
very similar?).

Quote:> and what is this
> --checkpoint

--checkpoint
               print directory names while reading the archive

A lesser version of -v, ie just display the directories in an archive as
opposed to the complete list of files?  (Try it an see with:

   $ tar --checkpoint -tf somearchive.tar

?)

Quote:> --modification-time

        -m, --modification-time
               don't extract file modified time

When restoring, leave mod time as now as opposed to time originally on file?
  (If all files restored with current time, make's, etc could break).

Quote:> --record-number

        -R, --record-number
               show record number within archive with each message

I presume that the first file is record 1, the second record 2, etc.

Quote:> --verify

        -W, --verify
               attempt to verify the archive after writing it

I presume this is in the good ol' days of tape backups to ensure the data
got written correctly to the file; and after writing it, it rewinds the
destination file and attempts to re-read it and see if it is correct.

 
 
 

1. Help with tar syntax please

Hello,

I'm planning on copying one of my partitions to a new one.  Originally I was
going to use Partimage, but I'd like to try it using tar.  Some searching
has shown me that the following command should work:

cd/home; tar cvpf - * | (cd/newhome; tar xvpf -)

However, I would like to fully understand the command before I use it.
Manual pages tell me what the options c, v, p, f, x do.  I don't know what
the "-", "|", and paranthesis do.  I can see what the command is doing
overall, but I don't understand the specific syntax mentioned.  If anyone
can shed light on this for me, or give me a link to a more comprehensive
explanation of tar, I would appreciate it.

thanks
sluggo

2. Boot 1 CPU only

3. Please help with tar syntax.

4. ATI StereoF/X configuration with Linux?

5. Translating ARP commands from linux syntax to dos command prompt

6. Ineffective password deletion!

7. help: tar syntax

8. HOW TO GET XF86_S3 w/ Vision864-Support ???

9. Need help with command syntax for performing a remote cpio restore

10. backup multiple tar-files on a tape using tar and mt - command

11. tar & mt command. Getting Tar:Unexpected EOF

12. using tar command to extract tarred files

13. Matrox Mystique ands X.