T
T
Timur Mammadov2022-01-11 00:48:17
MySQL
Timur Mammadov, 2022-01-11 00:48:17

#1045 - Access denied for user 'root'@'127.0.0.1', what should I do?

In OpenServer -> PHPMyAdmin I created user root1:

CREATE USER 'root1'@'localhost' IDENTIFIED WITH mysql_native_password BY '***';ALTER USER 'root1'@'localhost' REQUIRE NONE;


But when I log in, it gives an error:
61dca8d578208399574151.png

I set the password to the standard "1111"

Here are the user parameters:
61dca9308d46c074291217.png

Please help!
If you need extra. information, I will gladly provide it to you!

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Akina, 2022-01-11
@TimurWiFi

In OpenServer -> PHPMyAdmin I created user root1

It is not enough to create a user, you must also give him the rights necessary for work. At least elementary for reading for the database that is specified as the default database.
Here are the user options

The USAGE right is synonymous with the “no privileges” right . Those. a freshly created user is absolutely powerless.
Read and apply the GRANT Statement . Pay special attention to WITH GRANT OPTION .

D
Drno, 2022-01-11
@Drno

We put ubuntu (you can on a virtual machine)
We try to do everything on it We transfer the virtual machine to a
real server
And on the question - you need to give privileges to this user on the necessary bases

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question