How do I make a backup of the database?

Almost every modern website uses a MySQL database. More popular content management systems, such as Wordpress, Magento, Joomla, store all data in a MySQL database. If, for some reason, we want to back up the database, such as a MySQL server update, then it is possible to extract the data stored in the database or to recover the dump in case of a possible error. [...]