背景:闲来想着用navicat访问下centos上的数据库,发现连接不上。。。尴尬。。
如图:一直在连接。。然后报了一个unknown error。。
解决:
1、查看一下防火墙状态
[root@VM_0_15_centos ~]# systemctl status iptables.service
● iptables.service - IPv4 firewall with iptables
Loaded: loaded (/usr/lib/systemd/system/iptables.service; enabled; vendor preset: disabled)
Active: inactive (dead) since Sat 2018-11-17 10:13:48 CST; 45min ago
Process: 2312 ExecStop=/usr/libexec/iptables/iptables.init stop (code=exited, status=0/SUCCESS)
Process: 454 ExecStart=/usr/libexec/iptables/iptables.init start (code=exited, status=0/SUCCESS)
Main PID: 454 (code=exited, status&