Migrating databases to new server, stumped!

zek

Registered
For some reason this came up in the wrong forum before...

Some time ago the web hosting company I am using was taken over and changed to another platform. Everything broke and the tech support took the attitude they were helping me sort out my problem rather then sorting out a problem they had created. So I have moved to another company. It's budget hosting so I can't expect a lot. I backed up the directories with the script stuff in, (drupal and Gallery) and the new host has an auto-install feature for both scripts.

I could do with some help (maybe over skype or something) as I want to get them working with the previous content if possible. It would be an enormous task to start over again.

Any takers?
 
Drupal normally uses mysql, so if that is the case. Get your self some shell access to your old account or if they have phpMyAdmin installed it's even easier.

With phpMyAdmin just find the export function and export that parts of the database you need. On the import side if you also have phpMyAdmin I think there is an import feature too. Try google for some help if you can't find it.

If you don't have phpMyAdmin support you are going to have to log into your server via ssh.

use the mysqldump command to export your database. The basic syntax is like this: mysqldump [options] --databases db_name1 > <what you want to save it as>.sql

to import it you should be able to just run one mysql command:
mysql -u <username> -p <databasename> < <file you exported>.sql

I could go more in depth if necessary but those are the basic fundamentals.

Most hosts only let you get to the database server from the web server so you have to use ssh, but if you have direct access to the database server you could also use one of the MySQL management tools: http://dev.mysql.com/downloads/gui-tools/5.0.html
You could probably use those tools even if you don't have direct access to the database server but have ssh access if you know how to do a ssh tunnel.
 
|Thanks a lot, yes both MySQL, both servers with phpMyAdmin. Done now, seems to be working ok.
 
Back
Top