AFMichael
01-06-2004, 11:12 PM
I tar'd a complete folder on Server A (using A and B for server identities). Now, I FTP'd the .gz file over to server B into the directory I need it in. When I tried to untar it, I get the following error:
tar: Cowardly refusing to create an empty archive
I used the following command to untar:
tar -zcvf file.gz
Does anyone know what this error means and how I can untar the contents?
Originally posted by HScene Mike
I tar'd a complete folder on Server A (using A and B for server identities). Now, I FTP'd the .gz file over to server B into the directory I need it in. When I tried to untar it, I get the following error:
tar: Cowardly refusing to create an empty archive
I used the following command to untar:
tar -zcvf file.gz
Does anyone know what this error means and how I can untar the contents? Remove the "c". You already created this archive...then use this instead tar -xvf file.gz
AFMichael
01-07-2004, 12:32 AM
I tried that and it said that I was missing a field.
bitserve
01-07-2004, 12:53 AM
My tar doesn't have any error message in it related to a missing field. Are you sure that's the exact error message?
It seems more likely that you would be getting one of these two messages:
tar: option requires an argument -- f
tar: This does not look like a tar archive
It's hard to say what you should use to untar your file, unless you say what you used to create the archive. If this really is a tar file, and you gzipped it, you really should have given it the extension ".tar.gz" or ".tgz". But if you really gzipped it as well, you will still want the "z" parameter.
tar -xzvf file.tar.gz
namelayer
01-07-2004, 01:01 AM
What command did you use to tar the folder?
Steven
01-07-2004, 01:51 AM
tar -zcf file.tar.gz directory or files to add
namelayer
01-07-2004, 01:53 AM
try
gzip -d file*
then
tar -xvf file*
Steven
01-07-2004, 01:55 AM
oh i thought u were asking how to make one :)
AFMichael
01-07-2004, 03:20 AM
How would I ftp all of the files over from server A to B via ssh "ftp" command without tarring it? I tried "put *.*" but that didn't work.
Steven
01-07-2004, 03:26 AM
u can try wget ftp://user:pass@host.com:21/*.* i know that will work
AFMichael
01-07-2004, 03:38 AM
Well, this is how the user has his account as when you log in:
src
web>>docs (folder that I want contents in)
How will I transfer over just the contents of the "docs" folder?
Steven
01-07-2004, 03:58 AM
Recursive retrieval:
-r, --recursive recursive web-suck -- use with care!
-l, --level=NUMBER maximum recursion depth (inf or 0 for infinite).
--delete-after delete files locally after downloading them.
-k, --convert-links convert non-relative links to relative.
-K, --backup-converted before converting file X, back up as X.orig.
-m, --mirror shortcut option equivalent to -r -N -l inf -nr.
-p, --page-requisites get all images, etc. needed to display HTML page.
check those options out
AFMichael
01-07-2004, 04:11 AM
Ok, I am a little confused now...
I used ftp://user:pass@host.com/*.*, but it only copied the files in the folder and none of the sub-folders.