Backup Database Using Command Line in Linux
How to backup a database using command line - LinuxTo create a backup of a database you need to SSH into the server.
ssh -p <portnumber> 'user'@servername.com
Then enter the following command replacing DATABASE_NAME with the name of your database in order to generate your backup which will be called BACKUP.sql.
mysqldump DATABASE_NAME > BACKUP.sql