Easy VLAN management!

Source: Internet
Author: User
Tags cisco 2950

VLAN is an important part of swap technology. It logically divides a physically directly connected network into multiple subnets. Each VLAN has a corresponding broadcast domain. Different VLANs must communicate with each other through layer-3 switching technology.

Layer-3 switching is a technology that combines routing and switching. After the router routes the first data stream, a ing table between the MAC address and IP address is generated. When the same data flow passes again, the ing table is used to directly switch from the second layer instead of re-routing, which eliminates the network delay caused by router selection and improves the efficiency of packet forwarding.

VLAN configuration involves the configuration of VTP and VLAN relay.

VLAN trunk, also known as VLAN trunk, as long as it refers to the relay mode (trunk mode) configured on the port connecting a vswitch to a vswitch or vro, the relay mode allows data frames of different VLANs to be transmitted through the relay link.

VTP (VLAN relay protocol ). Through VTP, the VLAN information of the entire network can be consistent. First, you must know that VTP has three modes: service mode, customer mode, and transparent mode. The initial status of a vswitch is transparent. It can configure VLAN information. It can receive VLAN information sent from The vtp server but is not applied to the vswitch. Instead, it is directly forwarded to other vswitches, it is worth noting that no VLAN information is broadcasted. In the server mode, VLAN information can be configured in a unified manner, and information is automatically broadcast to other switches on the Internet. In customer mode, you cannot configure VLAN information. VLAN information is the VLAN configuration that receives server broadcasts.

There are three VLAN division methods:

1 static VLAN: in this way, network administrators manually configure VLAN for each port of the switch. This static allocation method has its advantages and disadvantages. Once configured, the VLAN corresponding to the port is fixed unless it is reset by the network administrator, configuration is troublesome, but it is safer and easier to maintain.

2. Dynamic VLAN: common methods for dynamically dividing VLANs in Lan are as follows:

L) MAC address-based VLAN
A VLAN based on a MAC address is used to query and record the MAC address of the NIC on the computer connected to the port to determine the port.

2) subnet-based VLAN
The subnet-based VLAN is determined by the IP address of the connected computer. Unlike the MAC address-based VLAN, even if the computer changes the MAC address due to NIC switching or other reasons, as long as its IP address remains unchanged, it can still add the previously set VLAN

3) user-based VLAN
The user-based VLAN is used to determine which VLAN the port belongs based on the user currently logged on to the computer connected to each port of the switch. The user identification information here is generally the user logging on to the computer operating system, for example, the user name used in the Windows domain.

4) Network Protocol Division
Based on Network protocols, VLAN is divided by network layer protocol and can be divided into IP, IPX, decnet, appletalk, Banyan and other VLAN networks. A VLAN composed of Network-layer protocols enables the broadcast domain to span multiple VLAN switches.

Now let's take the Cisco 1900 and 2950 vswitches as examples to see how to create a VLAN. We create a VLAN for each department and set the corresponding port to the corresponding VLAN. For port configuration commands see port configuration (http://www.pconline.com.cn/network/skills/0603/763872.html)


Cisco 2950 series switches

Cisco 1900
Create a VLAN:
Switch> en
Switch # config t
Switch (config) # hostname 1900
1900 (config) # VLAN 2 Name AC/* Create vlan2 named AC
1900 (config) # VLAN 3 name HR/* Create vlan3 named HR
1900 (config) # VLAN 4 name MIS/* Create VLAN4 named MIS
1900 (config) # exit
1900 #

Port Configuration VLAN:
1900 # config t
1900 (config) # int E0/2
1900 (config-If) # VLAN-membership static 2/* set the port to vlan2
1900 (config-If) # int E0/4
1900 (config-If) # VLAN-membership static 3/* set the port to vlan3
1900 (config-If) # int E0/5
1900 (config-If) # VLAN-membership Static 4/* set the port to VLAN4
1900 (config-If) # exit
1900 (config) # exit
1900 #

Cisco 2950
Create a VLAN:
Switch> en
Switch # config t
Switch (config) # hostname 2950
2950 (config) # exit
2950 # VLAN Database
2950 (VLAN) # VLAN 2 Name AC/* Create vlan2 named AC
VLAN 2 added:
Name: AC
2950 (VLAN) # VLAN 3 name HR/* Create vlan3 named HR
VLAN 3 added:
Name: HR
2950 (VLAN) # VLAN 4 name MIS/* Create VLAN4 named MIS
VLAN 4 added:
Name: MIS
2950 (VLAN) # apply/* must be submitted using the apply command after creation
Apply complete
2950 (VLAN) # End
2950 #

Port Configuration VLAN:
2950 # config t
2950 (config) # int F0/2
2950 (config-If) # switchport access VLAN 2/* set the port to vlan2
2950 (config-If) # int F0/3
2950 (config-If) # switchport access VLAN 3/* set the port to vlan3
2950 (config-If) # int F0/4
2950 (config-If) # switchport access VLAN 4/* set the port to VLAN4
2950 (config-If) # exit
2950 (config) # exit
2950 #

This static configuration is only suitable for the simplest Small Lan. For a large LAN, we recommend that you use layer-3 switches and enable the VTP protocol for unified configuration. In the subsequentArticleI will introduce how to configure VTP and another important Protocol STP (Spanning Tree Protocol) of the vswitch ).

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.