MyBB Community Forums

Full Version: [Tutorial] Moving a [very] large database without any data loss!
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
LOL When i see this i remeber admins from warezbb who have over 3 MILIONS registered user
Quote:Oh! I just understood something, you actually need to be the root on both the old and the new server if you want to transfer DB with shell, hmmm, that wasn't my case I moved from a host to a server...

Not true. You just need a shell account on both servers as well as MySQL user with proper permissions. Example is your MySQL config info when you setup the MyBB site. That username/dbname should work fine. You might not have perms to create the DB but you can do that in phpMyAdmin or whatever control panel you use.

Quote:but anyway, mysqldump is a very complex command:

No it's not. It's the easiest method to move the DB.

Export:
mysqldump -uUSERNAME -pPASSWORD DATABASENAME < DUMP.sql

Import:
mysql -uUSERNAME -pPASSWORD DATABASENAME >DUMP.sql

I've done that with an 8GB database with no problems. Took maybe 10 mins to run the import and about 3 mins for the export. You can just export/dump on OLDSERVER via SSH then do and FTP from shell and then login from SSH into NEWSERVER and do the import. Same thing for the files. I've done a ton of site moves.

Otherwise you've posted some good info but you shoulde never make it more complex than it needs to be. You'll just scare the noobs.
Well I myself didn't know all that information and if I didn't post that thread you guys wouldn't come up with your ideas and techniques Smile

So thank you very much, that will help me a lot
This was very useful. I'll be moving server this month, you see. I'll be sure to use your tutorial. Just in the nick of time! Thank you.
(2011-11-03, 11:59 PM)labrocca Wrote: [ -> ]
Quote:Oh! I just understood something, you actually need to be the root on both the old and the new server if you want to transfer DB with shell, hmmm, that wasn't my case I moved from a host to a server...

Not true. You just need a shell account on both servers as well as MySQL user with proper permissions. Example is your MySQL config info when you setup the MyBB site. That username/dbname should work fine. You might not have perms to create the DB but you can do that in phpMyAdmin or whatever control panel you use.

Quote:but anyway, mysqldump is a very complex command:

No it's not. It's the easiest method to move the DB.

Export:
mysqldump -uUSERNAME -pPASSWORD DATABASENAME < DUMP.sql

Import:
mysql -uUSERNAME -pPASSWORD DATABASENAME >DUMP.sql

I've done that with an 8GB database with no problems. Took maybe 10 mins to run the import and about 3 mins for the export. You can just export/dump on OLDSERVER via SSH then do and FTP from shell and then login from SSH into NEWSERVER and do the import. Same thing for the files. I've done a ton of site moves.

Otherwise you've posted some good info but you shoulde never make it more complex than it needs to be. You'll just scare the noobs.


But, we are just using shared hosting Big Grin
If you're on shared hosting and have cpanel then it's very easy to move the site. Very easy. Cpanel has site move options and also phpmyadmin has option for uploading an sql and then resuming if a limit is reached. I just think there are easier ways than how OP describes it. Matter of fact I think his tutorial might be the most difficult way. Lots of steps are involved.
labrocca is right...but uploading big database from php myadmin is hard when you have slow connection
Awesome guide, well-explained and with screenshots too!

I'll need to follow this in sometime, no kidding!
thanks man
Pages: 1 2