更新时间:2023-12-01 17:15:58
你能确认你已经映射了 dbserver 的 ip.转到终端并输入:ping dbserver",然后发布结果.
Can you confirm you have dbserver's ip mapped. Go to terminal and type : "ping dbserver" and please post result.
已这种情况是由 linux 发行版的安全策略引起的,其中设置了 apache 服务器,不允许它连接到远程 mysql 实例.为了解决这种情况,请转到终端并输入 sudo setenforce 0
,这样 linux 就不会强制执行如此严格的网络服务器行为.
EDITED: This situation was caused by a security policy of the linux distro where the apache server is setup that doesn't allow it to connect to remote mysql instances. For solving this situation go to terminal and type sudo setenforce 0
, that way linux won't enforce such strict webserver behaviour.