让远程链接linux服务器的数据库mysql

为了安全考虑,仅容许云主机本机(localhost)链接数据库,若是须要远程链接数据库,须要以下操做: 打开iptables 3306端口 # iptables -I INPUT 4 -p tcp -m state --state NEW -m tcp --dport 3306 -j ACCEPT# service iptables save #保存iptables规则 以下图: 数据库受权 远程
相关文章
相关标签/搜索