VLAN...

VLAN = Virtual Local Area NETWORK
It's a logical function between switches through which you devide a large broadcast domain into small domain.
There are two types of VLAN:
1. Static VLAN
2. Dynamic VLAN



1. Static VLAN:






switch> en
switch# sh vlan ---------to show vlan

VLAN Name                             Status    Ports
---- -------------------------------- --------- -------------------------------
1    default                          active    Fa0/1, Fa0/2, Fa0/3, Fa0/4
                                                Fa0/5, Fa0/6, Fa0/7, Fa0/8
                                                Fa0/9, Fa0/10, Fa0/11, Fa0/12
                                                Fa0/13, Fa0/14, Fa0/15, Fa0/16
                                                Fa0/17, Fa0/18, Fa0/19, Fa0/20
                                                Fa0/21, Fa0/22, Fa0/23, Fa0/24
                                                Gig0/1, Gig0/2
1002 fddi-default                     act/unsup
1003 token-ring-default               act/unsup
1004 fddinet-default                  act/unsup
1005 trnet-default                    act/unsup

Creating VLAN..........

Switch#vlan database
% Warning: It is recommended to configure VLAN from config mode,
  as VLAN database mode is being deprecated. Please consult user
  documentation for configuring VTP/VLAN in config mode.

Switch(vlan)#vlan 2 name IT
VLAN 2 added:
    Name: IT
Switch(vlan)#vlan 3 name Admin
VLAN 3 added:
    Name: Admin
Switch(vlan)#vlan 4 name Sales
VLAN 4 added:
    Name: Sales


Assigning Port.......

Switch#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
Switch(config)#int range fa0/1-3
Switch(config-if-range)#switchport access vlan 2
Switch(config-if-range)#int range fa0/4-6
Switch(config-if-range)#switchport access vlan 3
Switch(config-if-range)#int range fa0/7-9
Switch(config-if-range)#switchport access vlan 4
Switch(config-if-range)#^Z

Switch#sh vlan

VLAN Name                             Status    Ports
---- -------------------------------- --------- -------------------------------
1    default                          active    Fa0/10, Fa0/11, Fa0/12, Fa0/13
                                                Fa0/14, Fa0/15, Fa0/16, Fa0/17
                                                Fa0/18, Fa0/19, Fa0/20, Fa0/21
                                                Fa0/22, Fa0/23, Fa0/24, Gig0/1
                                                Gig0/2
2    IT                               active    Fa0/1, Fa0/2, Fa0/3
3    Admin                            active    Fa0/4, Fa0/5, Fa0/6
4    Sales                            active    Fa0/7, Fa0/8, Fa0/9
1002 fddi-default                     act/unsup
1003 token-ring-default               act/unsup
1004 fddinet-default                  act/unsup
1005 trnet-default                    act/unsup

Your VLAN is ready, now try to ping in another vlan...


Removing Port........

Switch#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
Switch(config)#int range fa0/1-24
Switch(config-if-range)#switchport access vlan 1
Switch(config-if-range)#^Z

Removing VLAN.........

Switch#vlan database
% Warning: It is recommended to configure VLAN from config mode,
  as VLAN database mode is being deprecated. Please consult user
  documentation for configuring VTP/VLAN in config mode.

Switch(vlan)#no vlan 2
Deleting VLAN 2...
Switch(vlan)#no vlan 3
Deleting VLAN 3...
Switch(vlan)#no vlan 4
Deleting VLAN 4...


No comments:

Post a Comment