1. Install MySQL and plugins:
sudo apt-get install mysql-server mysql-clientsudo apt-get Install Libmysqld-dev
sudo apt-get install Python-dev
In this process he will prompt you to enter the root password and confirm the password.
Install the python and MySQL connection plugin
Mysqlclient
2. Configure MySQL remote access permission (user name password self-modification)
GRANT all privileges on * * to ' user name ' @ '% ' identified by ' password ' with GRANT OPTION; FLUSH privileges; (Configuration takes effect immediately)
3. Configuration files
At this time we still can not remotely connect MySQL, the following also have to modify the file;
Vi/etc/mysql/mysql.conf.d/mysql.conf
Modify the IP address in bind-address = 127.0.0.1 to 0.0.0.0
Restart MySQL
Service MySQL Restart
This completes the installation of MySQL.
Install and deploy Django based on Ubuntu Server 16.04 lts version (iv): install MySQL Database