英文:
phpMyAdmin root login denied
问题
我在MX Linux 21.3上安装了phpMyAdmin作为我的操作系统,但尝试登录时遇到了错误。
尝试安装ZoneMinder时遇到了与数据库连接相关的错误,安装phpMyAdmin以便添加/更改用户/权限,可以顺利安装phpMyAdmin,但尝试登录时出现了以下错误:(请参见下面的截图),我遵循了这个帖子来安装phpMyAdmin。
附注:我已经在/var/www/html/phpMyAdmin/config.inc.php中更改了$cfg['blowfish_secret'] = 'mypassword';,我做错了什么?
英文:
I have MX Linux 21.3 as my OS, installed phpMyAdmin, but when tried to login, got an error.
tried to install ZoneMinder got an error with DB connection, installed phpMyAdmin to facilitate adding/changing users/privileges, could install phpMyAdmin without problem, but when tried to login, got the following error: (please see the screenshot below), and I followed this post to install phpMyAdmin.
ps: I did change the $cfg['blowfish_secret'] = 'mypassword'; in /var/www/html/phpMyAdmin/config.inc.php, what I'm doing wrong?
答案1
得分: 0
在没有更多上下文的情况下,这很难在假设之外回答。不管怎样,我希望这有所帮助。
根据您提供的数据,我得出的印象是问题可能只是根密码。
我要指出的是,根密码和$cfg['blowfish_secret']下的口令根据您分享的文档不一定相同。
如果您能够通过命令行无需密码登录。
然后,您可以自行重置密码
sudo mysqld --skip-grant-tables
mysql -u root mysql
UPDATE user SET Password=PASSWORD('YOUR_ENTRY_HERE') WHERE User='root'; FLUSH PRIVILEGES; exit;
英文:
Without more context, this is difficult to answer outside of assumptions. Regardless, I hope this helps.
The impression I get from the data you provided makes me infer the problem would just be the root password.
I would point out that the root password and the passphrase under $cfg['blowfish_secret'] are not necessarily the same thing according to the document you shared.
If you are able to login via command-line passwordless.
You can then reset the password yourself
sudo mysqld --skip-grant-tables
mysql -u root mysql
UPDATE user SET Password=PASSWORD('YOUR_ENTRY_HERE') WHERE User='root'; FLUSH PRIVILEGES; exit;
答案2
得分: 0
blowfish_secret
与Web界面连接相关,而不是与数据库连接相关。
zoneminder不使用数据库用户来控制访问,因此不需要phpmyadmin。
要重置root帐户的密码,并创建一个单独的zoneminder帐户:
$ sudo -u mysql mariadbd --skip-grant-tables &
$ mariadb
MariaDB [(none)]> FLUSH PRIVILEGES;
MariaDB [(none)]> SET PASSWORD FOR root@localhost = PASSWORD('i will not forget this');
MariaDB [(none)]> source /usr/share/zoneminder/db/zm_create.sql;
MariaDB [(none)]> grant lock tables,alter,create,select,insert,update,delete,index on zm.* to zmuser@localhost identified by 'zmpass';
MariaDB [(none)]> SHUTDOWN;
$ sudo systemctl start mariadb.service
确保zm配置(/etc/zm/zm.conf
?)使用zmuser
的这些认证。
来自zm安装的第7步。
英文:
blowfish_secret
is related to the web UI connection, not the database one.
zoneminder doesn't use database users to control access so phpmyadmin not needed.
To reset password of the root account, and CREATE A SEPARATE ZONEMINDER ACCOUNT;
$ sudo -u mysql mariadbd --skip-grant-tables &
$ mariadb
MariaDB [(none)]> FLUSH PRIVILEGES;
MariaDB [(none)]> SET PASSWORD FOR root@localhost = PASSWORD('i will not forget this');
MariaDB [(none)]> source /usr/share/zoneminder/db/zm_create.sql;
MariaDB [(none)]> grant lock tables,alter,create,select,insert,update,delete,index on zm.* to zmuser@localhost identified by 'zmpass';
MariaDB [(none)]> SHUTDOWN;
$ sudo systemctl start mariadb.service
Ensure the zm configuration (/etc/zm/zm.conf
?) uses these authentication of the zmuser
.
from step 7 of zm install.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论