Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-30-2006 08:37 PM
10-30-2006 08:37 PM
tar
i have a tar file xx.file it contains files with absolute path.
/Arr/AA/BB/file1
/Arr/AA/BB/file2
/Arr/AA/BB/file3
.
.
..
I need to untar the in a different path
/XX/YY/TT
how can I have all the files into /XX/YY/TT ?
thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-30-2006 08:51 PM
10-30-2006 08:51 PM
Re: tar
you can't with standard tar. However you can use gnu tar (gtar) or pax with -s option.
http://hpux.cs.utah.edu/hppd/hpux/Gnu/tar-1.15.1/
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-30-2006 08:57 PM
10-30-2006 08:57 PM
Re: tar
use 'pax' to read back the tarfile content under a different path.
BTW., it is not a good idea anyway, to store absolute pathnames in a tarfile.
cd resultdir
pax -r -s:/Arr/AA/BB:XX/YY/TT: /pathname/xx.tar
mfG Peter
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-31-2006 05:32 PM
10-31-2006 05:32 PM
Re: tar
#tar xf mw.tar
tar: Removing leading `/' from member names
Don't be root.
There is a special option for not removing leading '.' (-P, check manpage).
JP
P.S. Don't ask the same question twice please...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-31-2006 08:05 PM
10-31-2006 08:05 PM
Re: tar
can you please update. Is this problem answered ?
For earlier similar problems please see:
http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=17465
http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=132348
http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=263946
If the answers were useful, please allocate points as per: http://forums1.itrc.hp.com/service/forums/helptips.do?#28
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-31-2006 08:12 PM
10-31-2006 08:12 PM
Re: tar
Peter Nikita gave you the solution...
I do the same:
Copy the archive to
the relative location in
which you wish to untar it.
Then, execute the following
command:
pax -r -s ',^/,,' -f file.tar
All the best
Victor