manpagez: man pages & more
info tar
Home | html | info | man
[ << ] [ < ] [ Up ] [ > ] [ >> ]         [Top] [Contents] [Index] [ ? ]

The ‘--verbose’ Option

--verbose
-v

Show the files being worked on as tar is running.

--verbose’ (‘-v’) shows details about the results of running tar. This can be especially useful when the results might not be obvious. For example, if you want to see the progress of tar as it writes files into the archive, you can use the ‘--verbose’ option. In the beginning, you may find it useful to use ‘--verbose’ at all times; when you are more accustomed to tar, you will likely want to use it at certain times but not at others. We will use ‘--verbose’ at times to help make something clear, and we will give many examples both using and not using ‘--verbose’ to show the differences.

Each instance of ‘--verbose’ on the command line increases the verbosity level by one, so if you need more details on the output, specify it twice.

When reading archives (‘--list’, ‘--extract’, ‘--diff’), tar by default prints only the names of the members being extracted. Using ‘--verbose’ will show a full, ls style member listing.

In contrast, when writing archives (‘--create’, ‘--append’, ‘--update’), tar does not print file names by default. So, a single ‘--verbose’ option shows the file names being added to the archive, while two ‘--verbose’ options enable the full listing.

For example, to create an archive in verbose mode:

$ tar -cvf afiles.tar apple angst aspic
apple
angst
aspic

Creating the same archive with the verbosity level 2 could give:

$ tar -cvvf afiles.tar apple angst aspic
-rw-r--r-- gray/staff    62373 2006-06-09 12:06 apple
-rw-r--r-- gray/staff    11481 2006-06-09 12:06 angst
-rw-r--r-- gray/staff    23152 2006-06-09 12:06 aspic

This works equally well using short or long forms of options. Using long forms, you would simply write out the mnemonic form of the option twice, like this:

$ tar --create --verbose --verbose …

Note that you must double the hyphens properly each time.

Later in the tutorial, we will give examples using ‘--verbose --verbose’.

The full output consists of six fields:

For example, here is an archive listing containing most of the special suffixes explained above:

V--------- 0/0            1536 2006-06-09 13:07 MyVolume--Volume Header--
-rw-r--r-- gray/staff   456783 2006-06-09 12:06 aspic--Continued at byte 32456--
-rw-r--r-- gray/staff    62373 2006-06-09 12:06 apple
lrwxrwxrwx gray/staff        0 2006-06-09 13:01 angst -> apple
-rw-r--r-- gray/staff    35793 2006-06-09 12:06 blues
hrw-r--r-- gray/staff        0 2006-06-09 12:06 music link to blues

[ << ] [ < ] [ Up ] [ > ] [ >> ]         [Top] [Contents] [Index] [ ? ]

This document was generated on November 1, 2013 using texi2html 5.0.

© manpagez.com 2000-2024
Individual documents may contain additional copyright information.