思科命令大全

上传人:工**** 文档编号:483220272 上传时间:2023-07-08 格式:DOCX 页数:27 大小:19.42KB
返回 下载 相关 举报
思科命令大全_第1页
第1页 / 共27页
思科命令大全_第2页
第2页 / 共27页
思科命令大全_第3页
第3页 / 共27页
思科命令大全_第4页
第4页 / 共27页
思科命令大全_第5页
第5页 / 共27页
点击查看更多>>
资源描述

《思科命令大全》由会员分享,可在线阅读,更多相关《思科命令大全(27页珍藏版)》请在金锄头文库上搜索。

1、1.设置主机名/系统名IOS:switch(config)# hostname hostnameCLI:switch(enable) set system name name-string2设置登录口令 IOS:switch(config)# enable password level 1 passwordCLI:switch(enable) set passwordswitch(enable) set enalbepass3设置远程访问 IOS:switch(config)# interface vlan 1switch(config-if)# ip address ip-address n

2、etmaskswitch(config-if)# ip default-gateway ip-addressCLI:switch(enable) set interface sc0 ip-address netmask broadcast-addressswitch(enable) set interface sc0 vlanswitch(enable) set ip route default gateway4启用和浏览CDP信息IOS:switch(config-if)# cdp enableswitch(config-if)# no cdp enableCLI:switch(enable

3、) set cdp enable|disable module/port5查看Cisco邻接设备的CDP通告IOS:switch# show cdp interface type modle/portswitch# show cdp neighbors type module/port detailCLI:switch(enable) show cdp neighborsmodule/port vlan|duplex|capabilities|detail6端口描述 IOS:switch(config-if)#description escription-stringCLI:switch(en

4、able)set port name module/number description-string7设置端口速度IOS:switch(config-if)# speed10|100|autoCLI:switch(enable) set port speed moudle/number 10|100|autoswitch(enable) set port speed moudle/number 4|16|auto8设置以太网的链路模式IOS:switch(config-if)# duplex auto|full|halfCLI:switch(enable) set port duplex m

5、odule/number full|half9配置静态VLANIOS:switch# vlan databaseswitch(vlan)# vlan vlan-num name vlaswitch(vlan)# exitswitch# configure teriminalswitch(config)#interface interface module/numberswitch(config-if)# switchport mode accessswitch(config-if)# switchport access vlan vlan-numswitch(config-if)# endCL

6、I:switch(enable) set vlan vlan-num name nameswitch(enable) set vlan vlan-num mod-num/port-list10配置VLAN中继线IOS:switch(config)# interface interface mod/portswitch(config-if)# switchport mode trunkswitch(config-if)#switchport trunk encapsulation isl|dotlqswitch(config-if)# switchport trunk allowed vlan

7、remove vlan-listswitch(config-if)# switchport trunk allowed vlan add vlan-listCLI:switch(enable)set trunk module/port on|off|desirable|auto|nonegotiateVlan-range isl|dotlq|dotl0|lane|negotiate11配置VTP管理域IOS:switch# vlan databaseswitch(vlan)# vtp domain domain-nameCLI:switch(enable) set vtp domain dom

8、ain-name12配置VTP 模式IOS:switch# vlan databaseswitch(vlan)# vtp domain domain-nameswitch(vlan)# vtp sever|cilent|transparentswitch(vlan)# vtp password passwordCLI:switch(enable) set vtp domain domain-name mode sever|cilent|transparent password password13配置VTP版本IOS:switch# vlan databaseswitch(vlan)# vtp

9、 v2-modeCLI:switch(enable) set vtp v2 enable14启动VTP剪裁IOS:switch# vlan databaseswitch(vlan)# vtp pruningCLI:switch(enable) set vtp pruning enable15配置以太信道IOS:switch(config-if)# port group group-number distribution source|destinationCLI:switch(enable) set port channel moudle/port-range modeon|off|desir

10、able|auto16调整根路径成本IOS:switch(config-if)#spanning-tree vlan vlan-list cost costCLI:switch(enable)set spantree portcost moudle/port costswitch(enable)set spantree portvlancost moudle/port cost costvlan-list17调整端口IDIOS:switch(config-if)#spanning-treevlan vlan-listport-priority port-priorityCLI:switch(e

11、nable)set spantree portpri mldule/portpriorityswitch(enable)set spantree portvlanpri module/portpriority vlans18修改STP时钟 IOS:switch(config)# spanning-tree vlan vlan-list hello-time secondsswitch(config)#spanning-tree vlan vlan-list forward-time secondsswitch(config)#spanning-tree vlan vlan-list max-a

12、ge secondsCLI:switch(enable) set spantree hello intervalvlanswitch(enable) set spantree fwddelay delay vlanswitch(enable) set spantree maxage agingtiamevlan19.启用或禁用Port Fast 特征IOS:switch(config-if)#spanning-tree portfastCLI:switch(enable)set spantree portfast module/portenable|disable 20.启用或禁用Uplink

13、Fast 特征IOS:switch(config)#spanning-tree uplinkfast max-update-rate pkts-per-secondCLI:switch(enable)set spantree uplinkfast enable|disablerate update-rate all-protocols off|on为了将交换机配置成一个集群的命令交换机,首先要给管理接口分配一个IP地址,然后使用下列命令:switch(config)# cluster enable cluster-name21. 为了从一条中继链路上删除VLAN,可使用下列命令:switch(

14、enable) clear trunk module/port vlan-range22. 用show vtp domain 显示管理域的VTP参数.23. 用show vtp statistics显示管理域的VTP参数.24. 在Catalyst交换机上定义TrBRF的命令如下:switch(enable) set vlan vlan-name name name type trbrf bridge bridge-numstp ieee|ibm25. 在Catalyst交换机上定义TrCRF的命令如下:switch (enable) set vlan vlan-num name name type trcrf ring hex-ring-num|decring decimal-ring-num parent vlan-num26. 在创建好TrBRF VLAN之后,就可以给它分配交换机端口.对于以太网交换,可以采用如下命令给VLAN分配端口:switch(enable) set vlan vlan-num mod-num/port-num27. 命令show spantree显示一个交换机端口的STP状态.28. 配置一个ELAN的LES和BUS,可以使用下列命令: ATM (config)

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

当前位置:首页 > 高等教育 > 其它相关文档

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