Unable to create virtual interface with duplicate name across Virtual Device Contexts (VDC) #7593

Closed
opened 2025-12-29 20:25:50 +01:00 by adam · 1 comment
Owner

Originally created by @koratfood on GitHub (Feb 2, 2023).

NetBox version

v3.4.3

Python version

3.9

Steps to Reproduce

  1. Create a device
  2. Create a VDC on the device with name VDC1
  3. Create a VDC on the device with name VDC2
  4. Create an interface on the device with the following properties:
  • name: Vlan100
  • type: virtual
  • virtual device context: VDC1
  1. Try to create an interface on the device with the following properties:
  • name: Vlan100
  • type: virtual
  • virtual device context: VDC2

Expected Behavior

Netbox should successfully create the interface object in step 5. Alternatively, if Netbox fails to do so, it should at the very least throw an error.

Reason:

A device object should be able to hold multiple virtual interfaces (i.e. interfaces with type LAG, Virtual or Bridge) with the duplicate names as long as they are assigned to separate Virtual Device Contexts on said device object. Otherwise, it may not be possible to use Netbox to model e.g. SVIs (Switched Virtual Interfaces) or Port-channels (= Cisco-speak for LAGs), which may perfectly well exist as multiple but isolated completely instances across VDCs of one single, read-world switch.

Observed Behavior

The "Add a new interface" page reloads without any error or warning message, and the interface is not created.

Originally created by @koratfood on GitHub (Feb 2, 2023). ### NetBox version v3.4.3 ### Python version 3.9 ### Steps to Reproduce 1. Create a device 2. Create a VDC on the device with name VDC1 3. Create a VDC on the device with name VDC2 4. Create an interface on the device with the following properties: - name: Vlan100 - type: virtual - virtual device context: VDC1 5. Try to create an interface on the device with the following properties: - name: Vlan100 - type: virtual - virtual device context: VDC2 ### Expected Behavior Netbox should successfully create the interface object in step 5. Alternatively, if Netbox fails to do so, it should at the very least throw an error. Reason: A device object should be able to hold multiple virtual interfaces (i.e. interfaces with type LAG, Virtual or Bridge) with the duplicate names as long as they are assigned to separate Virtual Device Contexts on said device object. Otherwise, it may not be possible to use Netbox to model e.g. SVIs (Switched Virtual Interfaces) or Port-channels (= Cisco-speak for LAGs), which may perfectly well exist as multiple but isolated completely instances across VDCs of one single, read-world switch. ### Observed Behavior The "Add a new interface" page reloads without any error or warning message, and the interface is not created.
adam closed this issue 2025-12-29 20:25:50 +01:00
Author
Owner

@jeremystretch commented on GitHub (Feb 2, 2023):

This is expected behavior. Interface names must be unique per device irrespective to their assignment to VDCs.

@jeremystretch commented on GitHub (Feb 2, 2023): This is expected behavior. Interface names must be unique per device irrespective to their assignment to VDCs.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#7593