Problem moving an account

aquagerbil

Member
Mar 17, 2004
11
0
151
I have an account on one server I am trying to move to another. It has about 340 DB's. When I move it, many come over blank, but they are not blank on the source server. I have tried the GUI and the /scripts/ option.

Any idea how I can move this customer's 340ish database's correctly?
 

lijeeshsd

Active Member
Apr 22, 2005
33
0
156
If you have shell access to both the servers, then a simple shell script can do this job.
 

aquagerbil

Member
Mar 17, 2004
11
0
151
I do have root shell access to both servers. I did the /scripts/package /scripts/restore options. I also did a mysql rsync of the 340 DB's. The trouble comes in if I do a mysqldump of the mysql and then import into the new server, it gets a lot of crap entries as the source mysql has grants for many many accounts.

Any more specific about the script you would use?
 

nicklas

Well-Known Member
Dec 22, 2005
117
0
166
cPanel Access Level
Root Administrator
compare on both servers if the /etc/my.cnf is different, maybe you force the import of the Db's in utf and on old server they might other format.
 

Miraenda

Well-Known Member
Jul 28, 2004
243
5
168
Coralville, Iowa USA
cPanel Access Level
Root Administrator
Is one machine using a different MySQL version that the other? If the old server is MySQL 4.1 and the new is 5.0 or 5.1, then you will have issues with moving the databases. You could upgrade MySQL on the source machine before doing the move first if that's the case or downgrade MySQL on the destination machine. Depending on whether this is the case (the MySQL version) and whether you have other accounts on both machines already that might be impacted, the better option would be to upgrade the old machine to the same MySQL as the new machine over downgrading MySQL on the new machine.
 

cPanelDon

cPanel Quality Assurance Analyst
Staff member
Nov 5, 2008
2,544
14
268
Houston, Texas, U.S.A.
cPanel Access Level
DataCenter Provider
I have an account on one server I am trying to move to another. It has about 340 DB's. When I move it, many come over blank, but they are not blank on the source server. I have tried the GUI and the /scripts/ option.

Any idea how I can move this customer's 340ish database's correctly?
I do have root shell access to both servers. I did the /scripts/package /scripts/restore options. I also did a mysql rsync of the 340 DB's. The trouble comes in if I do a mysqldump of the mysql and then import into the new server, it gets a lot of crap entries as the source mysql has grants for many many accounts.

Any more specific about the script you would use?
If you've not already tried this, I recommend examining one or more full account backups to see if they are packaged successfully without loss of data from MySQL. Using the script "/scripts/pkgacct" generate a fresh backup of a cPanel account that contain MySQL databases, then manually extract the backup that was generated (e.g., "tar -xzvf $archive"). After extracting the archive contents, locate the directory named "mysql" and manually inspect the MySQL database dumps; using the SQL dumps, import each into a new database, checking to see how they compare with the original database.

Do not use "rsync" in attempt to synchronize the MySQL data directory between two servers.