LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-22-2005, 10:35 PM   #1
ericpolanco
LQ Newbie
 
Registered: Feb 2005
Posts: 17

Rep: Reputation: 0
HELP WITH TAR of ROOT


Hello All, I'm not a Linux newbie but i feel like one right now :-(.

Okay, i have tried everything to tar my `/' directory and it's not working point blank. Problem is, i can tar / but the hard drive is too small to actually tar it here so i have to mount an nfs mount and then tar it there of course i'm using gzip.

I'm trying to exclude /proc and /mnt but it won't happen.

I have tried using exclude files...
Sometimes i won't get errors and it makes a 45 kb file... yeah right....

Anyone please help me!!!!
aRGGGGG

tar cvfzX file.tar.gz excludefile /

didn't work

tar cvfzXP file.tar.gz excludefile /

didn't work

Thanks for any help guys
 
Old 02-23-2005, 12:14 AM   #2
Sepero
Member
 
Registered: Jul 2004
Location: Tampa, Florida, USA
Distribution: Ubuntu
Posts: 734
Blog Entries: 1

Rep: Reputation: 32
According to the man page, the exclude file should be directly after the "-X".

tar cvfzX excludefile file.tar.gz /
 
Old 02-23-2005, 02:30 AM   #3
ericpolanco
LQ Newbie
 
Registered: Feb 2005
Posts: 17

Original Poster
Rep: Reputation: 0
Unhappy

Nope, that's not it....
I get an error saying file file.tar.gz doesn't exist, it;'s looking for the exclude file after file.tar.gz...

i can't believe i can't get this work..

Thanks man.

Any more help will be welcomed with digital cookies
haha
no milk sorry

Thanks
 
Old 02-23-2005, 02:39 AM   #4
Sepero
Member
 
Registered: Jul 2004
Location: Tampa, Florida, USA
Distribution: Ubuntu
Posts: 734
Blog Entries: 1

Rep: Reputation: 32
Doh!
Did we forget the dash?

tar -cvfzX excludefile file.tar.gz /
 
Old 02-23-2005, 07:59 AM   #5
vls
Member
 
Registered: Jan 2005
Location: The grassy knoll
Distribution: Slackware,Debian
Posts: 192

Rep: Reputation: 31
Quote:
Originally posted by Sepero
Doh!
Did we forget the dash?

tar -cvfzX excludefile file.tar.gz /
You don't have your option arguments ordered correctly:

tar -c -v -z -X excludefile -f file.tar.gz \

With verbose options

tar --create --verbose --gzip --exclude-from=excludefile --file=file.tar.gz \

Any option that takes an argument such as "X" of "f" needs the arg
immediately after that option.
 
Old 02-23-2005, 10:36 AM   #6
ericpolanco
LQ Newbie
 
Registered: Feb 2005
Posts: 17

Original Poster
Rep: Reputation: 0
I think that might have worked.....

I actually thought it was the ordering of the options but i had that wrong all along....

I'm actually running it right now and i'll see how if it works....

Thanks for the post and all the help people...

I'll keep it posted...

Thanks vls
Thanks Sepero

Eric
 
Old 02-23-2005, 12:45 PM   #7
Sepero
Member
 
Registered: Jul 2004
Location: Tampa, Florida, USA
Distribution: Ubuntu
Posts: 734
Blog Entries: 1

Rep: Reputation: 32
Thanks for clearing that up vls. I looked over the man again and it's not very clear about "-f file". Personally I don't ever use exclude, good work pointing it out.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
how can i decompress this tar.tar file? hmmm sounds new.. tar.tar.. help ;) kublador Linux - Software 14 10-25-2016 02:48 AM
tar tar cvf - . | (cd /root/; tar xvf -) ewt3y Linux - General 10 02-19-2014 10:55 AM
a tough question 4 u, problem in extracting tar & tar.gz files p_garg Linux - General 5 11-08-2010 11:02 AM
.rpms, .tar.gz, .tgz, .src.rpm, & .tar.bz2 whoots Mandriva 10 10-18-2003 12:08 PM
Diferance between rpm, tar, tar.gz, scr.tar, etc mobassir Linux - General 12 08-21-2003 06:30 AM


All times are GMT -5. The time now is 03:50 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration