A typical LAN is to connect a core switch with a layer-3 Switch to several Branch switches (not necessarily with layer-3 switching ). We assume that the core switch name is com, and the Branch switches are par1, par2, and par3 respectively, which are connected to the core switch through the light module of port 1; assume that the vlan names are counter, market, and managing ......
Work to be done:
1. Set vtp domain (both core and Branch switches)
2. Configure Relay (both core and Branch switches)
3. Create a vlan (set on the server)
4. Route vswitch ports to vlan
5. configure Layer-3 Switching
1. Set vtp domain. Vtp domain is called a management domain.
All switches that exchange vtp update information must be configured with the same management domain. If all the switches are connected by a trunk, you only need to set a management domain on the core switch, and all the switches on the network are added to this domain, in this way, all the switches in the management domain can understand the vlan list of each other.
Com # Switch vlan database to vlan configuration mode
Com (vlan) # vtp domain com set vtp management domain name com
Com (vlan) # vtp server sets the switch to the server mode
Par1 # Switch vlan database to vlan configuration mode
Par1 (vlan) # Set vtp domain com
Par1 (vlan) # vtp client sets the switch to the client Mode
Par2 # Switch vlan database to vlan configuration mode
Par2 (vlan) # Set vtp domain com
Par2 (vlan) # vtp client sets the switch to the client Mode
Par3 # Switch vlan database to vlan configuration mode
Par3 (vlan) # Set vtp domain com
Par3 (vlan) # vtp client sets the switch to the client Mode
Note: Setting the core switch to the server mode allows you to create, modify, and delete VLANs and other configuration parameters for the entire vtp domain on the switch, synchronize the latest vlan information transmitted by other switches in The vtp domain. The client Mode means that the vswitch cannot create, delete, or modify vlan configurations, nor store vlan configurations in nvram, however, the vlan information transmitted by other switches in The vtp domain can be synchronized.
2. Configure relay to ensure that the management domain can cover all Branch switches.
The cisco switch can support any media as a trunk line. To achieve relay, you can use its unique isl tag. Isl (inter-switch link) is a protocol for transmitting vlan information and vlan data streams between switches, between switches and routers, and between switches and servers, by configuring isl encapsulation on the port directly connected to the vswitch, you can allocate and configure VLANs across the entire network.
The core switch is configured as follows:
Com (config) # interface gigabitethernet 2/1
Com (config-if) # switchport
Com (config-if) # switchport trunk encapsulation isl configure the relay Protocol
Com (config-if) # switchport mode trunk
Com (config) # interface gigabitethernet 2/2
Com (config-if) # switchport
Com (config-if) # switchport trunk encapsulation isl configure the relay Protocol
Com (config-if) # switchport mode trunk
Com (config) # interface gigabitethernet 2/3
Com (config-if) # switchport
Com (config-if) # switchport trunk encapsulation isl configure the relay Protocol
Com (config-if) # switchport mode trunk
The configuration on the branch switch side is as follows:
Par1 (config) # interface gigabitethernet 0/1
Par1 (config-if) # switchport mode trunk
Par2 (config) # interface gigabitethernet 0/1
Par2 (config-if) # switchport mode trunk
Par3 (config) # interface gigabitethernet 0/1
Par3 (config-if) # switchport mode trunk
Now, the management domain is set.
3. Once a management domain is created, you can create a vlan.
Com (vlan) # vlan 10 name counter creates a vlan numbered 10 and named counter.
Com (vlan) # vlan 11 name market creates a vlan numbered 11 and named market
Com (vlan) # vlan 12 name managing creates a vlan numbered 12 and named managing.
Note that the vlan here is created on the core switch. In fact, as long as the vlan is created on any vtp vswitch with the server attribute in the management domain, it notifies all switches in the entire management domain through vtp. If you want to add a specific switch port to a vlan, you must set it on the switch to which the port belongs.
4. Route vswitch ports to vlan
For example, par1, par2, par3 ...... Port 1 of the branch switch is allocated to the counter vlan, Port 2 is allocated to the market vlan, and Port 3 is allocated to the management vlan ......
Par1 (config) # interface fastethernet 0/1 Configure port 1
Par1 (config-if) # switchport access vlan 10 belongs to the counter vlan
Par1 (config) # interface fastethernet 0/2 Configure port 2
Par1 (config-if) # switchport access vlan 11 belongs to the market vlan
Par1 (config) # interface fastethernet 0/3 Configure port 3
Par1 (config-if) # switchport access vlan 12 belongs to the management vlan
Par2 (config) # interface fastethernet 0/1 Configure port 1
Par2 (config-if) # switchport access vlan 10 belongs to the counter vlan
Par2 (config) # interface fastethernet 0/2 Configure port 2
Par2 (config-if) # switchport access vlan 11 belongs to the market vlan
Par2 (config) # interface fastethernet 0/3 Configure port 3
Par2 (config-if) # switchport access vlan 12 belongs to the management vlan
Par3 (config) # interface fastethernet 0/1 Configure port 1
Par3 (config-if) # switchport access vlan 10 belongs to the counter vlan
Par3 (config) # interface fastethernet 0/2 Configure port 2
Par3 (config-if) # switchport access vlan 11 belongs to the market vlan
Par3 (config) # interface fastethernet 0/3 Configure port 3
Par3 (config-if) # switchport access vlan 12 belongs to the management vlan
5. configure Layer-3 Switching
Now, vlan division is complete. However, how does one implement layer-3 (Network Layer) switching between VLANs? In this case, we need to allocate Network (ip) addresses to each vlan. You can assign an IP address to a vlan in two ways: one is to assign a static IP address to all nodes in the vlan, and the other is to assign a dynamic IP address to all nodes in the vlan. The two cases are described below.
Assume that the interface IP address assigned to the vlan counter is 172.16.58.1/24 and the network address is 172.16.58.0,
The interface IP address allocated by the vlan market is 172.16.59.1/24, and the network address is 172.16.59.0,
The interface IP address for vlan management is 172.16.60.1/24 and the network address is 172.16.60.0.
......
If an IP address is dynamically assigned, set the IP address of the dhcp server on the network to 172.16.1.11.
(1) assign a static IP address to all nodes in the vlan.
First, set the interface IP addresses of each vlan on the core switch. The core switch treats vlan as an interface, just like on a vro, as shown below:
Com (config) # interface vlan 10
Com (config-if) # ip address 172.16.58.1 255.255.255.0 vlan10 interface ip
Com (config) # interface vlan 11
Com (config-if) # ip address 172.16.59.1 255.255.255.0 vlan11 interface ip
Com (config) # interface vlan 12
Com (config-if) # ip address 172.16.60.1 255.255.255.0 vlan12 interface ip
Then, set the IP address that is consistent with the network address of the vlan on the computer of each access vlan, and set the default gateway as the interface address of the vlan. In this way, all VLANs can access each other.
(2) Assign Dynamic IP addresses to all nodes in the vlan.
First, set the interface IP addresses of each vlan and the IP addresses of the same dhcp server on the core switch, as shown below:
Com (config) # interface vlan 10
Com (config-if) # ip address 172.16.58.1 255.255.255.0 vlan10 interface ip
Com (config-if) # ip helper-address 172.16.1.11 dhcp server ip
Com (config) # interface vlan 11
Com (config-if) # ip address 172.16.59.1 255.255.255.0 vlan11 interface ip
Com (config-if) # ip helper-address 172.16.1.11 dhcp server ip
Com (config) # interface vlan 12
Com (config-if) # ip address 172.16.60.1 255.255.255.0 vlan12 interface ip
Com (config-if) # ip helper-address 172.16.1.11 dhcp server ip
On the dhcp server, set the network addresses to 172.16.58.0, 172.16.59.0, and 172.16.60.0 respectively, and set the "Router" option of these scopes to the interface IP address of the corresponding vlan. In this way, all VLANs can be exchanged.
Finally, set the network in the computer of each access vlan and set the IP address option to automatically get the article entry: csh responsible editor: csh