iptables允许一个ip访问本机的某个端口 需求是redis允许特定客服端连接: -A INPUT -s 182.xx.xx.xxx/32 -p tcp --dport 6379 -j ACCEPT