Cannot log into phpMyAdmin as root user


(Craig) #1

A member of our community brought up an issue he ran into the other day. I was able to reproduce this issue after installing phpMyAdmin on Ubuntu 18.04. The repositories in Ubuntu 18.04 appear to download a newer version of phpMyAdmin that comes with an extra security measure. In this case, the security measure is to disable using your MySQL root user on phpMyAdmin.


(Craig) #2

So, how do I create a user/database to install Magento?
Looks like you’ll have to do this from the command line now. Luckily, it’s pretty easy…

1. Log into MySQL from the Command Line

  • mysql -u root -p (Log into mysql from the command line as the MySQL root user)
  • You’ll be prompted for your MySQL root user password. Enter this and hit Enter to continue.

2. Create the Magento Database
Replace database

  • CREATE DATABASE database;
  • CREATE DATABASE magento_database; (example)

3. Create the Magento Database User
Replace username and password

  • CREATE USER 'username'@'localhost' IDENTIFIED BY 'password';
  • CREATE USER 'craig'@'localhost' IDENTIFIED BY 'iamasecurepassword'; (example)

4. Permit the Magento User to access the Magento Database

  • GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, INDEX, ALTER, CREATE TEMPORARY TABLES, LOCK TABLES, EXECUTE, CREATE VIEW, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, TRIGGER, REFERENCES ON magento_database.* TO 'craig'@'localhost';

5. Exit MySQL

  • Type exit

How to install Magento 2.3 (Coming Soon...)
(Craig) #3