Article

noneal's picture
article
Reads:

3090

Score:
0
0
 
Comments:

1

Moving a MySQL Database to a new VM or Physical SUSE Linux Enterprise Server

Author Info

9 July 2009 - 12:14pm
Submitted by: noneal

(View Disclaimer)

Scenario: We moved from VMware ESX to Citrix XenServer 5.5....We had to get our GroupLink everything HelpDesk to a new VM.....Instead of a V2V process we quickly spun up a new SLES10 Server (15 seconds) and copied the MySQL Database over to the new server:

  1. SSH to Exsiting MySQL Server .. and type:
  2. mysqldump -u root -p DatabaseName > DatabaseName.sql
  3. Copy the DatabaseName.sql file to the new server and type:
  4. mysqladmin -u root -p CREATE DatabaseName
  5. mysql -u root -p DatabaseName < DatabaseName.sql

Here is the Copy Process from step 3 above.

  1. Find the dir on the src server which was /apps in this scenario..Now, ssh to the target server
  2. Issue scp -r root@sourceip:/dirname . (notice the space dot at the end)
  3. The server will ask for the root password
  4. Now Authenticate and the source data will be copied over to the new server in root/apps

DONE.

Quickly ran the install of eHD against the database and ShaZaaaam. Done!


Disclaimer: As with everything else at Cool Solutions, this content is definitely not supported by Novell (so don't even think of calling Support if you try something and it blows up).

It was contributed by a community member and is published "as is." It seems to have worked for at least one person, and might work for you. But please be sure to test, test, test before you do anything drastic with it.




User Comments

grimlock's picture

I would just add this

Submitted by grimlock on 10 July 2009 - 11:07am.

Make sure the versions are the same major version of the database, and check the character encoding of the database. You could run into issues if the old server was using something like latin1 for the encoding and the new database was using UTF8 if you didn't convert it first.

© 2012 Novell