Migrating cPanel Accounts using cPanel Root Password

Is there any way to migrate an account from cPanel using the WHM root password rather than the account password?

Specifically, I'm wondering if nightly backups made by WHM, or backups created by root via the shell, would be able to be migrated into Virtualmin using the cPanel/WHM root password.

Thanks.

Status: 
Active

Comments

Howdy -- thanks for contacting us!

The cPanel migration uses a cPanel backup file to perform the migration.

On the migration form, where it asks "Password for administrator", it needs the account password.

However, if you're using remote backups via SSH, FTP, or similar, you can use any login username/password combination that has access to the files.

RJM Web Design's picture
Submitted by RJM Web Design on Thu, 07/25/2019 - 13:17 Pro Licensee

Thank you, but I'm not quite sure what you mean.

Do you mean if I point the Virtualmin migration tool at /backup on the old server and pull the backup file over that way (or conversely, push the backup file over to /home on the Virtualmin server using SCP), I would then enter "root" for "Username for domain" and root's password for "Password for administrator"?

Wouldn't that make root the virtual server owner and mess up permissions?

Or do "Username for domain" and "Password for administrator" in that page refer only to the file permissions for the archive, not to the new virtual server that will be created?

Also, does it matter whether the backup archive was created as a user or as root?

Thanks,

Richard

There's two password options on the Migrate Virtual Server form.

One is an SSH or FTP password.

One is a password for the "Password for administrator".

The SSH or FTP password has to be the password to login via SSH/FTP to access the backups. If the backups are stored on the Virtualmin server, you wouldn't have to specify that password at all.

The "Password for administrator" option has to be the password for the cPanel account being migrated, it can't be root.

It doesn't matter what user makes the backups, it just matters that they are backups of the cPanel accounts. If they are backups of the cPanel accounts, you would need to be using the cPanel username and password in the "Username for administrator" and "Password for administrator" fields.

RJM Web Design's picture
Submitted by RJM Web Design on Fri, 07/26/2019 - 06:58 Pro Licensee

Okay, thank you, Andrey. So the short answer is that you need the account password to actually migrate the account, regardless of how you're accessing the backup file. You can't do it with the root password.

I'm pretty sure there's a way around this. But I'm very sure I don't know what it is. On a cPanel server, root can use cPanel backup files to restore accounts made on the same or another cPanel server, without needing their passwords. Buried somewhere in that process is a little trick I'd love to uncover because I'm absolutely certain I'm going to have some clients who don't know their passwords.

Of course, I can always reset the passwords and create new backups to migrate the accounts, and then let the clients change the passwords to whatever they like. It would just be nice to know how WHM manages to do it without the passwords. I may make a hobby of figuring that out.