Mysql remote configuration on Debian

之前虽然已经在Mysql中配置好了允许远程连接的用户,但是仍然无法连接,终于在今天得到了解决。

通过iptables –list命令查看得知,在iptables中Mysql的3306端口被DROP了。而关于iptables的大部分问题是基于CentOS的。根据这些解答,CentOS中iptables的位置似乎位于/etc/sysconfig/iptables,而Debian中没有这个文件夹。后来通过whereis命令查找到iptables配置文件的位置/etc/iptables.rules,修改3306端口规则为ACCEPT,并更新规则后连接成功。

参考链接:https://blog.slogra.com/post-232.html

Leave a Reply

Your email address will not be published. Required fields are marked *