Vlan负载均衡的实验.doc_第1页
Vlan负载均衡的实验.doc_第2页
Vlan负载均衡的实验.doc_第3页
Vlan负载均衡的实验.doc_第4页
Vlan负载均衡的实验.doc_第5页
免费预览已结束,剩余1页可下载查看

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

图一Cisco Packet Tracer实验图对上图的一些说明:两个交换机通过两个GigabitEthernet端口相连。共创建两个VLAN,Vlan 100与Vlan 200。一、利用switchport trunk allowed vlan vlanid命令实现Vlan负载均衡分别在两个交换机上创建两个VLan:SwitchenSwitch#conf tEnter configuration commands, one per line. End with CNTL/Z.Switch(config)#vlan 100Switch(config-vlan)#vlan 200Switch(config-vlan)#查看创建的Vlan信息Switch(config-vlan)#do show vlanSwitch(config-vlan)#在两个计算机上把相应的端口划到两个VLan内。Switch(config-vlan)#int f0/1Switch(config-if)#switchport mode accessSwitch(config-if)#switchport access vlan 100Switch(config-if)#int fa0/2Switch(config-if)#switchport mode accessSwitch(config-if)#switchport access vlan 200Switch(config-if)#配置trunk端口:Switch(config-if)#int gig0/1Switch(config-if)#switchport trunk encapsulation dot1qSwitch(config-if)#switchport mode trunkSwitch(config-if)#switchport trunk allowed vlan 100Switch(config-if)#int gig0/2Switch(config-if)#switchport trunk encapsulation dot1qSwitch(config-if)#switchport mode trunkSwitch(config-if)#switchport trunk allowed vlan 200Switch(config-if)#为计算机配置IP地址,检查网络是否通畅: Vlan 100的网络地址:192.168.100.0;Vlan 200的网络地址:192.168.200.0以上配置实现了每个Vlan一个专用链路,实现了负载均衡。当某一个链路Down掉后,其中的一个Vlan通信将中断。二、利用STP实现Vlan的负载均衡及链路冗余备份去掉前面的一些配置:Switch(config-if)#no switchport trunk allowed vlan 200Switch(config-if)#int gig0/1Switch(config-if)#no switchport trunk allowed vlan 100Switch(config-if)#为Vlan配置STP:在一个交换上配置:SwitchenSwitch#conf tEnter configuration commands, one per line. End with CNTL/Z.Switch(config)#spanning-tree vlan 100 root primarySwitch(config)#在另一个交换相配置:SwitchenSwitch#conf tEnter configuration commands, one per line. End with CNTL/Z.Switch(config)#spanning-tree vlan 200 root primarySwitch(config)#在一个交换机查看配置:Switch#sh spanning-tree vlan 100VLAN0100 Spanning tree enabled protocol ieee Root ID Priority 24676 Address 0040.0BAB.E471 Cost 4 Port 25(GigabitEthernet0/1) Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec Bridge ID Priority 32868 (priority 32768 sys-id-ext 100) Address 000B.BE94.BD7A Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec Aging Time 20Interface Role Sts Cost Prio.Nbr Type- - - - - -Gi0/2 Altn BLK 4 128.26 P2pGi0/1 Root FWD 4 128.25 P2pFa0/1 Desg FWD 19 128.1 P2pSwitch#sh spanning-tree vlan 200VLAN0200 Spanning tree enabled protocol ieee Root ID Priority 24776 Address 000B.BE94.BD7A This bridge is the root Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec Bridge ID Priority 24776 (priority 24576 sys-id-ext 200) Address 000B.BE94.BD7A Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec Aging Time 20Interface Role Sts Cost Prio.Nbr Type- - - - - -Gi0/2 Desg FWD 4 128.26 P2pGi0/1 Desg FWD 4 128.25 P2pFa0/2 Desg FWD 19 128.2 P2pSwitch#在另一个交换查看配置:Switch#sh spanning-tree vlan 100VLAN0100 Spanning tree enabled protocol ieee Root ID Priority 24676 Address 0040.0BAB.E471 Cost 4 Port 25(GigabitEthernet0/1) Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec Bridge ID Priority 32868 (priority 32768 sys-id-ext 100) Address 000B.BE94.BD7A Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec Aging Time 20Interface Role Sts Cost Prio.Nbr Type- - - - - -Gi0/2 Altn BLK 4 128.26 P2pGi0/1 Root FWD 4 128.25 P2pFa0/1 Desg FWD 19 128.1 P2pSwitch#sh spanning-tree vlan 200VLAN0200 Spanning tree enabled protocol ieee Root ID Priority 24776 Address 000B.BE94.BD7A This bridge is the root Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec Bridge ID Priority 24776 (priority 24576 sys-id-ext 200) Address 000B.BE94.BD7A Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec Aging Time 20Interfa

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论