"get logical-switches"
run on NSX Manager:
get logical-switches
# su admin -c get logical-switches | grep -v "^$\|VNI" | awk '{print $1, $3}' | sort | uniq -w 6 -c | sort -r | head -n 5
head -n 5
" can be increased to display more lines.VMware NSX 4.x.
VMware NSX-T Data Center 3.x.
An update or delete of a Logical Switch (LS) done on the Management Plane is handled concurrently by two different Manager nodes.
As a part of the delete activity, the NSX Manager releases the VNI, but an update operation which is triggered a few milliseconds later prevents the deletion of that Logical Switch / VNI from the NSX Manager's Corfu DB.
Due to this, the NSX Manager may have stale VNI entries for VNIs which are already associated with a Logical Switch, but at the same time, these VNIs are also available for consumption (to be assigned) in the VNI pool, which creates a possibility where a free VNI may be picked from the pool and assigned to a new Logical Switch.
The fix for this issue is to ensure that only one NSX Management node handles CRUD operations for a Segment
This issue is resolved in VMware NSX 4.1.1, 4.2.0 and VMware NSX-T Data Center 3.2.4, available at Broadcom downloads.
An upgrade will not resolve already impacted VNIs, the upgrade will carry over duplicate VNIs, any existing duplicates will need to be cleaned up manually by Broadcom Support.
If you suspect the presence of duplicate VNIs in your environment, please contact Broadcom Support and reference this KB article.