3 Replies Latest reply: Nov 22, 2007 4:21 AM by abrante RSS

    Can any body brief me about  this syntax  given below

    807567
      I have doubt of using this command on Production server... How best is this.. Can anybody brief me about this syntax.. what exactly this command do...

      $ tar -cvfX - /tmp/exclude *. |* compress -c - > ../archive/file name

      Here i know about "tar -cvfX" but symbols which are highlited i dont have much idea about this.

      Will somebody will help me out in this.
        • 1. Re: Can any body brief me about  this syntax  given below
          807738
          tar -cvfX - /tmp/exclude . | compress -c - > ../archive/file name

          Using the tar utility, archive the current directory, skipping the files listed in the /tmp/exclude file and send it to standard output. Pipe the standard output to the compress utility store the resulting output in the parent directory of the current one in the file named "filename"
          • 2. Re: Can any body brief me about  this syntax  given below
            807567
            timevans wrote:
            tar -cvfX - /tmp/exclude . | compress -c - > ../archive/file name

            Using the tar utility, archive the current directory, skipping the files listed in the /tmp/exclude file and send it to standard output. Pipe the standard output to the compress utility store the resulting output in the parent directory of the current one in the file named "filename"
            Hi Timevans,

            But my question is what are those symbols stands for in the syntax
            i.e

            1. an hyphen* after tar -cvfX -
            2. an pullstop* after /tmp/exclude .
            3. an " *_hyphen"_* after compress -c
            4. an *"_redirection"_* after hyphen after compress -c
            • 3. Re: Can any body brief me about  this syntax  given below
              abrante
              1) stdout
              2) this directory
              3) stdin
              4) file-to-create.

              Aka,
              create a tarfile on STDOUT (1) with the current directory (.), pipe it to compress, which reads the input from STDIN(3) and creates the file (4).

              Clear as gravy :-)

              .7/M.