资源预览内容
第1页 / 共6页
第2页 / 共6页
第3页 / 共6页
第4页 / 共6页
第5页 / 共6页
第6页 / 共6页
亲,该文档总共6页全部预览完了,如果喜欢就下载吧!
资源描述
实验九: 两台交换机划分VLAN配置实验目标: 理解虚拟VLAN基本配置; 掌握一般交换机按端口划分VLAN的配置方法; 掌握Tag VLAN配置方法实验背景: 某一公司内财务部,销售部的PC通过2台交换机实现通信:要求财务部和销售部的PC机可以互通,但是为了数据安全起见,销售部和财务部需要进行互相隔离,现要在交换机上做适当配置来实现这一标准。技术原理: VLAN是指在一个物理网段内,进行逻辑的划分,划分成若干个虚拟局域网,VLAN最大的特性是不受物理位置的限制,可以进行灵活的划分。VLAN具备了一个物理网段所具备的特性。相同VLAN内的主机之间可以直接通信,不同VLAN间的主机之间相互访问必须经路由设备进行转发,广播数据包只可以在本VLAN内进行广播,不能传输到其他VLAN中。 portVLAN是实现VLAN的方式之一,他利用交换机的端口进行VLAN划分,一个端口只能属于一个VLAN。实验步骤:新建packet tracer拓扑图 划分VLAN 将端口划分到相应VLAN中 设置VLAN Trunk属性 测试实验设备: Switch_2960 2台;PC4台;直连线交换机和PC机配置过程如下:SwitchenSwitch#conf tEnter configuration commands, one per line. End with CNTL/Z.Switch(config)#hostname Switch1Switch1(config)#vlan 2Switch1(config-vlan)#exitSwitch1(config)#vlan 3Switch1(config-vlan)#exitSwitch1(config)#int f0/1Switch1(config-if)#switchport access vlan 2Switch1(config-if)#exitSwitch1(config)#int f0/2Switch1(config-if)#switchport access vlan 3Switch1(config-if)#exitSwitch1(config)#int f0/24Switch1(config-if)#switchport mode trunk(红色的是交换机自动生成的参数代码)%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/24, changed state to down%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/24, changed state to upSwitch(config-if)#end%SYS-5-CONFIG_I: Configured from console by consoleSwitch#show vlanSwitchenSwitch#conf tSwitch(config)#hostname Switch2Switch2(config)#vlan 2Switch2(config-vlan)#exitSwitch2(config)#vlan 3Switch2(config-vlan)#exitSwitch2(config)#int f0/1Switch2(config-if)#switchport access vlan 2Switch2(config-if)#exitSwitch2(config)#int f0/2Switch2(config-if)#switchport access vlan 3Switch2(config-if)#exitSwitch2(config)#int f0/24Switch2(config-if)#switchport mode trunk(红色的是交换机自动生成的参数代码)%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/24, changed state to down%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/24, changed state to upSwitch2(config-if)#end%SYS-5-CONFIG_I: Configured from console by consoleSwitch2#show vlan四台PC机的配置省略!测试:分别去测试PC1和PC3是通的,PC2和PC4是通的,其他都不通。
收藏 下载该资源
网站客服QQ:2055934822
金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号