The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Google UNIX.COM


UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Extracting from a tar file nmalencia UNIX Desktop for Dummies Questions & Answers 1 03-22-2008 03:42 AM
How to view the contents of .gz file without extracting the file? amitkhiare Shell Programming and Scripting 3 01-13-2008 09:35 PM
Extracting data from text file based on configuration set in config file suparnbector Shell Programming and Scripting 3 08-09-2007 11:25 PM
extracting XML file using sed pujansrt Shell Programming and Scripting 7 06-29-2007 10:18 AM
[Splitting file] Extracting group of segments from one file to others ozgurgul Shell Programming and Scripting 1 09-14-2006 09:17 AM

Reply
 
Submit Tools LinkBack Thread Tools Display Modes
  #1  
Old 03-23-2006
Registered User
 

Join Date: Jun 2001
Location: Tehran, Iran
Posts: 61
extracting from a tar file

Dear experts
I have received a tar file containing several files with full path. Now I need to restore it in another system but when I want to extract files by using
tar -xvf tarfile
it wants to create all files with full paths again in new system in which I don't have enough previleges.
How can I restore these files in my directory without creating their full path??
Thanks and regards
Reply With Quote
Forum Sponsor
  #2  
Old 03-23-2006
Registered User
 

Join Date: Nov 2005
Location: cyberjaya
Posts: 85
try this:

tar -xvf tarfile -C new_dir
Reply With Quote
  #3  
Old 03-24-2006
Registered User
 

Join Date: Jun 2001
Location: Tehran, Iran
Posts: 61
Quote:
Originally Posted by ashterix
try this:

tar -xvf tarfile -C new_dir



I have tried but it doesn't create any file in the new directory even with full path. Is that because I am using Solaris8??
Regards
Reply With Quote
  #4  
Old 03-24-2006
Perderabo's Avatar
Unix Daemon
 

Join Date: Aug 2001
Location: Washington DC Area
Posts: 8,614
See this thread: Untar to different location
Reply With Quote
  #5  
Old 03-24-2006
Registered User
 

Join Date: Jun 2001
Location: Tehran, Iran
Posts: 61
Quote:
Originally Posted by Perderabo


Thank you very much. It was successful.
Cheers
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools
Display Modes




All times are GMT -7. The time now is 12:40 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0