tar: removing leading '/' from member names
i am trying to take a tar by command as below.
tar -cvf app-bkp040413.tar /home/user/app the tar is created with the following warning tar: removing leading '/' from member names how can i overcome this. TIA Arif |
from "man tar"
Code:
-P, --absolute-names |
appreciated. thnx
so do i need to use "P" again while extracting the tar file? Also found that the size of tar file is different when used with "P" option and otherwise. |
Quote:
|
The problem with using -P will be it will restore to the exact same place, overwriting anything already there. You don't always want that, so it defaults to stripping the leading '/' so you can re-locate the files anywhere and maybe just pick out stuff you want or diff the files from the extant ones.
|
By the way cpio, works this way by default. However common cpio formats odc and newc have file size limitations that make them unsuited for backups on modern systems. However some cpio implementations, such as bsdcpio (part of libarchive) can output in modern formats (e.g. pax) without such limitations.
|
All times are GMT -5. The time now is 11:46 PM. |