vmware source: stop reconciling guest.net IPs on acos/tmos/alteon data interfaces - #11
Merged
Conversation
…a interfaces Confirmed live: netbox-sync's own guest.net-derived IP handling was fighting netbox-device-onboard.py's self-IP writes on these platforms' data-plane interfaces every 5-minute cron cycle - either tearing the address off a real vNIC guest.net never reports it on (alt01a), or reparenting it back onto the real vNIC from the device-side collector's synthetic VLAN interface (ltm01a). The existing identity-only-sync policy only covered interface attributes, not IP-to-interface ownership. Extends the same per-platform policy: a new _skip_ip_reconciliation flag (smuggled through interface_data the same way untagged_vlan/tagged_vlans already are) tells add_update_interface() to leave a data interface's IP assignment alone entirely, for both additions and removals. mgmt keeps syncing from guest.net as before - that path has never conflicted. Also touch (re-source, no data change) any IP left alone this way, so prune_data()'s 30-day orphan-delete doesn't reclaim an address a device-side collector is actively managing just because this source stopped claiming it.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
netbox-device-onboard.py's self-IP writes on acos/tmos/alteon data-plane interfaces every 5-minute cron cycle (confirmed live innetbox_sync.logfor bothalt01aandltm01a)._skip_ip_reconciliationflag tellsadd_update_interface()to leave a data interface's IP assignment alone entirely. mgmt interfaces are unaffected - that path has never conflicted.Test plan
-n -l DEBUG2) against live vCenter/NetBox data before the fix: reproduced both failure modes (address torn offalt01a's vNIC; address reparented offltm01a's synthetic VLAN interface onto the real vNIC1.3)alt01a/alt01b/ltm01a/ltm01b/bigip-ve-001/thn01a/thn01bNetBox-synced: Orphaned