redhat7.2中,keepalived绑定虚拟IP失败

发布于 2022-01-05 04:10:41 字数 2202 浏览 843 评论 3

redhat7.2中,keepalived绑定虚拟IP失败,大家帮忙看看呢

配制信息:

global_defs {
   notification_email {
     acassen@firewall.loc
     failover@firewall.loc
     sysadmin@firewall.loc
   }
   notification_email_from Alexandre.Cassen@firewall.loc
   smtp_server 192.168.200.1
   smtp_connect_timeout 30
   router_id LVS_DEVEL
}

vrrp_instance VI_1 {
    state MASTER
    interface bond0
    virtual_router_id 51
    priority 100
    advert_int 1
    authentication {
        auth_type PASS
        auth_pass 1111
    }
    virtual_ipaddress {
        192.168.79.100
    }
}



错误日志:

Nov  4 20:07:03 YSBUS1 Keepalived_vrrp[6642]: Registering Kernel netlink command channel
Nov  4 20:07:03 YSBUS1 Keepalived_vrrp[6642]: Registering gratuitous ARP shared channel
Nov  4 20:07:03 YSBUS1 Keepalived_healthcheckers[6641]: Opening file '/usr/local/etc/keepalived/keepalived.conf'.
Nov  4 20:07:03 YSBUS1 Keepalived_vrrp[6642]: Opening file '/usr/local/etc/keepalived/keepalived.conf'.
Nov  4 20:07:03 YSBUS1 Keepalived_vrrp[6642]: Cant find interface bond0 for vrrp_instance VI_1 !!!
Nov  4 20:07:03 YSBUS1 Keepalived_healthcheckers[6641]: Configuration is using : 11584 Bytes
Nov  4 20:07:03 YSBUS1 Keepalived_vrrp[6642]: Configuration error: VRRP definition must belong to an interface
Nov  4 20:07:03 YSBUS1 Keepalived_vrrp[6642]: Default interface eth0 does not exist and no interface specified. Skip VRRP address.
Nov  4 20:07:03 YSBUS1 Keepalived_vrrp[6642]: VRRP_Instance(VI_1) Unknown interface !



网络信息:ip a

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN 
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host 
       valid_lft forever preferred_lft forever
2: enP7p128s0f0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq state DOWN qlen 1000
    link/ether 98
              

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

爱的那么颓废 2022-01-07 15:44:10

兄弟解决了吗,解决的话,给个解决办法呗,同样的问题。

深巷少女 2022-01-07 15:31:15

默认的eth0网卡不存在,我也好纳闷没事改网卡名干啥

檐上三寸雪 2022-01-07 02:50:01

解决了吗?相同问题

​
Jan  3 16:02:20 LoSingSang Keepalived_healthcheckers[13142]: Opening file '/etc/keepalived/keepalived.conf'.
Jan  3 16:02:20 LoSingSang Keepalived_vrrp[13143]: Registering Kernel netlink reflector
Jan  3 16:02:20 LoSingSang Keepalived_vrrp[13143]: Registering Kernel netlink command channel
Jan  3 16:02:20 LoSingSang Keepalived_vrrp[13143]: Registering gratuitous ARP shared channel
Jan  3 16:02:20 LoSingSang Keepalived_vrrp[13143]: Opening file '/etc/keepalived/keepalived.conf'.
Jan  3 16:02:20 LoSingSang Keepalived_vrrp[13143]: WARNING - default user 'keepalived_script' for script execution does not exist - please create.
Jan  3 16:02:20 LoSingSang Keepalived_vrrp[13143]: Cant find interface eth0 for vrrp_instance VI_100 !!!
Jan  3 16:02:20 LoSingSang Keepalived_vrrp[13143]: Default interface eth0 does not exist and no interface specified. Skipping static address 192.168.1.199.
Jan  3 16:02:20 LoSingSang Keepalived_vrrp[13143]: VRRP_Instance(VI_100) Unknown interface !
Jan  3 16:02:21 LoSingSang Keepalived_vrrp[13143]: Stopped
Jan  3 16:02:21 LoSingSang Keepalived_healthcheckers[13142]: Stopped
root@LoSingSang:/home/lgl# ip addr
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host 
       valid_lft forever preferred_lft forever
2: ens33: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
    link/ether 00:0c:29:7c:0f:de brd ff:ff:ff:ff:ff:ff
    inet 192.168.1.200/24 brd 192.168.1.255 scope global noprefixroute ens33
       valid_lft forever preferred_lft forever
    inet6 fe80::2cf0:bf6d:e273:350d/64 scope link noprefixroute 
       valid_lft forever preferred_lft forever
root@LoSingSang:/home/lgl# 

​

 

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文