Comprehensive introduction to layer-3 Switch configuration instances: with detailed command explanations, have you ever encountered layer-3 Switch configuration? Are you familiar with the detailed commands? Does your layer-3 Switch often make your machine difficult? Let's take a look at the layer-3 Switch configuration Article below. All problems can be solved. This article describes in detail the instance Description: Comprehensive layer-3 Switch configuration more comprehensive layer-3 Switch configuration instance (with command explanation yo !)
Layer-3 Switch configuration:
Enable // enter private Mode
Configure terminal // enter global Mode
Service password-encryption // encrypt the password
Hostname Catalyst 3550-12T1 // define the name for the layer-3 Switch
Enable password 123456. // enable password
Enable secret 654321 // The encryption password of enable should be garbled, rather than 654321)
Ip subnet-zero // allow all 0 subnets to be enabled by default)
Ip name-server 172.16.8.1 172.16.8.2 // the Ip address of the layer-3 Switch name Catalyst 3550-12T1 is 172.16.8.1.
Service dhcp // provides the DHCP Service
Ip routing // enable the routing module on the layer-3 Switch
Exit
Layer-3 Switch configuration:
Vtp mode server // defines VTP working mode as sever mode
Vtp domain centervtp // define the name of The VTP domain as centervtp
Vlan 2 name vlan2 // define the vlan and name the vlan. If no name is specified, the name of vlan2 should be vlan002)
Vlan 3 name vlan3
Vlan 4 name vlan4
Vlan 5 name vlan5
Vlan 6 name vlan6
Vlan 7 name vlan7
Vlan 8 name vlan8
Vlan 9 name vlan9
Exit
Layer-3 Switch configuration:
Interface Port-channel 1 // enter the virtual ethernet channel Group 1
Switchport trunk encapsulation dot1q // encapsulate the trunk for this interface as the 802.1Q frame format
Switchport mode trunk // defines the operation mode of this interface as trunk
Switchport trunk allowed vlan all // this trunk allows all VLANs to pass through
Interface gigabitethernet 0/1 // enter the guitar Ethernet 1 on Module 0
Switchport trunk encapsulation dotlq // encapsulate the trunk for this interface as the 802.1Q frame format
Switchport mode trunk // defines the operation mode of this interface as trunk
Switchport trunk allowed vlan all // this trunk allows all VLANs to pass through
Channel-group 1 mode on // place this interface in Fast Ethernet channel group 1
Interface gigabitethernet 0/2 // same as above
Switchport trunk encapsulation dotlq
Switchport mode trunk
Switchport trunk allowed vlan all
Channel-group 1 mode on
Layer-3 Switch configuration:
Port-channel load-balance src-dst-ip // defines the load balancing mode of the Fast Ethernet channel group according to * Source and Destination IP)
Interface gigabitethernet 0/3 // enter the guitar Ethernet Port 3 on Module 0
Switchport trunk encapsulation dotlq // encapsulate trunk as 802.1Q
Switchport mode trunk // defines the operation mode of this interface as trunk
Switchport trunk allowed vlan all // allow all vlan information to pass through
Interface gigabitethernet 0/4 // same as above
Switchport trunk encapsulation dotlq
Switchport mode trunk
Switchport trunk allowed vlan all
Interface gigbitethernet 0/5 // same as above
Switchport trunk encapsulation dotlq
Switchport mode trunk
Switchport trunk allowed vlan all
Interface gigbitethernet 0/6 // same as above
Switchport trunk encapsulation dotlq
Switchport mode trunk
Switchprot trunk allowed vlan all
Layer-3 Switch configuration:
Interface gigbitethernet 0/7 // enter the gibit Ethernet port 7 on Module 0
Switchport mode access // defines the operation mode of this interface as access mode
Switchport access vlan 9 // defines which vlan this interface can access. Actually, this interface is allocated to the vlan)
No shutdown
Spanning-tree vlan 6-9 cost 1000 // in the production tree, the overhead of the vlan6-9 is defined as 10000
Interface range gigabitethernet 0/8-10 // enter the gibit Ethernet ports, 10 on Module 0
Switchport mode access // define the operation mode of these interfaces as access mode
Switchport access vlan 8 // allocate these interfaces to vlan8
No shutdown
Layer-3 Switch configuration:
Spanning-tree portfast // After portfast is used on these interfaces and portfast is used, the operation is not performed when the tree is generated and directly becomes the forwarding status)
Interface gigabitethernet 0/11 // enter the gibit Ethernet port 11 on Module 0
Switchport trunk encapsulation dotlq // encapsulate this interface as 802.1Q
Switchport mode trunk // defines the operation mode of this interface as trunk
Switchport trunk allowed vlan all // allow all vlan information to pass through
Interface gigabitethernet 0/12 // same as above
Switchport trunk encapsulation dotlq
Switchport mode trunk
Switchport trunk allowed vlan all
Interface vlan 1 // The logical interface to enter vlan1 is not a physical interface, used for routing vlan)
Ip address 172.16.1.7 255.255.255.0 // configure the ip address and subnet mask
No shutdown