The documentation set for this product strives to use bias-free language. For the purposes of this documentation set, bias-free is defined as language that does not imply discrimination based on age, disability, gender, racial identity, ethnic identity, sexual orientation, socioeconomic status, and intersectionality. Exceptions may be present in the documentation due to language that is hardcoded in the user interfaces of the product software, language used based on RFP documentation, or language that is used by a referenced third-party product. Learn more about how Cisco is using Inclusive Language.
To allocate Ethernet interfaces to a virtual device context (VDC), use the allocate interface ethernet command. To revert to the default settings, use the no form of this command.
allocate interface ethernet slot/port
allocate interface ethernet slot/port [-port]
allocate interface ethernet slot/port , ethernet slot1/port ... [ , ethernet slot/port ]
no allocate interface ethernet slot/port
no allocate interface ethernet slot/port [-port]
no allocate interface ethernet slot/port , ethernet slot1/port ... [ , ethernet slot/port ]
slot/port |
Slot number and port number for the Ethernet interface. |
None
VDC configuration
Release |
Modification |
---|---|
6.1(1) |
Added the no option. |
4.0(1) |
This command was introduced. |
You can use this command only in the default VDC (VDC 1).
Initially, all interfaces belong to the default VDC. You can allocate individual interfaces, ranges of interface, or lists of interfaces.
Use the show vdc membership command to display the current allocation of interfaces among the VDCs on the physical device.
Note | All configuration for the interface is lost when you allocate them to another VDC. |
To remove the interface from the VDC and return them to the default VDC, you must enter VDC configuration mode for the default VDC and allocate the interface to the default VDC.
This command requires the Advanced Services license.
This example shows how to allocate one Ethernet interface to a VDC:
switch# configure terminal switch(config)# vdc MyDevice switch(config-vdc)# allocate interface ethernet 2/1 Moving ports will cause all config associated to them in source vdc to be removed. Are you sure you want to move the ports? [yes] yes
This example shows how to allocate a range of Ethernet interfaces on the same module to a VDC:
switch# configure terminal switch(config)# vdc MyDevice switch(config-vdc)# allocate interface ethernet 2/1 - 4 Moving ports will cause all config associated to them in source vdc to be removed. Are you sure you want to move the ports? [yes] yes
This example shows how to allocate a list of Ethernet interfaces on the same module to a VDC:
switch# configure terminal switch(config)# vdc MyDevice switch(config-vdc)# allocate interface ethernet 2/1, ethernet 2/3, ethernet 2/5 Moving ports will cause all config associated to them in source vdc to be removed. Are you sure you want to move the ports? [yes] yes
This example shows how to move an Ethernet interface back to the default VDC:
switch# configure terminal switch(config)# vdc switch switch(config-vdc)# allocate interface ethernet 2/1 Moving ports will cause all config associated to them in source vdc to be removed. Are you sure you want to move the ports? [yes] yes
Command |
Description |
---|---|
show vdc membership |
Displays VDC interface membership information. |
vdc |
Creates or specifies a VDC and enters VDC configuration mode. |