The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > OS Specific Forums > SUN Solaris
Google UNIX.COM



View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
  #8 (permalink)  
Old 05-19-2008
sparcguy sparcguy is offline
Registered User
 

Join Date: Nov 2006
Posts: 252
actually I just want to add. For safety reasons whenever you tar anything always try to have the practice to specify relative instead of absolute path.

example:
absolute path will be tar cf /tmp/abc.tar /etc
relative path will be tar cf /tmp/xyz.tar ./etc <-- "."

The danger of using absolute path is when you un-tar the file it will overwrite existing folder.


example:
cd /tmp
tar xf abc.tar will extract and overwrite existing /etc
tar xf xyz.tar will extract into /tmp only
Reply With Quote