mysql_100x52-64

One day , while i am viewing my website, i got the error message is that, your mysql table has been corrupted. I wonder what happened to my database. I used phpmyadmin for its repair. But no use. Gone is gone !!!

All this happened only because of the lack perfect backup of mysql database. You can backup your mysql database in some simple step. I think you know the mysql command mysqldump. This will create an sql file for your database. See example,

mysqldump -u -p databasename > /path/to/backup.sql

If you want to save this sql backup in a remote server, use* scp* command

scp /path/to/bakup.sql root@yourserverip:/path/to/remote/server

This will ask for your current useraccount’s password and remote server password. Thus your backup file is saved to a remote server

If you want to take backup periodically , add this command to your cron and execute as you wish , daily, weekly or monthly .

Go and enjoy programming , dont worry about backup, its already taken :)