cisco2960配置命令.docx

上传人:小飞机 文档编号:3154584 上传时间:2023-03-11 格式:DOCX 页数:6 大小:37.83KB
返回 下载 相关 举报
cisco2960配置命令.docx_第1页
第1页 / 共6页
cisco2960配置命令.docx_第2页
第2页 / 共6页
cisco2960配置命令.docx_第3页
第3页 / 共6页
cisco2960配置命令.docx_第4页
第4页 / 共6页
cisco2960配置命令.docx_第5页
第5页 / 共6页
亲,该文档总共6页,到这儿已超出免费预览范围,如果喜欢就下载吧!
资源描述

《cisco2960配置命令.docx》由会员分享,可在线阅读,更多相关《cisco2960配置命令.docx(6页珍藏版)》请在三一办公上搜索。

1、cisco2960配置命令配置密码:2960>en ;第一次密码为空 2960h#conf t ;进入全局配置模式 2960(config)#hostname swa ;设置交换机名 2960(config)#enable secret aaa ;设置特权加密口令为 aaa 2960(config)#enable password aax ;设置特权非密口令为 aax 2960(config)#line console 0 ;进入控制台口(Rs232) 2960(config-line)#password aa ;设置登录口令aa 2960(config-line)#login ;登录要求

2、口令验证 2960(config-line)#line vty 0 4 ;进入虚拟终端virtual tty 2960(config-line)#password a ;设置登录口令a 2960(config-line)#login ;登录要求口令验证 2960(config-line)#exit ;返回上一层 2960(config)#exit ;返回上一层 2960#sh run ;看配置信息 2960#exit ;返回命令配置Vlan新建一个Vlan的命令Switch>enable 进入特权模式 Switchconfigure terminal 进入全局配置模式 Switch (co

3、nfig)# vlan vlan-id 创建一个Vlan或者进入Vlan配置模式 Switch (config-vlan)# name vlan-name 给Vlan命名(取消设置:no name) Switch (config-vlan)# mtu mtu-size 设置最大通讯量(取消设置:no mtu) Switch (config-vlan)#remote-span 开启远程流量监控(关闭:no remote-span) Switch (config-vlan)# end 回到特权模式 Switchshow vlan name vlan-name | id vlan-id 查看当前配置

4、 Switchcopy running-config startup config 保存配置删除Vlan的命令Switch>enable 进入特权模式 Switchconfigure terminal 进入全局配置模式 Switch (config)# no vlan vlan-id 删除Vlan Switch (config)# end 回到特权模式 Switchshow vlan brief 查看删除情况 Switchcopy running-config startup config 保存配置端口加入特定Vlan的命令Switch>enable 进入特权模式 Switchconf

5、igure terminal 进入全局配置模式 Switch (config)# interface interface-id 进入端口配置 Switch (config-if)# switchport mode access 将接口的模式设为访问模式 Switch (config-if)# switchport access vlan vlan-id 将端口加入指定的Vlan(恢复端口默认配置:default interface interface-id) Switch (config-if)# end 回到特权模式 Switchshow running-config interface i

6、nterface-id 查看端口模式 Switchshow interfaces interface-id switchport 查看端口详细配置 Switchcopy running-config startup-config 保存配置批量端口加入特定Vlan的命令int range fa0/1 - 10 switchport access VLan V2将特定端口设为trunk2960-01(config)#default interface fastEthernet 0/1 端口恢复默认值 2960-01(config)#interface fastethernet0/1 进入端口模式2

7、960-01(config-if)#switchport mode trunk 设置端口为trunk模式2960-01(config-if)#switchport nonegotiate 将接口设置为不协商模式2960-01(config-if)end2960-01#wr启用snmp Switch>enable 进入特权模式 Switchconfigure terminal 进入全局配置模式 Switch (config)# snmp-server community string view view-name ro | rw access-list-number (关闭snmp: no

8、snmp-server) (删除团体字符: no snmp-server community string) 配置snmp团体字符并开启snmp代理服务 String: 团体口令字符(所有SNMP命令中只有设置团体口令的snmp-server community是必须的,其它的都是可选的.) View: view 可以用于限定哪些MIB分支不能用本community-string存取预先用snmp-server view定义 ro | rw: ro获得MIB对象信息;rw获得并可以修改MIB对象信息 access-list-number:访问列表号 Switch (config)#access

9、-list access-list-number deny | permit source source-wildcard 配置拒绝或者允许访问snmp代理服务的IP地址,访问列表号为上一步指定的列表号 Switch (config)#end 回到特权模式 Switchshow running-config 查看配置 Switchcopy running-config startup-config 保存配置cisco2960口令恢复交换机口令恢复的步骤 串口线连接到到交换机的console口。 先按住交换机面板上的mode键,然后打开电源。 初始化flash。 >flash_init 更名含有password的配置文件。 >rename flash:config.text flash:config.old 启动交换机。 >boot 进入特权模式。 >enable 此时开机是已忽略password。 #rename flash:config.old flash:config.text copy配置文件到当前系统中。 #copy flash:config.text system:running-config 修改口令。 #configure terminal #enable secret 保存配置。 #write

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > 生活休闲 > 在线阅读


备案号:宁ICP备20000045号-2

经营许可证:宁B2-20210002

宁公网安备 64010402000987号