keepalived.conf 中的未知关键字

keepalived.conf 中的未知关键字

检查 keepalived 状态时收到以下消息:

Feb 07 17:32:12 st- 1 Keepalived[1727]: (Line 3) Unknown keyword 'interface'
Feb 07 17:32:12 s   Keepalived[1727]: (Line 4) Unknown keyword 'vitual_router_id'
Feb 07 17:32:12 st- Keepalived[1727]: (Line 5) Unknown keyword 'priority'
Feb 07 17:32:12 st1 Keepalived[1727]: (Line 6) Unknown keyword 'advert_int_1'
Feb 07 17:32:12 st- Keepalived[1727]: (Line 7) Unknown keyword 'virtual'
Feb 07 17:32:12 st- Keepalived[1727]: (Line 7) Unexpected '{' - ignoring
Feb 07 17:32:12 st- Keepalived[1727]: (Line 8) Unknown keyword '10.10.XXX.XX/24'
Feb 07 17:32:12 st- Keepalived[1727]: (Line 9) Unknown keyword '}'
Feb 07 17:32:12 st- Keepalived[1727]: (Line 10) Unknown keyword '}'
Feb 07 17:32:12 st- Keepalived[1727]: Warning - keepalived has no configuration to run

keepalived.conf 如下所示:

vrrp_intance stnexus1 {
   state BACKUP
   interface ens192
   vitual_router_id 102
   priority 200
   advert_int_1
   virtual ipaddress {
      10.10.XXX.XX/24
   }
}

感谢你的帮助,谢谢

答案1

关键字 vrrp_instance 拼写错误,应为 vrrp_intance。这导致 keepalived 忽略整个块,因为它无法识别该名称。

相关内容