This article covers how to install MySQL version 8.0 on an Ubuntu 20.04 server. By completing it, you will have a working relational database that you can use to build your next website or application.
MySQL is an open-source database management system, commonly installed as part of the popular LAMP (Linux, Apache, MySQL, PHP/Python/Perl) stack. It implements the relational model and uses Structured Query Language (better known as SQL) to manage its data.
To install MySQL using the APT package repository:
1. Update the package index on your server if you've not done so recently:
$ sudo apt update
2. Then install the mysql-server package:
$ sudo apt install mysql-server
This will install MySQL, but will not prompt you to set a password or make any other configuration changes.
Because this leaves your installation of MySQL insecure, we will address this next.