【问题标题】:Xampp/ Lampp Mysql accessXampp/ Lampp Mysql访问
【发布时间】:2016-09-04 09:31:07
【问题描述】:

我在 Ubuntu 16.04 LTE Xampp (lampp) 上安装一切正常:

:~$ sudo /opt/lampp/lampp start
Starting XAMPP for Linux 5.6.20-0...
XAMPP: Starting Apache...already running.
XAMPP: Starting MySQL...ok.
XAMPP: Starting ProFTPD...already running.

:~$ sudo /opt/lampp/lampp status
Version: XAMPP for Linux 5.6.20-0
Apache is running.
MySQL is not running.
ProFTPD is running.

:~$ sudo service mysql start

:~$ sudo /opt/lampp/lampp status
Version: XAMPP for Linux 5.6.20-0
Apache is running.
MySQL is not running.
ProFTPD is running.

但是当我要进入TERMINAL的时候有mysql -u root:

错误 1698 (28000):拒绝用户 'root'@'localhost' 访问

如果我使用 sudo mysql -u root,一切正常,我可以通过终端使用 mysql。

但对于 Firefox http://127.0.01/phpmyadmin/

Welcome to phpMyAdmin

Error

MySQL said: Documentation
Cannot connect: invalid settings.
Connection for controluser as defined in your configuration failed.
phpMyAdmin tried to connect to the MySQL server, and the server rejected the connection. You should check the host, username and password in your configuration and make sure that they correspond to the information given by the administrator of the MySQL server.

【问题讨论】:

    标签: php mysql xampp ubuntu-16.04


    【解决方案1】:

    我会检查 /var/lib 和 /var/run 下的权限 我有类似的情况并通过更改这些文件夹的权限然后运行来解决 $./etc/init.d/mysql 启动

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2013-12-11
      • 2013-07-11
      • 2013-02-17
      • 1970-01-01
      • 1970-01-01
      • 2011-06-17
      • 2011-03-19
      • 2022-07-25
      相关资源
      最近更新 更多