How To: Transfer Accounts from one server to another!

HelloAdam

Well-Known Member
Nov 6, 2005
145
0
166
Hey,

Note to mods: Maybe you can sticky this thread?


-----
I have seen many requests on people trying to transfer accounts from one server to another. In this tutorial or how to guide, you will need root access via SSH on both servers. So lets get started!


Steps on backing up accounts
-------------------------------------

This guide is guessing that you have already made backups of each account you want to transfer to the new server by running the command

Code:
/scripts/cpbackup
in SSH. Depending on your server specs and how many accounts you want to transfer this could take from 5 min to 6 hours. I'm also guessing that you have enabled backups in root WHM and have setup a folder to backup your file. I'm also guessing that you DO NOT, have Incremental backup enabled. Incremental backups do not put each account in its own .tar.gz file. IF you have Incremental backups enabled please disable them by going into root WHM, Main > Backup > Configure Backup. Once you have all backups done, lets really really start transfering accounts.

This guide I'll be using the folder /backup/ to where my files all my accounts have been backup to. (The full path will look something like /backups/cpbackup/daily)

Lets get started!!!

===
1) In SSH cd to backup folder

Code:
[email protected] [/]# cd /backup/cpbackup/
2) Now this is not where your files are located, but rather in a folder called daily, weekly or monthly. Your current backups should be in daily (daily folder is /backups/cpbackup/daily)

3) We are now going to tar the whole daily folder

Code:
[email protected] [/backups/cpbackup]# tar -zcvf backup_daily_folder.tar.gz daily
(Depending on how many accounts or your sever specs this could take anywhere from 5 min to 6 hours, your server may be "laggy" during this time)

4) Once you have that done you should see a file named backup_daily_folder.tar.gz in /backups/cpbackup . We are now going to move this file to your new server!

Code:
[email protected] [/backups/cpbackup]# scp -c arcfour backup_daily_folder.tar.gz [email protected]:/home/
After you enter this, you will be asked for root's password on your NEW server and hit enter when your done. This will then transfer the file to the new server.

Once your done, type

Code:
[email protected] [/backups/cpbackup]# rm -rf backup_daily_folder.tar.gz
(removes the tar file on your old server)

ON YOUR NEW SERVER

5) Go to your /home/ folder

Code:
[email protected] [/]# cd /home/
and tpye this

Code:
[email protected] [/home]# tar -xvfz backup_daily_folder.tar.gz
(This will unpack the tar)

Once again lets delete the tar file

Code:
[email protected] [/home]# rm -rf backup_daily_folder.tar.gz
Now in your new server logon to root WHM and click on the

Backup > Restore a Full Backup/cpmove file

and use the information on that screen to use the accounts on the server.

If you have any questions post them below!

From,
Adam
 

HelloAdam

Well-Known Member
Nov 6, 2005
145
0
166
use whm

Transfers
Copy an account from another server
Copy an account from another server with account password
Copy multiple accounts from another server
Hey,

Or you could use this method. HOW ever, when trasfering large accounts (anything over 300mb is my limit) you have a higher chance of something going wrong, from a lost packet from old server to new server. This process is longer since it takes each account and extracts them one by one, instead of downloading all the accounts and extracting all the accounts together. Hence the reson the first method is the best...

From,
Adam
 

zoelsepur

Registered
Jan 24, 2007
2
0
151
i need help to ransfer

i'm reseller hosting who use whm, how can i transfer my client to my server ?
in my whm i don't see trasfer link in main. thx
 

Chriz1977

Well-Known Member
Sep 18, 2006
191
0
166
Hi

This is how I do it :

1. Log into the server that your copying the accounts from via SSH

2. type '/scripts/pkgacct [username]'

3. type 'scp cpmove-[username].tar.gz [email protected][NEWSERVERIP]:/home/'

4. Log into the [NEWSERVER] via SSH

5. type '/scripts/restorepkg [username]'

DONE!
 

ekhwan

Active Member
Aug 12, 2006
33
0
156
Hi

This is how I do it :

1. Log into the server that your copying the accounts from via SSH

2. type '/scripts/pkgacct [username]'

3. type 'scp cpmove-[username].tar.gz [email protected][NEWSERVERIP]:/home/'

4. Log into the [NEWSERVER] via SSH

5. type '/scripts/restorepkg [username]'

DONE!
Can this be done with multiple accounts? Can you provide a similar step by step guide with scripts please.

Thanks a lot
 

timbernet

Registered
Mar 5, 2005
1
0
151
Hey,
-----
I have seen many requests on people trying to transfer accounts from one server to another. In this tutorial or how to guide, you will need root access via SSH on both servers. So lets get started!


Steps on backing up accounts
-------------------------------------

This guide is guessing that you have already made backups of each account you want to transfer to the new server by running the command

Code:
/scripts/cpbackup
Will this method copy MySQL databases and Addon domains as well?

I have seen mention that the WHM method of transfer doesn't copy those two (maybe it does now, but I guess it didn't use to)

Thanks!
 

AngleOfDeath

Member
Jun 9, 2007
16
0
151
Hi

This is how I do it :

1. Log into the server that your copying the accounts from via SSH

2. type '/scripts/pkgacct [username]'

3. type 'scp cpmove-[username].tar.gz roo[email protected][NEWSERVERIP]:/home/'

4. Log into the [NEWSERVER] via SSH

5. type '/scripts/restorepkg [username]'

DONE!
My friend was a reseller of a server , and he had many clients
He used whm to control them
I have a dedicated server
I want him tobe a reseller in my server
and all his clients will be transfered to my server
So, can I use above guide??


2. type '/scripts/pkgacct [username]'
3. type 'scp cpmove-[username].tar.gz [email protected][NEWSERVERIP]:/home/'
and when I do them, they will create a tar file in my server???
and they will stay in /home???
thanks sir
 

ddeans

Well-Known Member
Feb 13, 2004
296
0
166
Maryland
Will this method copy MySQL databases and Addon domains as well?

I have seen mention that the WHM method of transfer doesn't copy those two (maybe it does now, but I guess it didn't use to)

Thanks!
I use the WHM transfer method a lot and it copies the databases and add on domains for me.
 

ddeans

Well-Known Member
Feb 13, 2004
296
0
166
Maryland
In WHM -> Account Information -> List Accounts -> The very last column says who the owner is, click the edit icon next to them and select who the new owner should be.
 

markhard

Well-Known Member
Apr 22, 2004
252
0
166
My friend was a reseller of a server , and he had many clients
He used whm to control them
I have a dedicated server
I want him tobe a reseller in my server
and all his clients will be transfered to my server
So, can I use above guide??
you can only use the guide above only if you have root access to the old server. if your friend only a reseller, which don't have root access, all i know is to transfer accounts using cpanel full backup feature or from your server's WHM "copy account using account password" which is a boring thing to do if you have a lot of accounts :(
 

ebinfo

Active Member
Oct 5, 2005
31
0
156
Hi

This is how I do it :

1. Log into the server that your copying the accounts from via SSH

2. type '/scripts/pkgacct [username]'

3. type 'scp cpmove-[username].tar.gz [email protected][NEWSERVERIP]:/home/'

4. Log into the [NEWSERVER] via SSH

5. type '/scripts/restorepkg [username]'

DONE!
tried this method and worked like a charm for an account of about 3 gb :)
 

apex2010

Registered
Mar 28, 2010
3
0
51
Backup help

Hello gurus, I have a bit complex scenario. Please help

I have a WHM reseller account with No SSH & root with over 12 GB data and 150 accounts. Now I got a VPS with WHM and root access.

I want to move all my 150 accounts from Server A to Server B (with SSH).

I need help and guidance by which I can get the job done with least efforts. I have R1soft backup facility on my Server A and root access on server B.

If there is any way I can log on to my new server and run a script to get accounts from FTP access of the old server to CP backup restore (complete package & PW) at new server.

Please help
 

mohit

Well-Known Member
Jul 12, 2005
553
0
166
Sticky On Internet
Hello gurus, I have a bit complex scenario. Please help

I have a WHM reseller account with No SSH & root with over 12 GB data and 150 accounts. Now I got a VPS with WHM and root access.

I want to move all my 150 accounts from Server A to Server B (with SSH).

I need help and guidance by which I can get the job done with least efforts. I have R1soft backup facility on my Server A and root access on server B.

If there is any way I can log on to my new server and run a script to get accounts from FTP access of the old server to CP backup restore (complete package & PW) at new server.

Please help

Use copy multiple accounts from another server option in WHM of new server.
you can search more details on this on this forum, i think not less than 100 threads about the same.
 

columbusgeek

Member
Nov 30, 2007
8
1
53
Hi

This is how I do it :

1. Log into the server that your copying the accounts from via SSH

2. type '/scripts/pkgacct [username]'

3. type 'scp cpmove-[username].tar.gz [email protected][NEWSERVERIP]:/home/'

4. Log into the [NEWSERVER] via SSH

5. type '/scripts/restorepkg [username]'

DONE!

Brilliant and perfect advice. Thanks so much.