cPanel Migration

Hi there,

I am in a position now to start migrating all my cPanel accounts over but I have come across a problem.

I have taken the back up and it creates as tar.gz file but when I download it from the cPanel server it drops the .gz bit. I have been through the migrate server form without touching the file and also by changing the file name to add the .gz on the end.

Each time the backup fails to migrate I get the following message:

… validation failed : Not a cPanel tar.gz file : Un-archive command failed : gunzip: /tmp/.webmin/569380_1_migrate.cgi: unexpected end of file tar: Read 1732 bytes from - tar: Unexpected EOF in archive tar: Unexpected EOF in archive tar: Error is not recoverable: exiting now

Am I doing something wrong?


Hey James,

I’m not actually sure off-hand.

I know that databases come over. I don’t know about mboxes. Subdomains should come over fine, though I never could figure out how to create one type of domain that cPanel talks about in their docs…the option just wasn’t there on our test server.

It is definitely something you’ll want to try on a test box until we’re calling things stable and roll an official release. One of the reasons for the early adopter period is to try out the more complex new features (like cPanel import) to be sure everything ends up in the right place, and we don’t mysteriously lose any data in the process.

To be more succint: cPanel import ought to bring over everything that is in your backup file, but probably won’t be successful in EA1. We’d like to know where things fall down. Tell us what goes wrong and we’ll fix it (we may need you to send us a backup file that exhibits the problem).

On this same topic, if anyone wants Virtualmin Professional to support import from another virtual host administration system, make a backup file containing all available features and send it to me (or send me a link to where I can download it).

You actually want to MIGRATE the server, just like your title says. By default it’s set to cpanel migration.

OOOps! Apparently the GPL version doesn’t migrate servers. The VMPro version actually has a migrate server option. Although, you can still build a server and FTP the site over :wink:

Apparently the GPL version doesn’t migrate servers.

Isn’t that silly? We’ll fix that. Next release of GPL will have migration capabilities.

You’re using a browser that is “helping” by uncompressing the file. Don’t let it do that. Save the file as a tar.gz file.

Or, even better, save it to the cPanel server rather than trying to copy it to your desktop machine, and then copy it over to the Virtualmin server using scp. You can’t reliably use your browser to deal with large files, anyway (http has somewhat unfortunate timeouts and such when dealing with very large files…it can be somewhat sensitive to network sluggishness and such). We actually originally tried to avoid letting people use the browser at all for uploading and downloading backup files, because it is so unreliable (and we can’t make it more reliable because it’s due to problems with the protocol and the browsers)…but people really wanted it for quick and dirty backup tasks. And since it works well enough for small backups, it makes it more likely to trip people up when the backups get really big.

Thanks Joe - at least I know now why it’s not working.

However being totally new to this how exactly do I transfer using SCP as its something I am not too familiar with.

Login to via ssh to the cPanel server and cd to the location of the file, and then type:

scp source-filename root@virtualmin.server.address:/root/

Where source-filename is the name of the backup file to be transferred, and virtualmin.server.address is the IP or hostname of the destination Virtualmin server. And /root/ is the directory where you want to put the file on the destination server.

Punch in the password of the new server, and wait for it to transfer.

If you’ve also never used ssh, now’s a great time to learn. If you’re on Windows google “putty”, and download it. It is a very nice free ssh client. If you’re on Mac OS X, just open a terminal and type “ssh -l root virtualmin.server.address”, or “ssh -l root cpanel.server.address” and enter the root password.

The ssh tools (scp is one of them, sftp is the other) are awesome tools to know how to use well. It’s definitely worth your time to spend a few minutes coming to grips with them. They’re all easy to use. I’ve taught folks the basics in a few minutes several times in the past.

Thanks Joe,

Finally got round to giving it another go and I have managed to migrate my first server. Wonderful.

It was however easier than I though as when taking the back up I set the option to back up to SCP and put in the details for my server and when it was done there it was.

Thanks again.