Skip to content

fix: don't tear down IP assignments when guest.net is empty but tools report running - #3

Merged
dirtycache merged 1 commit into
mainfrom
fix/skip-ip-sync-when-guest-net-empty
Jul 28, 2026
Merged

fix: don't tear down IP assignments when guest.net is empty but tools report running#3
dirtycache merged 1 commit into
mainfrom
fix/skip-ip-sync-when-guest-net-empty

Conversation

@dirtycache

Copy link
Copy Markdown
Owner

Summary

  • BIG-IP VE hosts on old TMOS builds (11.5.0, 12.1.4.1) report VMware Tools as guestToolsRunning but never populate per-NIC guest.net data. Every sync cycle, this looked like "all IPs removed from all interfaces" and netbox-sync deleted the (correct, live) IP-to-interface assignments.
  • Extends the existing skip_ip_handling guard (previously only triggered when tools aren't running at all) to also skip IP add/remove for a VM when guest.net comes back completely empty despite tools reporting running.
  • A genuine per-NIC IP removal is unaffected: that case still reports the NIC in guest.net, just with no IP bound to it, so skip_ip_handling stays False and the removal still happens.
  • Known gap: a VM that legitimately drops to zero reporting NICs (all interfaces at once) would also be protected by this guard and not reflected in NetBox. Considered acceptable — far less common than a single NIC losing its IP.

Test plan

  • Confirm bigip-ve-001/bigip-ve-002 (the two affected hosts) stop losing their mgmt IP-to-interface assignment across sync cycles once deployed
  • Confirm a genuine IP removal on a normal VM (e.g. unassign an IP from a vNIC with working tools) still gets reflected/removed in NetBox

…tive IP removal

Old TMOS builds (e.g. BIG-IP 11.5.0, 12.1.4.1) report VMware Tools as
running but never populate per-NIC guest.net data. That caused every
interface's NetBox IP assignment on those VMs to look "removed" on
each sync cycle and get deleted, even though the guest is up and the
IP is still live. Skip IP handling for a VM when guest.net comes back
completely empty while tools report running; a real per-NIC removal
still reports the NIC (just without an IP), so that case is unaffected.
@dirtycache
dirtycache merged commit 4928b8b into main Jul 28, 2026
@dirtycache
dirtycache deleted the fix/skip-ip-sync-when-guest-net-empty branch July 28, 2026 21:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant