Skip to content

Trigger GARP after VRRP send failure without state change #2676

@KolozsSandor

Description

@KolozsSandor

Describe the bug
Keepalived logs the message:
Cant send advert to <peer_ip> (Operation not permitted)
when a unicast VRRP advertisement cannot be sent, for example due to temporary kernel conntrack exhaustion. In this scenario:

  • The master remains in the MASTER state.
  • Notify scripts (notify_master, notify_backup, notify_fault) do not run, because no state transition occurs.
  • Backup node (peer_ip) may briefly promote themselves if they stop receiving advertisements, creating a micro split-brain scenario. Backup sends GARPs out.

Once the original master resumes sending, <peer_ip> goes to BACKUP, but no automatic mechanism exists to stabilize the network and revert to original master (e.g., sending gratuitous ARPs), and many node tries the backup node, as it is in their arp cache for VIP.

To Reproduce
It occurred for me when conntrack was exhausted for a moment:
Add input accept nft rules for vrrp - this causes conn-tracking vrrp packets, decrease conntrack-max and DOS the MASTER node, so keepalived somehow can't send packets because this.

Expected behavior
Detect VRRP send failures (unicast or multicast).
Go to FAILED state (distruptive a bit), or stay in MASTER state but:
Trigger a corrective action without requiring a state transition, such as:

Send gratuitous ARPs (GARP) for all VIPs.
Provide configuration options, for example:
on_send_failure { send_garp 3 alert true }

Keepalived version

Keepalived v2.2.8 (04/04,2023), git commit v2.2.7-154-g292b299e+

Distro (please complete the following information):

  • Name: [Ubuntu]
  • Version: [Ubuntu 24.04.3 LTS]
  • Architecture: [x86_64]

Details of any containerisation or hosted service (e.g. AWS)
None

Configuration file:


Notify and track scripts

none

System Log entries

Confidential, sorry

BR
Sandor

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions