VLAN/VTP/DTP commands Flashcards
How do you view VLAN info on a switch?
sh vlan brief
How do you view VLAN info on a specific interface?
sh interface gig0/1 switchport
How do you configure a port as a trunk port?
()interface gig0/1
(if)switch mode trunk
How do you configure a port as an access port?
()interface gig0/1
(if)switch mode access
How do you add a port to VLAN 10?
()interface gig0/1
(if)switchport access vlan 10
What is good practice when configuring ports?
give a name and description for the port
How do you configure VLAN 75 as the native vlan?
First select unused VLAN.
()vlan 75
(vlan)name Native
Then
()interface gig0/1
(if)switchport mode trunk
(if)switchport native vlan 75
On older switches you must do what when configuring every single trunk interface?
How do you do this?
You must specify the trunking protocol to be used because they support both Inter-switch Link (ISL) and 802.1Q, they default to ISL.
(if)switchport trunk encapsulation dot1q
How do you limit allowed VLANS?
Navigate to the trunk port with
()interface GigabitEthernet 0/1
List allowed VLANs, there is an implicit deny. (if)switchport trunk allowed vlan 10,30
What is DTP and how do you disable it if it’s on by default?
Dynamic Trunking Protocol allows switches to automatically negotiate trunk connections.
(f)switchport nonegotiate
How do you change a switch port to DTP desirable?
(if)switchport mode dynamic desirable
How do you change a switch port to DTP auto?
(if)switchport mode dynamic auto
DTP is not recommended, what should you do instead for trunking?
manual configuration using these as needed.
(if) switchport mode access
(if) switchport mode trunk
What is VTP?
VLAN Trunking Protocol.
It allows switches to automatically populate VLAN databases to reduce the amount of maintenance needed for large campus networks.
How does VTP work?
- Switches are configured either as VTP clients, VTP transparent, or VTP servers.
- VTP client switches will automatically synchronize their VLAN database with that of the VTP server.
- VTP transparent devices do not participate but will forward VTP requests.
What is the default VTP state switches?
Server.
This is very dangerous because the switch has no VLANs by default, adding it to the network will erase VTP client’s VLAN tables.
A technician working on a VTP enabled device is unable to manually add VLANs, what is the likely cause.
How do you fix it?
It is in VTP client mode.
()vtp mode transparent
A VTP enabled device is unable to automatically add VLANs from the server, what is the cause?
How do you fix this?
The device is in VTP transparent mode
()vtp mode client
What is a revision number?
The VTP server priority, the higher the number the more priority its VTP updates have over other servers.
If you are using both VTP and DTP at the same time, what needs to be configured?
How do you do this?
The VTP domain name must match on all neighboring switches for trunks to form.
()vtp domain NAMEHERE
How do you verify VTP is working properly?
#sh vtp status #sh vlan brief
What are the three methods of inter-VLAN communication?
Separate router interfaces - One physical cable and one physical port for each VLAN on the switch.
Router on a stick - Single cable with multiple virtual interfaces and a single physical trunk port on the switch.
L3 switch - most commonly used method
What is the advantage and disadvantage of router-on-a-stick for inter-VLAN routing over the other two methods?
You save interfaces on the switch compared to separate-interface method. And you don’t need to buy an expensive L3 switch.
There is more contention for bandwidth because it all goes through a single Ethernet Cable and still needs to go through a router.
L3 switch method requires what additional configurations? How do you do them?
The port on the L3 switch needs to be converted into a layer 3 interface for the WAN link. And that L3 interface needs same default gateway as WAN port on router.
Enable routing with:
L3SW ()ip routing
Then add IPs to each vlan interface.
For router link:
L3SW ()interface fast0/1
L3SW (if)no switchport
L3SW (if) ip address 1.1.1.1 255.255.255.0
L3SW (if) ip route 0.0.0.0 0.0.0.0 1.1.1.2
On router:
Add ip to L3 switch link, default gateway leading to WAN link.
Add route on WAN link for the VLANs leading to the L3 switch link:
ip route 10.10.0.0 255.255.255.0 1.1.1.1