Original URL: http://help.hardhathosting.com/question.php/124
From the SSH command line:
mysqldump -h localhost DATABASE > DATABASE.sqlReplace DATABASE with the name of your database.
NOTE: Accounts created before July 7th, 2003 will want to use:
/usr/local/mysql/bin/mysqldump -h localhost DATABASE > DATABASE.sql