There might have been occasions where you had to move/copy one of your databases which are huge in size (few MBs and so on). Trying to import it normally i.e. using PHPMyAdmin isn’t a solution as it doesn’t allow you to export such huge dumps. Here’s where BigDump steps in.
BigDump is light weight utility which allows you to import big databases to your server. This teeny-weeny utility has been written in PHP and comes very handy to database professionals whose most work is in PHP.
Using this utility is very easy.
- Download BigDump from here.
- Extract the zip folder in your www directory.
- Now open the bigdump.php script in your favorite editor and make the following changes:
// Database configuration
$db_server = ‘<your dbhost>’;
$db_name = ‘<your dbname>’;
$db_username = ‘<your db username>’;
$db_password = ‘<your db password>’;
- After this search for $max_query_lines and change it a large value, eg: 10000. This is required if you get any error while import your dump.
// How many lines may be considered to be one query (except text lines)</span>
$max_query_lines = 50000;
- Once you have made these changes, copy your .sql dump file in the folder where you extracted BigDump.
- Open your browser and point it to the folder where bigdump.php resides. Eg. localhost/mysite/bigdump/bigdump.php
- You should see your dump.sql file in the list, choose that file and hit import.
- Sit back and let this magical tool cast a spell !
This tool came very handy while I was trying to import a database. Thought to share with everyone as it might be useful to many. In case of any issues, do leave your comments below ! Cheers !