Jump to content

Recommended Posts

Posted

I have some domains on another host that I want to bring over to TCH. The other host does not have a control panel, and most things have to be done thru SSH and secure CRT.

 

What I'm trying to figure out how to do is to create a .tar file of the entire site contents and then bring that one file over and extract it thru cpanel. What ever I try is not working.

 

Here's what I've tried:

 

at the command prompt I type:

tar cvf archive.tar -C directoryName

 

It does create a file called archive.tar

 

Then I uploaded that file to TCH thru Cpanel file manager. But when I click on that file name, there is no menu choice on the right to extract the files. I tried downloading the file and trying to use WinZip locally on it, and it did not recognize the file as being an archive.

 

So it seems to me that what I'm doing on the other server is not actually creating an archive file.

 

Does anyone know what I need to be doing thru SSH to actually create a useable archive file?

 

Thanks alot,

 

Miriam

Posted

Hi Miriam,

 

Once you have uploaded the tar file to the new location on your website

open cpanel then click on File Manager

then go to the location where you uploaded the file then you should see the file name

on the left

if you click on the file name a menu should apear top right that will have extract files

 

Hope this helps :wallbash:

Posted

Just a wild guess here, maybe you need to compress the archive too? Add z to the tar command options:

tar cvfz archive.tar.gz -C directoryName

 

EDIT:

And use 7-Zip for handling tar archives, last time I tried it, WinZip couldn't open them.

http://www.7-zip.org/

Posted

I know cPanel lets you decompress tarballs (.tar.gz files) but I'm not sure if it supports TAR files, so perhaps you should do as Ayman suggested and use a tarball instead.

Posted
Just a wild guess here, maybe you need to compress the archive too? Add z to the tar command options:

tar cvfz archive.tar.gz -C directoryName

 

EDIT:

And use 7-Zip for handling tar archives, last time I tried it, WinZip couldn't open them.

http://www.7-zip.org/

 

I followed your instructions, and this time in Cpanel when I clicked on the uploaded .tar.gz file, the Extract files menu selection was available. But it looks like on the other server, no files were actually included in the archive, and on the TCH server, no files were extracted. It's looking like I'm going to have to move all of the files manually. :(

 

Thanks,

Miriam

Posted

did you check the size of the tar file ? was it greater than 0 bytes ?

 

Also when you extracted its contents did you check that it extracted them into a sub directory ?

 

also if you would you could email the file and I will untar it on my side and check it for you

Posted
tar cvfz archive.tar.gz -C directoryName

 

Drop the -C. That's for changing directories (and why you have an empty archive).

 

The correct syntax (complete with compression as Ayman suggested) would be:

tar cvfz archive.tar.gz directoryName

 

...with the assumption that directoryName is a subdirectory of the one you are sitting in.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...