Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a mysql database on a server that is around 4 gb in size and I couldn't get it downloaded to my local machine. I tried getting a dump on the server, but the dump is not getting created probably because of the big size. Is there any way, I could get the dump downloaded on my local machine?

I can syncing using Sqlyog but I know it will take ages. Is there a way, I can get a dump created on the server?

By the way, my server is a linux server and its running php/mysql.

share|improve this question

2 Answers 2

If you want to create the dump on the server and transfer it afterwards, you will have to tell us what the error is when you try to create it.

If you just want it on your local desktop: Download the MySQL workbench, make sure you have appropriate privileges to acccess the database from this machine (or maybe use SSH port forwarding) and use the dump tool. Works flawless for me.

share|improve this answer
    
When I used mysqlworkbench, the windows gets closed in just under a minute. When I tried to execute the dump script using SSH earlier, it gets stopped in the middle after taking the dump for 1.5 GB. –  Ctroy Feb 2 '11 at 8:44
    
Is there a log entry for mysql that might give a hint about what's going wrong? Also, did you tell the workbench to create a dump folder or a self contained file? For a 4GB database, use the folder, as it will create a file for every table. Also, do you use a recent version of the workbench? Older versions crashed really easy. And last: Do you have enough space left on the device where you want to store the dump? Depending on your data, the dump can get more than twice as big as your original data. –  Sven Feb 2 '11 at 8:53

Well you havent stated exactly what error youre getting, but you can shrink the file significantly by passing it through gzip. Since you said youre running linux, this is really easy to do

mysqldump -u USER -p --all-databases | gzip > /path/to/store/dump.sql.gz

Of course, tune the mysqldump parameters as necessary. But since the mysqldump output is largely ASCII, gzip will compress it extremely well.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.