CCNA – Switching example – vlan

TYPE OF VLAN

  • Default VLAN: By default, all switch ports become a member of the default VLAN, which makes them all part of the same broadcast domain. The default VLAN is VLAN 1 and we cannot rename or delete it.
  • Native VLAN: Frames that belong to this VLAN are not encapsulated with any tagging information
  • Data VLAN: A data VLAN that can also be referred to as user VLAN. This is configured to carry only user-generated traffic
  • Management VLAN: The administrator can manage the switch from this VLAN
  • Voice VLAN: It’s configured to carry voice traffic, ensure voice quality, and capability to be routed around congested areas on the network with minimal delays (150-180 milliseconds)

 

EXAMPLE 1 – CREATE VLAN, VLAN TRUNKING

  1. Topology

  1. Required:

    There is no VLAN on the first time, PCs can’t communicate each other and we need to create the required VLAN.

    Then, we need to configure VLAN trunk link to allow PCs can communicate each other

  1. Implement: Step 1 – Create VLANs
  • Default VLAN is VLAN 1 so we no need to create
  • Native VLAN is VLAN 1 so we no need to create (but we can create a new native vlan)
  • Data VLAN for users: VLAN 50 – Data
  • Management VLAN for admin: VLAN 99 – Mgt
  • Voice VLAN for phone: VLAN 60 – Voice

Switch 1

Description

Switch>enable

Switch#config terminal

Switch(config)#hostname S1

S1 (config)# enable secret admin

S1 (config)#line vty 0 15

S1 (config-line)#password cisco

S1 (config-line)#login

S1 (config)#vlan 50

S1 (config-vlan)#name Data

S1 (config-vlan)#vlan 99

S1 (config-vlan)#name mgt

S1 (config)#interface fastEthernet 0/10

S1 (config-if)#switchport mode access

S1 (config-if)#switchport access vlan 50

S1 (config)#interface fastEthernet 0/24

S1 (config-if)#switchport mode access

S1 (config-if)#switchport access vlan 99

S1 (config)#interface vlan 99

S1 (config-if)#ip address 192.168.99.2 255.255.255.0

S1 (config-if)#no shutdown

Configure switch name

Set privilege mode password to ‘admin’

Allow telnet

Set telnet password to ‘cisco’

Create vlan 50

Assign name ‘Data’ for vlan 50

Create vlan 50

Assign name ‘Data’ for vlan 99

Assign port Fa0/10 to vlan 50

Assign port Fa0/24 to vlan 99

Configure virtual ip for vlan 99 – mgt


Switch 2

Description

Note: Ignore configure hostname…etc..

S2 (config)#vlan 50

S2 (config-vlan)#name Data

S2 (config-vlan)#vlan 60

S2 (config-vlan)#name Voice

S1 (config-vlan)#vlan 99

S1 (config-vlan)#name mgt

S2 (config)#interface fastEthernet 0/10

S2 (config-if)#switchport mode access

S2 (config-if)#switchport access vlan 50

S2 (config)#interface fastEthernet 0/20

S2 (config-if)#switchport mode access

S2 (config-if)#switchport access vlan 60

S2 (config)#interface fastEthernet 0/21

S2 (config-if)#switchport mode access

S2 (config-if)#switchport access vlan 60

Create vlan 50

Assign name ‘Data’ for vlan 50

Create vlan 60

Assign name ‘Voice’ for vlan 60

Create vlan 99

Assign name ‘mgt’ for vlan 60

Assign port Fa0/10 to vlan 50 (interface range)

Assign port Fa0/20 to vlan 60

Assign port Fa0/22 to vlan 60

  1. Implement: Step 2 – Configure trunk link

Switch 1

Description

S1 (config)# interface fastEthernet 0/1

S1 (config-if)#switchport mode trunk

S1 (config-if)#switchport trunk allowed vlan 1-99

S1# show interfaces trunk

F0/1 is trunk link

Allow trunking for vlan1-99

Show the result

Switch 2

Description

S2 (config)# interface fastEthernet 0/1

S2 (config-if)#switchport mode trunk

S2 (config-if)#switchport trunk allowed vlan 1-99


  1. Result: VLAN created, trunk linked created, PCs can ping (same vlan)

  1. Option: This step will change the Native VLAN (VLAN 1 to other VLAN)
Switch(config)#vlan 99

Switch(config-vlan)#name native

Switch(config)#int fa0/1

Switch(config-if)#switchport trunk native vlan 99

About Terri

System Administrator @Netpower Datacenter

Posted on 24.01.2015, in Basic & Networking, Technical Articles and tagged , , . Bookmark the permalink. Leave a comment.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: