RE: [suse-linux-uk-schools] archiving directories
$ tar cf my_folder > my_folder.tar You can then do $ gzip my_folder.tar to gzip it. -----Original Message----- From: Steve Palmer To: suse-linux-uk-schools@suse.com Sent: 6/24/03 2:04 PM Subject: [suse-linux-uk-schools] archiving directories Hello once more folks, i'm having a little trouble archiving a large number of folders with one simple command & keeping that folder structure intact. I noticed in midnight commander you can do a folder distribution in a tar.gz format but it doesn't appear to perform anything. Gzip doesn't appear to do deal with folders according to the command line listing at least. :( Anyone out there with the knowledge? i'm still too much of a sith to understand these things! ;) ________________________________________________________________________ Want to chat instantly with your online friends? Get the FREE Yahoo! Messenger http://uk.messenger.yahoo.com/ -- To unsubscribe, e-mail: suse-linux-uk-schools-unsubscribe@suse.com For additional commands, e-mail: suse-linux-uk-schools-help@suse.com
--- E Lea
You can then do
$ gzip my_folder.tar
to gzip it.
Or you could take a look here: http://www.linuxgazette.com/issue78/adam.html#keyfiles **cough** -- Thomas Adam ===== Thomas Adam "The Linux Weekend Mechanic" -- www.linuxgazette.com ________________________________________________________________________ Want to chat instantly with your online friends? Get the FREE Yahoo! Messenger http://uk.messenger.yahoo.com/
http://www.linuxgazette.com/issue78/adam.html#keyfiles
So I'm giving this a try as I need a backup script that's better than mine! Something silly I'm sure but I get... tar: compress: Cannot exec: No such file or directory Error is not recoverable: exiting now when I run keyfiles. I've put keyfiles.conf in /etc and the /var/log/keyfiles directory exists. My conf is just... /home/matt/* Any ideas? -- Matt ________________________________________________________________________ Want to chat instantly with your online friends? Get the FREE Yahoo! Messenger http://uk.messenger.yahoo.com/
For some it gives me:
tar: Cowardly refusing to create an empty archive
whenever i try it :/
I've tried applying it to other directories on me box
incase it was the unique structure of the wanted
directories, but its still the same. It does say its
an old command if you don't enter the other parameters
though - differening versions of tar to blame here?
i'm running SuSe 8.0 with stock tar on it.
Any other suggestions are very welcome.
--- E Lea
You can then do
$ gzip my_folder.tar
to gzip it.
-----Original Message----- From: Steve Palmer To: suse-linux-uk-schools@suse.com Sent: 6/24/03 2:04 PM Subject: [suse-linux-uk-schools] archiving directories
Hello once more folks, i'm having a little trouble archiving a large number of folders with one simple command & keeping that folder structure intact. I noticed in midnight commander you can do a folder distribution in a tar.gz format but it doesn't appear to perform anything. Gzip doesn't appear to do deal with folders according to the command line listing at least. :(
Anyone out there with the knowledge? i'm still too much of a sith to understand these things! ;)
________________________________________________________________________
Want to chat instantly with your online friends? Get the FREE Yahoo! Messenger http://uk.messenger.yahoo.com/
-- To unsubscribe, e-mail: suse-linux-uk-schools-unsubscribe@suse.com For additional commands, e-mail: suse-linux-uk-schools-help@suse.com
________________________________________________________________________ Want to chat instantly with your online friends? Get the FREE Yahoo! Messenger http://uk.messenger.yahoo.com/
--- Steve Palmer
For some it gives me:
tar: Cowardly refusing to create an empty archive
whenever i try it :/ I've tried applying it to other directories on me box incase it was the unique structure of the wanted directories, but its still the same. It does say its an old command if you don't enter the other parameters though - differening versions of tar to blame here? i'm running SuSe 8.0 with stock tar on it.
I did post a URL... http://www.linuxgazette.com/issue78/adam.html#keyfiles which ought to help you. However, directly from the command line, try... tar cvf name.tar DIRECTORY substituting the values as you need them. Different versions of tar are not to blame. Whoever it was that suggested using redirected output "> filename.tar" in the last thread is severly mistaken about how tar works..... HTH, -- Thomas Adam ===== Thomas Adam "The Linux Weekend Mechanic" -- www.linuxgazette.com ________________________________________________________________________ Want to chat instantly with your online friends? Get the FREE Yahoo! Messenger http://uk.messenger.yahoo.com/
Yes sorry i know you did. :) Its just that i have very
little time to get it done - the sorta time that isn't
enough to learn new stuff :(
Anyway your little snippet appears to have done the
trick! Thanks for that. I'll probably make use of that
other script as this linux box needs some backing up
of configs anyway.
cheers!
--- Thomas Adam
For some it gives me:
tar: Cowardly refusing to create an empty archive
whenever i try it :/ I've tried applying it to other directories on me box incase it was the unique structure of the wanted directories, but its still the same. It does say its an old command if you don't enter the other parameters though - differening versions of tar to blame here? i'm running SuSe 8.0 with stock tar on it.
I did post a URL...
http://www.linuxgazette.com/issue78/adam.html#keyfiles
which ought to help you.
However, directly from the command line, try...
tar cvf name.tar DIRECTORY
substituting the values as you need them. Different versions of tar are not to blame. Whoever it was that suggested using redirected output "> filename.tar" in the last thread is severly mistaken about how tar works.....
HTH,
-- Thomas Adam
===== Thomas Adam
"The Linux Weekend Mechanic" -- www.linuxgazette.com
________________________________________________________________________
Want to chat instantly with your online friends? Get the FREE Yahoo! Messenger http://uk.messenger.yahoo.com/
________________________________________________________________________ Want to chat instantly with your online friends? Get the FREE Yahoo! Messenger http://uk.messenger.yahoo.com/
--- Steve Palmer
Yes sorry i know you did. :) Its just that i have very little time to get it done - the sorta time that isn't enough to learn new stuff :(
I know what you mean :)
Anyway your little snippet appears to have done the trick! Thanks for that.
No worries... One thing I should have said is that you can also compress it directly with gzip, by using "tar cvfz" (the "z" flag uses gzip). You can also try the "j" flag which uses bzip2 if it is installed.
I'll probably make use of that other script as this linux box needs some backing up of configs anyway.
Cool -- If you do use it, let me know, as I might improve it, if you can think of any features that should be added. You can also set the program to run as a cron-job. But more on that when you get round to it.
cheers!
:) Thomas Adam
--- Thomas Adam
wrote: > --- Steve Palmer wrote: For some it gives me:
tar: Cowardly refusing to create an empty archive
whenever i try it :/ I've tried applying it to other directories on me box incase it was the unique structure of the wanted directories, but its still the same. It does say its an old command if you don't enter the other parameters though - differening versions of tar to blame here? i'm running SuSe 8.0 with stock tar on it.
I did post a URL...
http://www.linuxgazette.com/issue78/adam.html#keyfiles
which ought to help you.
However, directly from the command line, try...
tar cvf name.tar DIRECTORY
substituting the values as you need them. Different versions of tar are not to blame. Whoever it was that suggested using redirected output "> filename.tar" in the last thread is severly mistaken about how tar works.....
HTH,
-- Thomas Adam
===== Thomas Adam
"The Linux Weekend Mechanic" -- www.linuxgazette.com
________________________________________________________________________
Want to chat instantly with your online friends? Get the FREE Yahoo! Messenger http://uk.messenger.yahoo.com/
________________________________________________________________________ Want to chat instantly with your online friends? Get the FREE Yahoo! Messenger http://uk.messenger.yahoo.com/
-- To unsubscribe, e-mail: suse-linux-uk-schools-unsubscribe@suse.com For additional commands, e-mail: suse-linux-uk-schools-help@suse.com
===== Thomas Adam "The Linux Weekend Mechanic" -- www.linuxgazette.com ________________________________________________________________________ Want to chat instantly with your online friends? Get the FREE Yahoo! Messenger http://uk.messenger.yahoo.com/
participants (4)
-
E Lea
-
Matt Johnson
-
Steve Palmer
-
Thomas Adam