4WebHelp: Backup your mySQL Database

How do I back up my database?

phpMyAdmin To backup your database, you will need to use phpMyAdmin. Most hosts have this script pre-installed. If you can't find it, contact your host.

When you have gotten into phpMyAdmin, you should see a welcome message saying something along the lines of "Welcome to phpMyAdmin".

On the left hand frame on the welcome screen, you should see, just below the home link, the name of your database with a number in brackets (the number in brackets is the number of tables within your database). By clicking this, the right hand frame should update, and you should be presented with a list of all your tables. Scroll down to near the bottom of this page until you find the option:

View dump (schema) of database

Select the option "Structure and Data" and click on the name of the top table, scroll down to the bottom of the list of tables, hold shift and click on the bottom table name. Then simply tick the box that says send, and click go, you should now be presented with a file download box with databasename.sql as the file. Simply save the file to your hard drive, and there you go, your database is backed up!

How do I upload my database?

If you want to re-upload your database, simply follow the commands above, but instead of going to "View dump (schema) of database", go to the section marked: Or Location of the textfile, hit the browse button underneath this, locate your .sql database file and click go. Then wait while your database is being uploaded and after that you should see all your database tables appear as normal.

And that's it, you're done!

Screenshot added by Daniel, 25 June 2002.

© 4WebHelp and Justin

Latest comments on this tutorial
Online Backup
This software will let you perform an online backup your MYSQL database automatically each night or how ever many times you would like to set it for. Not a bad choice for someone who doesnt want to mess with any PHPMYADMIN every night.

http://www.backup-database.com
adam
I suggest you to use MYSQL FRONT for that .for more information please search google.

this is a good tool and does not want to to make a login to your websites to take the backup of your website.

Adam
NIck
Quote:
go to the section marked: Or Location of the textfile, hit the browse button underneath this

I have searched all the menus of PHPmyadmin and I cannot find the section marded :Or Location of textfile with a browse button underneath it.  Even in your picture it is not visable.  Please someone tell me where to find this section.  The only way I have to back up a database is to tick all the options including drop table and copy out the sql into a text file then use it in a new database as a query.
Vlad
It worked.
Thanks a lot!
özkan
xxxxxxxxxxx
Mark White
Thanks - that's exactly what I wanted!
Daniel, 4WebHelp Team Member
Depending on the version of phpMyAdmin, the box may say "Save" or "Send". Don't worry, both will do the same thing.
Sherri
Am I the only one who does not see a "send" box to "simply tick" after highlighting all of the table names and before clicking "Go?"

I see:
Add 'drop table'  
Complete inserts  
Extended inserts  
Use backquotes with tables and fields' names  
Save as file ( "zipped"  "gzipped" )  

But I see no "send" box.  Do you mean "Save?"

Thank you,
Sherri
Daniel, 4WebHelp Team Member
This topic will probably be useful to you:

http://www.4webhelp.net/forums/viewtopic.php?p=8418#8418
Eric Desmarais
After my backup, I try to upload my database. I wait and after 1 minute a have a error message : TIME IS OUT!!!

How can i restore my database ?

(sorry for my english i speak french)
Daniel, 4WebHelp Team Member
Hi James,

If you are using phpPgAdmin, follow the same instructions until you get to "View dump (schema) of database". Then follow these instructions:

Select the option "Structure and data". Then simply tick the box that says send, and click go, you should now be presented with a file download box with databasename.sql as the file. Simply save the file to your hard drive, and there you go, your database is backed up!
James
Brilliant, helped me, but could someone do one with PHPPgAdmin too?

Add a new comment


Page URL: http://www.4webhelp.net/tutorials/db/backup.php
Back to the "pretty" page!

© 2024, 4WebHelp Team.