I need some help with moving host. I have a Drupal website. I would like to move the whole site to another host.

When I tried to export and import database from phpmyAdmin, I get error saying the database is too big to be imported.

In fact, I don't really understand how to transfer the whole drupal site to another host.

I learned that:
1) Export database (in .sql) on old host from phpmyAdmin
2) Import database (in .sql) on new host from phpmyAdmin (database too large, error. I also tried .zip, cant work)
3) FTP drupal directory from old site to new site.

Are they correct?

And is there a way to replace the second step?

Please help. Thank you!

Comments

catch’s picture

you can open up the .sql file in notepad, then copy and paste sections manually into the phpmyadmin sql page.

As long as you copy and paste everything in the right order, you'll be fine. You probably have a low post/memory limit in php, so you just need to keep each section under that.

Another option is to raise a support ticket with your hosting provider and get them to do it.

gymosphere’s picture

I have never thought of investigating the .sql file!

Yes, I know how to do that. Will try now.

Thank you!

kbahey’s picture

If your host has ssh, you can do that from the command line, without any restriction on the site of the file.

another thing is in phpMyAdmin on the old host, look and see which tables are too big. Some of those you can just truncate (i.e. empty contents), and then do a dump and the database will be smaller.

Tables like accesslog, watchdog, ...etc., or tables from modules you no longer use.
--
Drupal development and customization: 2bits.com
Personal: Baheyeldin.com

--
Drupal performance tuning and optimization, hosting, development, and consulting: 2bits.com, Inc. and Twitter at: @2bits
Personal blog: Ba

catch’s picture

Yeah there's a few tables that get pretty big, and can be emptied without too many side effects:

cache (more than one table in 5.0)
sessions (will log users out including you)
possibly your search tables as well (search will need to re-index)

jwalling’s picture

I used Bigdump to restore a mysql database.
http://www.hotscripts.com/Detailed/20922.html
http://www.ozerov.de/bigdump.php

When I created the backup copy I avoided using extended inserts. An extended insert contains all table entries within one SQL query.

Bigdump will upload your database backup to the host before restoring it. You can run a test on your backup before restoring it.

John