feature interface-vlan
Enables the creation and configuration of VLAN interfaces (SVI) on the switch.
Overview
The 'feature interface-vlan' command enables the creation and configuration of switched virtual interfaces (SVIs), also known as VLAN interfaces, on Cisco Nexus switches running NX-OS. SVIs are Layer 3 interfaces that represent a VLAN, allowing the switch to route traffic between VLANs without requiring an external router. This command is a prerequisite for any SVI configuration; without it, the 'interface vlan' command is not recognized.
In networking, VLANs segment a broadcast domain at Layer 2. To enable communication between different VLANs, a Layer 3 device (router or multilayer switch) must perform routing. SVIs provide this routing capability directly on the switch, associating an IP address with a VLAN. This is commonly used for inter-VLAN routing, management access, and as gateway addresses for hosts.
On Cisco NX-OS, features are explicitly enabled to conserve resources. The 'feature interface-vlan' command must be issued in global configuration mode before any VLAN interface can be created. Once enabled, you can configure multiple SVIs, each with its own IP address, ACLs, HSRP, and other Layer 3 features. The feature can be disabled with 'no feature interface-vlan', but this removes all VLAN interface configurations.
This command fits into troubleshooting workflows when verifying Layer 3 connectivity. If VLAN interfaces are not working, check if the feature is enabled. It is also important when migrating from IOS to NX-OS, as IOS does not require a separate feature enablement for SVIs.
feature interface-vlanWhen to Use This Command
- Enable routing between VLANs by creating SVIs for Layer 3 switching.
- Configure management VLAN interface for remote access to the switch.
- Set up VLAN interfaces for HSRP/VRRP gateway redundancy.
- Enable VLAN interfaces for DHCP relay or ACL application.
Parameters
| Parameter | Syntax | Description |
|---|---|---|
| feature interface-vlan | feature interface-vlan | Enables the interface-vlan feature. No parameters. Must be entered in global configuration mode. |
Command Examples
Enable interface-vlan feature
configure terminal
feature interface-vlanswitch(config)# feature interface-vlan switch(config)#
The command is entered in global configuration mode. No output confirms success. After this, VLAN interfaces can be created.
Verify feature is enabled
show feature | include interface-vlaninterface-vlan 1 enabled
The output shows the interface-vlan feature is enabled. '1' indicates the feature is turned on.
Understanding the Output
The command itself produces no output on success. To verify, use 'show feature | include interface-vlan'. The output shows the feature name and status: 'enabled' means it is active. If disabled, it shows 'disabled'. After enabling, you can create VLAN interfaces with 'interface vlan <id>'. This command is a prerequisite for any SVI configuration on NX-OS.
Configuration Scenarios
Enable and Configure a VLAN Interface for Management
A network administrator needs to manage a Nexus switch remotely via VLAN 10.
Topology
[Management PC] --- [Nexus Switch]Steps
- 1.Enter global configuration mode.
- 2.Enable the interface-vlan feature.
- 3.Create VLAN 10 and assign a name.
- 4.Create VLAN interface 10 and assign an IP address.
- 5.Ensure the interface is administratively up.
configure terminal feature interface-vlan vlan 10 name Management interface vlan 10 ip address 192.168.10.1/24 no shutdown
Verify: Use 'show ip interface brief vlan 10' to verify the interface is up and has the correct IP.
Watch out: The VLAN must exist in the VLAN database before creating the SVI; otherwise, the interface will be in a down state.
Troubleshooting with This Command
When troubleshooting VLAN interface issues on NX-OS, the first step is to verify that the 'interface-vlan' feature is enabled. Use 'show feature | include interface-vlan'. If disabled, enable it with 'feature interface-vlan'. If the feature is enabled but the VLAN interface is down, check if the VLAN exists with 'show vlan'. If the VLAN is not present, create it. Also ensure the VLAN interface is not administratively down ('no shutdown').
If the VLAN interface is up but cannot ping the gateway, verify the IP address configuration and that the interface is in the correct VRF (default unless changed). Check routing with 'show ip route'. For SVIs participating in HSRP, verify HSRP status with 'show hsrp'. ACLs applied to the SVI can also block traffic; check with 'show ip access-lists'.
Common issues include: VLAN not created, SVI in 'down/down' state due to no active ports in the VLAN, or mismatched VRF. Use 'show interface vlan <id>' to see detailed status. If the SVI is 'up/up' but traffic fails, check for STP blocking or port security issues on access ports.
CCNA Exam Tips
Remember that 'feature interface-vlan' must be enabled before configuring any VLAN interface on NX-OS.
On CCNP Enterprise, know that this is specific to NX-OS; IOS uses 'interface vlan' without a feature command.
Be aware that disabling the feature removes all VLAN interface configurations.
Common Mistakes
Forgetting to enable the feature before configuring 'interface vlan', resulting in '% Invalid command' error.
Assuming the feature is enabled by default; it is not on many NX-OS platforms.
Disabling the feature without removing VLAN interfaces, causing configuration loss.
Platform Notes
On Cisco IOS, VLAN interfaces are created directly with 'interface vlan <id>' without needing a feature command. NX-OS requires explicit feature enablement to conserve resources. On IOS-XE, the equivalent is also 'interface vlan' without a feature command, but on some platforms like Catalyst 9000, the 'interface vlan' command is available by default. On NX-OS, disabling the feature removes all SVI configurations, which is a significant difference. In earlier NX-OS versions, the command was 'feature interface-vlan' but on newer versions it remains the same. For troubleshooting, NX-OS provides 'show feature' to list enabled features, which is not available on IOS.
Practice for the CCNA 200-301
Test your knowledge with hundreds of CCNA practice questions covering all exam domains.
Practice CCNA Questions