Answer the question
In order to leave comments, you need to log in
Where is the MySQL password stored when installing with LAMP?
Good afternoon. I wrote recently that there were problems installing the bundle.
I found another manual, installed LAMP on it, edited a little configs for Apache and voila PHP pages are launched.
MySQL was also installed along with everything and he did not ask me what password to put.
From above, I rolled phpmyadmin. I thought happily that here, as on Windows, there will be no password for root. But a roast goose by my collar, some kind of password was still generated.
When mysql_secure_installation
it asks you to enter the current root password first. Natural flight. I can't access the
address localhost/phpmyadmin/index.php either.
Googling I found that the MySQL installer generates a password here/var/log/mysqld.log
But there were no logs along this path. And here is where to dig out this default password now?
Result status
[email protected]:~$ systemctl status mysql.service
● mysql.service - MySQL Community Server
Loaded: loaded (/lib/systemd/system/mysql.service; enabled; vendor preset: en
Active: active (running) since Wed 2019-03-13 11:16:31 GMT; 3h 1min ago
Main PID: 9754 (mysqld)
Tasks: 29 (limit: 4522)
CGroup: /system.slice/mysql.service
└─9754 /usr/sbin/mysqld --daemonize --pid-file=/run/mysqld/mysqld.pid
мар 13 11:16:31 evgeniipc95 systemd[1]: Starting MySQL Community Server...
мар 13 11:16:31 evgeniipc95 systemd[1]: Started MySQL Community Server.
Answer the question
In order to leave comments, you need to log in
Reset your password.
https://dev.mysql.com/doc/refman/8.0/en/resetting-...
At least in Ubuntu, when mysql-server is installed, a file /etc/mysql/debian.cnf is created with user access data, which is used by the system daemon for some technical purposes.
With the command
, you can enter mysql under this user and change the root password, for example, with this command:
ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'пароль';
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question