Last Updated on August 1, 2021 by Admin 2
What IOS VLAN commands would create a new VLAN and assign it to a port? (Choose two.)
-
switch(config)# vlan 10
-
switch(config)# vlan 10
-
switch(config)# vlan database 10
-
switch(config-if)# switchport vlan 10 enable
The commands necessary to create a VLAN and assign it to a port are switch(config)# vlan 10 and switch(config-if)# switchport access vlan 10. The global configuration mode is used to create VLANs with the command vlan {vlan_id}. VLANs can be removed with the no form of the command.
Ports are assigned as members of VLANs in the interface configuration mode with the command switchport access vlan {vlan_id}. At this point, if the port is in access mode, it will participate as a member of the VLAN. The mode of the port can be forced to be access in the interface configuration mode with the command switchport mode access.
The command vlan database 10 is not a valid command, but it is similar to a valid command. An optional, but not recommended, way to create a VLAN is in VLAN database mode. This is accessed from global configuration mode with the command vlan database. The prompt would be switch(vlan)#. At this prompt, a VLAN can be created with the command vlan 10. The problem with VLAN database mode is that the configurations issued here have to be applied with either the apply or exit commands. Using CTRL-Z to exit would cancel the changes made in this mode.
The command switchport vlan 10 enable is not correct due to invalid syntax.
Objective:
Layer 2 Technologies
Sub-Objective:
Configure and verify VLANs