BigDump

From TNG_Wiki
Jump to: navigation, search
Ambox notice.png BigDump Database Restore Utility

Current verion: 0.32b
Written by Alexey Ozerov, http://www.ozerov.de/bigdump/
License: Freeware GNU
Use: Synchronize website and WAMP server databases
Article contributed Aug 13, 2011 by --Kazooter

TNG All


Description

BigDump is a utility to restore a large database from a backup in the form of an SQL 'dump' file. There is a common problem with restoring dump files in phpMyAdmin -- often they will time out and abort because the dump file is too large. This is where BigDump comes to the rescue. It transparently breaks the restoration of large files into smaller, system-edible pieces. To summarize, you use phpMyAdmin to backup your website's database, then restore it with BigDump. One can use it exclusively to restore a website dump file to a desktop WAMP server in order to synchronize the databases. The following describes using BigDump to restore a website dump to a WAMP server.

Installing BigDump

The following steps are for installing BigDump on a WAMP Server:

  1. Download the file from http://www.ozerov.de/bigdump/.
  2. Following the directions from the website, create a working directory (e.g. /dump) on your Wamp server and add bigdump.php to it.
  3. Using a text editor, open bigdump.php, read the introductory information, and add your server name, database name, user name and password where indicated.

Note: this file could be a security hazard if left on a publicly accessible site after restoring a database, so please remove it when finished.

Backing Up A TNG Database

Virtually every hosting service provides access to phpMyAdmin to maintain MySQL databases. If you are using cPanel you can find it under the Databases section. Shown is phpMyAdmin v3.3.3. If yours looks different, see the next section below. Phpmyadmin.jpg
After clicking on phpMyAdmin you will probably have to respond to a login screen. In the left hand panel you must select a database to administer.

Selectdb.jpg

After selecting the TNG database a list of tables will appear. At the top of the page, click on the Export tab.

Exporttab.jpg

On the "View dump (schema) of database" page you must do the following:

Download.jpg

  1. Make sure the box next to 'Add Drop Table...' is checked.
  2. Make sure the box next to 'Extended inserts' is unchecked.
  3. The rest of the default settings should be okay.
  4. Make sure 'Save as file' is checked and select the 'gzipped' option.
  5. Click on Go, and save the file to a suitable location on your computer.

phpMyAdmin v3.4.3.2

Some web hosting services have upgraded to a later version of phpMyAdmin and the export screen looks completely different.

Bda001.jpg

Under Export Method, click on the Custom - display all possible options radio button. Under output select 'gzipped' from the drop down menu.

Bda002.jpg

Under Object creation options, make sure to check the box next to Add Drop Table ...

Bda003.jpg

To prevent extended inserts that would 'choke' BigDump and cause it to fail, select "include column names in every insert statement".

click on the Go button to download the dump file to your PC.

Restoring A Dump File

The following steps are for restoring a dump file to a Wamp Server database

  • Use the free utility 7-zip to unpack the gzipped dump file and place it in the same directory where you installed bigdump.php.
  • Using your browser, navigate to bigdump.php and start it. See (1) in the illustration below.

Bigdump.jpg

  • You should see the name of the SQL file you just placed in the BigDump directory (2).
  • Click on Start Import (3) to begin restoring the database.

Restoring.jpg

When finished, your WAMP server database should exactly mirror your website's TNG database.

Troubleshooting

You should not have any problems if you follow all the directions carefully; if you do, check the following pages on the author's Website:
http://www.ozerov.de/bigdump/faqs/
http://www.ozerov.de/bigdump/usage/

While you are there, consider donating a few dollars to the author for his good work.