Fix MYSQL authentication issue in Ubuntu 18.04

Secure your MySQL installation and set the root password

sudo mysql_secure_installation

From here, you can just press Y and then ENTER to accept the defaults for all the subsequent questions.

Fix authentication issue caused by Ubuntu using auth_socket plugin by default for the root user.
You can set the root user to use the mysql_native_password instead to fix this issue, and we will have to set the root password again to correct this.

log in as sudo to mysql using the username and password set before.

sudo mysql -u root

in MySQL enter the following

USE mysql;

ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'password';


Note:

For security make this password different than your server's password, and dont use the root user in any application that requires a database to store and pull data from.

FLUSH PRIVILEGES;

exit;


Create pem certificate

 Creating a .pem with the Private Key and Entire Trust Chain     Log into your DigiCert Management Console and download your Intermediate (D...

Mais vistos