Laravel 应用程序启动问题,来自 xampp 服务器

问题描述 投票:0回答:1

SQLSTATE[HY000] [1130] 不允许主机“localhost”连接到此 MariaDB 服务器

我经常遇到这个问题,我尝试删除xampp,当我重新安装它时,它可以正常工作大约2 3个月,2 3个月后我再次遇到这个问题....

html mysql laravel mariadb xampp
1个回答
0
投票

这是一个已知问题,请参阅:https://tableplus.com/blog/2019/08/host-localhost-is-not-allowed-to-connect-to-this-mysql-server.html

解决方案:

  1. 访问MySQL配置文件并添加--skip-grant-tables选项。
  1. 重启服务器
  1. 然后修复用户表:
CHECK TABLE user;
REPAIR TABLE user;

  1. 删除 --skip-grant-tables 并重新启动 mysql 服务器。
© www.soinside.com 2019 - 2024. All rights reserved.