gpt4 book ai didi

iptables - keepalived 在没有 iptables 的情况下也能正常工作

转载 作者:行者123 更新时间:2023-12-05 08:59:35 31 4
gpt4 key购买 nike

我已经设置了 keepalived,只有当我停止 iptables 服务时它才能正常工作。我的iptables配置是这样的,请告诉我应该为keepalived添加什么规则

# Firewall configuration written by system-config-firewall
# Manual customization of this file is not recommended.
*filter
:INPUT ACCEPT [0:0]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [0:0]
-A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT
-A INPUT -p icmp -j ACCEPT
-A INPUT -i lo -j ACCEPT
-A INPUT -m state --state NEW -m tcp -p tcp --dport 22 -j ACCEPT
-A INPUT -m state --state NEW -m tcp -p tcp --dport 80 -j ACCEPT
-A INPUT -m state --state NEW -m tcp -p tcp --dport 8080 -j ACCEPT
-A INPUT -m state --state NEW -m tcp -p tcp --dport 5666 -j ACCEPT
-A INPUT -m state --state NEW -m tcp -p tcp --dport 6379 -j ACCEPT
-A INPUT -j REJECT --reject-with icmp-host-prohibited
-A FORWARD -j REJECT --reject-with icmp-host-prohibited
COMMIT

最佳答案

这几天正好解决这个问题,哈哈

做:

iptables -I INPUT -d 224.0.0.0/8 -j ACCEPT
iptables -I INPUT -p vrrp -j ACCEPT

关于iptables - keepalived 在没有 iptables 的情况下也能正常工作,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12908701/

31 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com