实验一:交换机端口类型配置

1.拓扑图如下图所示: 2.实验要求:实现二层网络中工程部和市场部不能互访,但是都能与网络中心的服务器通信 3.请写出你的配置思路、配置命令

实验思路:将交换机SW1、SW2、SW3之间配置为trunk链路,其他接口配置为Hybrid链路;
	实验配置名如下:

SW1 sysname SW1 vlan batch 10 100 200 interface Ethernet0/0/1 port link-type hybrid port hybrid tagged vlan 10 100 200 interface Ethernet0/0/2 port link-type trunk port trunk allow-pass vlan all quit SW2 sysname SW2 vlan batch 10 100 200 interface Ethernet0/0/1 port link-type hybrid port hybrid tagged vlan 10 100 200 interface Ethernet0/0/2 port link-type trunk port trunk allow-pass vlan all interface Ethernet0/0/3 port link-type trunk port trunk allow-pass vlan all quit SW3 sysname SW3 vlan batch 10 100 200 interface Ethernet0/0/1 port link-type hybrid port hybrid tagged vlan 10 100 200 interface Ethernet0/0/3 port link-type trunk port trunk allow-pass vlan all quit SW4 sysname SW4 vlan batch 10 100 200 interface Ethernet0/0/1 port link-type hybrid port hybrid tagged vlan 10 100 200 interface Ethernet0/0/2 port link-type hybrid port hybrid pvid vlan 10 port hybrid untagged vlan 10 100 port hybrid tagged vlan 200 interface Ethernet0/0/3 port hybrid pvid vlan 10 port link-type hybrid port hybrid untagged vlan 10 100 port hybrid tagged vlan 200 quit SW5 sysname SW5 vlan batch 10 100 200 interface Ethernet0/0/1 port link-type hybrid port hybrid tagged vlan 10 100 200 interface Ethernet0/0/2 port link-type hybrid port hybrid pvid vlan 100 port hybrid untagged vlan 10 100 200 interface Ethernet0/0/3 port link-type hybrid port hybrid pvid vlan 100 port hybrid untagged vlan 10 100 200 quit SW6 sysname SW6 vlan batch 10 100 200 interface Ethernet0/0/1 port link-type hybrid port hybrid tagged vlan 10 100 200 interface Ethernet0/0/2 port link-type hybrid port hybrid pvid vlan 200 port hybrid untagged vlan 100 200 port hybrid tagged vlan 10 interface Ethernet0/0/3 port link-type hybrid port hybrid pvid vlan 200 port hybrid untagged vlan 100 200 port hybrid tagged vlan 10 quit

实验二:实现全网互通

1.以此拓扑为题,实现全网互通 2.实验要求: 1)实现vlan10、vlan20、vlan100、vlan200彼此互通; 2)可以通过SW1远程访问SW2 3.请写出你的配置思路、配置命令

配置思路:配置Vlan、静态路由
	配置命令如下:

R1 system-view sysname R1 interface g0/0/1 ip address 192.168.12.1 24 interface g0/0/2 ip address 192.168.10.254 24 quit ip route-static 0.0.0.0 0.0.0.0 192.168.12.2 R2 system-view sysname R2 interface g0/0/0 ip address 192.168.12.2 24 interface g0/0/1 ip address 192.168.23.2 24 interface g0/0/2 ip address 192.168.30.1 24 quit ip route-static 192.168.10.0 24 192.168.12.1 ip route-static 192.168.20.0 24 192.168.23.3 ip route-static 192.168.100.0 24 192.168.30.2 ip route-static 192.168.200.0 24 192.168.30.2 R3 system-view sysname R3 interface g0/0/0 ip address 192.168.23.3 24 interface g0/0/2 ip address 192.168.20.254 24 quit ip route-static 0.0.0.0 0.0.0.0 192.168.23.2 SW1 system-view sysname SW1 vlan 10 quit port-group 1 group-member Ethernet 0/0/1 to Ethernet 0/0/3 port link-type access port default vlan 10 quit interface Vlanif 10 ip address 192.168.10.10 24 quit ip route-static 0.0.0.0 0.0.0.0 192.168.10.254 SW2 system-view sysname SW2 vlan batch 100 200 30 interface GigabitEthernet 0/0/1 port link-type access port default vlan 100 interface GigabitEthernet 0/0/2 port link-type access port default vlan 200 interface GigabitEthernet 0/0/3 port link-type access port default vlan 30 interface Vlanif 100 ip address 192.168.100.254 24 interface Vlanif 200 ip address 192.168.200.254 24 interface Vlanif 30 ip address 192.168.30.2 24 quit ip route-static 0.0.0.0 0.0.0.0 192.168.30.1 user-interface vty 0 4 authentication-mode password set authentication password cipher 123456 user privilege level 15 quit SW3 system-view sysname SW3 vlan 20 quit port-group 1 group-member Ethernet 0/0/1 to Ethernet 0/0/3 port link-type access port default vlan 20 quit

实验三:实现负载均衡

1.如下图所示,实现vlan10、vlan20流量负载均衡; 2.实验要求 1)实现client1、client2访问server1、server2时流量负载均衡; 2)判断访问路径是否最优 3.请写出你的配置思路、配置命令

配置思路:配置多实例生成树
	配置命令如下:

SW1 system-view sysname SW1 vlan batch 10 20 port-group 1 group-member Ethernet 0/0/1 Ethernet 0/0/2 port link-type trunk port trunk allow-pass vlan all quit interface Ethernet0/0/10 port link-type access port default vlan 10 interface Ethernet0/0/20 port link-type access port default vlan 20 quit stp region-configuration region-name ntd instance 10 vlan 10 instance 20 vlan 20 active region-configuration quit stp instance 10 root secondary stp instance 20 root secondary SW2 system-view sysname SW2 vlan batch 10 20 port-group 1 group-member Ethernet 0/0/1 Ethernet 0/0/2 port link-type trunk port trunk allow-pass vlan all quit interface Ethernet0/0/10 port link-type access port default vlan 10 quit stp region-configuration region-name ntd instance 10 vlan 10 instance 20 vlan 20 active region-configuration quit stp instance 10 root primary SW3 system-view sysname SW3 vlan batch 10 20 port-group 1 group-member Ethernet 0/0/1 Ethernet 0/0/2 port link-type trunk port trunk allow-pass vlan all quit interface Ethernet0/0/20 port link-type access port default vlan 20 quit stp region-configuration region-name ntd instance 10 vlan 10 instance 20 vlan 20 active region-configuration quit stp instance 20 root primary

在此院哥祝愿大家 : 新春快乐,2019猪年大吉,猪事顺利 ^-^