Configure VLANs

Virtual LAN (VLAN) is a concept that allows devices to be logically partitioned at layer 2 (data link layer). Layer 3 devices typically share a broadcast domain, but the concept of VLANs can be used to divide the broadcast domain with switches.

Layer2 Switch VLAN Config:

Command Description
(config)# [no] vlan 23 To [delete vlan or] create vlan and enter config-vlan mode
(config-vlan)# name TelephoneSanitizer Name this vlan TelephoneSanitizer
(config)# int g1/1                                      NULL
(config-if)# switchport mode access Make frames out this port untagged
(config-if)# switchport access vlan 23                                      NULL
(config)# int g1/2                                      NULL
(config-if)# switchport mode trunk Make frames out this port tagged by default
(config-if)# switchport trunk encapsulation dot1q Sometimes the default is ciscos old isl.
(config-if)# switchport trunk native vlan 256 Except for vlan 256, which is still untagged.
(config-if)# switchport nonegotiate Disable DTP

Layer3 Switch VLAN Config:

Command Description
(config)# interface VLAN 23 enter interface config mode
(config-if)# IP address 1.2.3.4 255.255.255.0 set device IP in VLAN 23
(config-if)# no shutdown virtual interfaces are disabled by default
(config-if)# int g                                      NULL
(config)# no VLAN 23 delete VLAN 23

Router (on a Stick) VLAN Config:

Command Description
(config)# interface g1/1.10 Create subinterface g1/1.10 on g1/1
(config-subif)# encapsulation dot1q 10 enable IEEE 802.1Q VLAN tagging with VLAN 10 on the subinterface
(config-subif)# ip address 10.0.10.1 255.255.255.0                                      NULL
# show vlans Show VLANs and their trunk interfaces

Troubleshoot VLANs on a Switch:

Command Description
# show vlan [{id 23, name TelephoneSanitizer}] [brief] Show VLAN settings for all switch ports
# show interfaces g1/1 switchport Verify mode and VLAN of g1/1
# show interfaces g1/1 trunk Show trunk settings and state
# show run interface VLAN 1 A quick way to search the running config.
# show interface status Show trunk mode/access VLAN
# show dtp interface g1/1 Show current DTP mode for g1/1

VTP:

CCNA Cheatsheet

A CCNA certification proves you have the competencies needed to navigate an ever-changing IT landscape. CCNA exams cover network fundamentals, IP services, security fundamentals, automation, and programmability. Designed for agility and versatility, CCNA proves you have the skills needed to manage and optimize today’s most advanced networks. CCNA training courses and exams are the foundation for advancing your career in any direction. A Cisco certification is living proof of the standards and rigor your organization recognizes and trusts to meet and exceed market demands. Here is a cheat sheet for CCNA Examination.

Similar Reads

Network Fundamentals:

Networking Devices Used in CCNA:...

IP Addressing:

Classes of IP Addresses:...

Port Security:

Switches learn MAC addresses as frames are forwarded through switch ports. Port security allows you to limit the number of MAC addresses that can be learned on a port, configure static MAC addresses, and set penalties if that port is used by unauthorized users. Users can restrict, shutdown, or protect port security commands....

Configure VLANs:

Virtual LAN (VLAN) is a concept that allows devices to be logically partitioned at layer 2 (data link layer). Layer 3 devices typically share a broadcast domain, but the concept of VLANs can be used to divide the broadcast domain with switches....

STP (Spanning Tree Protocol):

Spanning Tree Protocol (STP) prevents frame loops by putting interfaces on a switch into a forwarding or blocking states....

Configure a Serial:

The speed of the Layer 1 connection is determined by the CSU/DSU. DTE (Data Terminal Equipment)  and DCE (Data Communications Equipment) cables are used in labs without an external CSU/DSU....