News:

GinGly.com - Used by 85,000 Members - SMS Backed up 7,35,000 - Contacts Stored  28,850 !!

Main Menu

Backup of Mysql database without Using PhpMyAdmin

Started by Sudhakar, May 24, 2009, 09:56 PM

Previous topic - Next topic

Sudhakar

phpMyAdmin has some file size limits so if you have large databases it may not be possible

to backup using phpMyAdmin. Then you have to use the command line tools that comes with

Mysql. Please note that this method is untested.

Mysql backup without phpMyAdmin
PHPMyAdmin can't handle large databases. In that case straight mysql code will help.

1. Change your directory to the directory you want to dump things to:

user@linux:~> cd files/blog
2. Use mysqldump (man mysqldump is available):

user@linux:~/files/blog> mysqldump --add-drop-table -h mysqlhostserver
-u mysqlusername -p databasename (tablename tablename tablename) | bzip2
-c > blog.bak.sql.bz2

Enter password: (enter your mysql password)
user@linux~/files/blog>
Example:
mysqldump --add-drop-table -h db01.example.net -u dbocodex -p dbwp | bzip2 -c >

blog.bak.sql.bz2

Enter password: my-password
user@linux~/files/blog>

The bzip2 -c after the pipe | means the backup is compressed on the fly.