华为交换机基本配置命令详解.doc

上传人:F****n 文档编号:101896927 上传时间:2019-09-30 格式:DOCX 页数:9 大小:26.88KB
返回 下载 相关 举报
华为交换机基本配置命令详解.doc_第1页
第1页 / 共9页
华为交换机基本配置命令详解.doc_第2页
第2页 / 共9页
华为交换机基本配置命令详解.doc_第3页
第3页 / 共9页
华为交换机基本配置命令详解.doc_第4页
第4页 / 共9页
华为交换机基本配置命令详解.doc_第5页
第5页 / 共9页
点击查看更多>>
资源描述

《华为交换机基本配置命令详解.doc》由会员分享,可在线阅读,更多相关《华为交换机基本配置命令详解.doc(9页珍藏版)》请在金锄头文库上搜索。

1、华为交换机基本配置命令详解1、配置文件相关命令Quidwaydisplaycurrent-configuration显示当前生效的配置Quidwaydisplaysaved-configuration显示flash中配置文件,即下次上电启动时所用的配置文件resetsaved-configuration檫除旧的配置文件reboot交换机重启displayversion显示系统版本信息2、基本配置Quidwaysuperpassword修改特权用户密码Quidwaysysname交换机命名Quidwayinterfaceethernet1/0/1进入接口视图Quidwayinterfacevla

2、n1进入接口视图Quidway-Vlan-interfacexipaddress10.1.1.11255.255.0.0配置VLAN的IP地址Quidwayiproute-static0.0.0.00.0.0.010.1.1.1 静态路由网关3、telnet配置Quidwayuser-interfacevty04进入虚拟终端S3026-ui-vty0-4authentication-modepassword设置口令模式S3026-ui-vty0-4setauthentication-modepasswordsimplexmws123设置口令S3026-ui-vty0-4userprivileg

3、elevel3用户级别4、端口配置Quidway-Ethernet1/0/1duplexhalf|full|auto配置端口工作状态Quidway-Ethernet1/0/1speed10|100|auto配置端口工作速率Quidway-Ethernet1/0/1flow-control配置端口流控Quidway-Ethernet1/0/1mdiacross|auto|normal配置端口平接扭接Quidway-Ethernet1/0/1portlink-typetrunk|access|hybrid设置端口工作模式Quidway-Ethernet1/0/1undoshutdown激活端口Qu

4、idway-Ethernet1/0/2quit退出系统视图5、链路聚合配置DeviceAlink-aggregationgroup1modemanual创建手工聚合组1Qw_Ainterfaceethernet1/0/1将以太网端口Ethernet1/0/1加入聚合组1Qw_A-Ethernet1/0/1portlink-aggregationgroup1Qw_A-Ethernet1/0/1interfaceethernet1/0/2将以太网端口Ethernet1/0/1加入聚合组1Qw_A-Ethernet1/0/2portlink-aggregationgroup1Qw_Alink-agg

5、regationgroup1service-typetunnel#在手工聚合组的基础上创建tunnel业务环回组。Qw_Ainterfaceethernet1/0/1将以太网端口Ethernet1/0/1加入业务环回组。Qw_A-Ethernet1/0/1undostpQw_A-Ethernet1/0/1portlink-aggregationgroup16、端口镜像Quidwaymonitor-port指定镜像端口Quidwayportmirror指定被镜像端口Quidwayportmirrorint_listobserving-portint_typeint_num指定镜像和被镜像7、VL

6、AN配置Quidwayvlan4创建VLANQuidway-vlan4portethernet1/0/1toethernet1/0/4在VLAN中增加端口配置基于access的VLANQuidway-Ethernet1/0/2portaccessvlan4当前端口加入到VLAN注意:缺省情况下,端口的链路类型为Access类型,所有Access端口均属于且只属于VLAN1配置基于trunk的VLANQuidway-Ethernet1/0/24portlink-typetrunk 设置当前端口为trunkQuidway-Ethernet1/0/24porttrunkpermitvlanID|Al

7、l设trunk允许的VLAN注意:所有端口缺省情况下都是允许VLAN1的报文通过的Quidway-Ethernet1/0/2porttrunkpvidvlan34设置trunk端口的PVID配置基于Hybrid端口的VLANQuidway-Ethernet1/0/2portlink-typehybrid配置端口的链路类型为Hybrid类型Quidway-Ethernet1/0/2porthybridvlanvlan-id-listtagged|untagged允许指定的VLAN通过当前Hybrid端口注意:缺省情况下,所有Hybrid端口只允许VLAN1通过Quidway-Ethernet1/

8、0/2porthybridpvidvlanvlan-id设置Hybrid端口的缺省VLAN注意:缺省情况下,Hybrid端口的缺省VLAN为VLAN1VLAN描述Quidwaydescriptionstring指定VLAN描述字符Quidwayundodescription删除VLAN描述字符Quidwaydisplayvlanvlan_id查看VLAN设置私有VLAN配置Qw_A-vlanxisolate-user-vlanenable设置主vlanQw_AIsolate-user-vlansecondary设置主vlan包括的子vlanQuidway-Ethernet1/0/2porthy

9、bridpvidvlan设置vlan的pvidQuidway-Ethernet1/0/2porthybridpvid删除vlan的pvidQuidway-Ethernet1/0/2porthybridvlanvlan_id_listuntagged设置无标识的vlan如果包的vlanid与PVId一致,则去掉vlan信息.默认PVID=1。所以设置PVID为所属vlanid,设置可以互通的vlan为untagged.8、STP配置Quidwaystpenable|disable设置生成树,默认关闭Quidwaystpmoderstp设置生成树模式为rstpQuidwaystppriority8

10、192设置交换机的优先级Quidwaystprootprimary|secondary设置为根或根的备份Quidway-Ethernet0/1stpcost200设置交换机端口的花费MSTP配置:#配置MST域名为info,MSTP修订级别为1,VLAN映射关系为VLAN2VLAN10映射到生成树实例1上,VLAN20VLAN30映射生成树实例2上。system-viewSysnamestpregion-configurationSysname-mst-regionregion-nameinfoSysname-mst-regioninstance1vlan2to10Sysname-mst-re

11、gioninstance2vlan20to30Sysname-mst-regionrevision-level1Sysname-mst-regionactiveregion-configuration9、MAC地址表的操作在系统视图下添加MAC地址表项Quidwaymac-addressstatic|dynamic|blackholemac-addressinterfaceinterface-typeinterface-numbervlanvlan-id;添加MAC地址表项在添加MAC地址表项时,命令中interface参数指定的端口必须属于vlan参数指定的VLAN,否则将添加失败。如果vlan参数指定的VLAN是动态VLAN,在添加静态MAC地址之后,会自动变为静态VLAN。在以太网端口视图下添加MAC地址表项Quidway-Ethernet1/0/2mac-addressstatic|dynamic|blackholemac-addressvlanvlan-id在添加MAC地址表项时,当前的端口必须属于命令中vlan参数指定的VLAN,否则将添加失败;如果vlan参数指定的VLAN是动态VLAN,在添加静态MAC地址之后,会自动变为静态VLAN。Quidwaymac-addresstimeragingage|no-aging设置MAC地

展开阅读全文
相关资源
相关搜索

当前位置:首页 > 办公文档 > 教学/培训

电脑版 |金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号