How to backup a MySQL database from the command line

MySQL provides a utility called “mysqldump”. Basically what this tool does it it creates a flat file containing the SQL instructions to restore your database. Here are a few usage examples of mysqldump: