39
interface vlan-interface
Use
interface vlan-interface
to create a VLAN interface and enter its view or enter the view of an existing
VLAN interface.
Use
undo interface vlan-interface
to remove the specified VLAN interface.
Syntax
interface vlan-interface
vlan-interface-id
undo interface vlan-interface
vlan-interface-id
Views
System view
Default command level
2: System level
Parameters
vlan-interface-id
: Specifies a VLAN interface number in the range of 1 to 4094.
Usage guidelines
Create the VLAN before you create the VLAN interface.
To configure an IP address for a VLAN interface that will perform IP routing, use the
ip address
command
in VLAN interface view.
Examples
# Create VLAN-interface 2, and enter its view.
<Sysname> system-view
[Sysname] vlan 2
[Sysname-vlan2] quit
[Sysname] interface vlan-interface 2
[Sysname-Vlan-interface2]
Related commands
display interface vlan-interface
ip address
Use
ip address
to assign an IP address and subnet mask to a VLAN interface.
Use
undo ip address
to remove the IP address and subnet mask for a VLAN interface.
Syntax
ip
address
ip-address
{
mask
|
mask-length
} [
sub
]
undo ip address
[
ip-address
{
mask
|
mask-length
} [
sub
] ]
Default
No IP address is assigned to a VLAN interface.
Views
VLAN interface view