Jump to content


0

[EXAMPLE CONFIG] - Create a VLAN


No replies to this topic

#1 goldplated

goldplated

    Cisco TE

  • Technical Expert
  • PipPipPip
  • 508 posts
  • 94 thanks
  • Location127.0.0.1

Posted 02 August 2010 - 10:52 PM

This is an example of how to configure a VLAN on a switch.  I know this is a very basic command but not everybody knows how to do so.

NOTE:  This also assumes the switch is in VTP SERVER or VTP TRANSPARENT mode.


you can check to see what mode your running in by using

 show vtp status 

Switch#
Switch#sh vtp status
VTP Version                     : running VTP1 (VTP2 capable)
Configuration Revision          : 3
Maximum VLANs supported locally : 1005
Number of existing VLANs        : 8
VTP Operating Mode              : Server
VTP Domain Name                 :
VTP Pruning Mode                : Disabled
VTP V2 Mode                     : Disabled
VTP Traps Generation            : Disabled
MD5 digest                      : 0xE8 0xE5 0x70 0x01 0xC3 0xF7 0x34 0x4B
Configuration last modified by 0.0.0.0 at 3-1-93 00:25:20
Local updater ID is 0.0.0.0 (no valid interface found)
Switch#


We create the vlans using:
 vlan 

Switch#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
Switch(config)#vlan 10
Switch(config-vlan)#name Users
Switch(config-vlan)#vlan 20
Switch(config-vlan)#name Servers
Switch(config-vlan)#vlan 30
Switch(config-vlan)#name Guest
Switch(config-vlan)#exit
Switch(config)#

We verify the vlans using:
 sh vlan brief 

Switch#sh vlan brief

VLAN Name                             Status    Ports
---- -------------------------------- --------- -------------------------------
1    default                          active    Gi1/0/1, Gi1/0/2, Gi1/0/3
                                                Gi1/0/4, Gi1/0/5, Gi1/0/6
                                                Gi1/0/7, Gi1/0/8, Gi1/0/9
                                                Gi1/0/10, Gi1/0/11, Gi1/0/12
                                                Gi1/0/13, Gi1/0/14, Gi1/0/15
                                                Gi1/0/16, Gi1/0/17, Gi1/0/18
                                                Gi1/0/19, Gi1/0/20, Gi1/0/21
                                                Gi1/0/22, Gi1/0/23, Gi1/0/24
                                                Gi1/0/25, Gi1/0/26, Gi1/0/27
                                                Gi1/0/28
10   Users                            active    
20   Servers                          active    
30   Guest                            active    

1002 fddi-default                     act/unsup
1003 token-ring-default               act/unsup
1004 fddinet-default                  act/unsup
1005 trnet-default                    act/unsup
Switch#
Switch#

Thanked by 3 Members:
joealtamirano , ykn , abege



0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

Organization

Community

Downloads

Test Providers

Site Info


Go to top