思科交换机常用show命令

显示交换机MAC地址表(用于排错)
switch#show mac address-table

显示当前的存储模版(比如用来主要做三层交换还是二层交换 IPV4 还是 IPV6 数据表空间是共享的需要定制表结构)
switch#show sdm prefer
switch(config)#sdm prefer router

查看端口的状态信息
switch#show interface fa0/1

查看CDP信息(思科私有协议 CDP = CISCO discovery protocol 思科邻居发现协议)
switch#show cdp neighbors
switch#show cdp neighbors gig1/0/22 detail

查看LLDP信息(工业标准协议 推荐使用 适合重建拓扑使用)
switch#show lldp neighbors
switch#show lldp neighbors gig1/0/22 detail

查看POE端口信息
switch#show power inline
switch#show power inline gigabitethernet1/0/5
switch#show power inline gigabitethernet1/0/5 detail

查看处于errdisable状态的端口(还原一般采用先 shut 再 unshut或者等待超时,一般应该先排除造成该现象的原因再还原)
switch#show interface status err-disabled

查看VLAN
switch#show vlan
switch#show vlan id 1

查看端口的trunk 配置
switch#show interface gigabitethernet1/0/4 switchport
switch#show interface gigabitethernet1/0/4 trunk
switch#show dtp interface gigabitethernet1/0/4

查看交换机VTP(思科私有协议 关于VTP的注意点 下次再继续讲)
switch#show vtp status

查看交换机端口STP状态
switch#show spanning tree
switch#show spanning-tree detail
switch#show spanning-tree summary
switch#show spanning-tree vlan 100 summary
switch#show spanning-tree vlan 100 root
switch#show spanning-tree vlan 100 bridge
switch#show spanning-tree uplinkfast
switch#show spanning-tree backbonefast
switch#show spanning-tree interface fa0/1

列出被标记为不一致状态的端口
switch#show spanning-tree inconsistentports

查看端口的STP状态
switch#show spanning-tree interface fa0/1 detail

UDLD问题 由于光纤造成的单向传输检测
switch#show udld
switch#resst udld -重置由于UDLD原因造成的err-disabled状态端口

关于以太网通道的命令
switch#show etherchannel summary
switch#show etherchannel port
switch#show etherchannel port-channel
switch#show etherchannel detail
switch#show etherchannel load-balance
switch#show lacp neighbor
switch#show lacp sys-id

关于思科CEF快速交换的查看命令 该特性默认开启 (思科快速交换技术)
switch#show ip cef vlan 101
switch#show ip cef 10.1.0.0 255.255.0.0 long prefixes
switch#show ip cef 10.1.3.0 255.255.255.192 detail

查看已知邻接的的统计信息
switch#show adjacency summary
switch#show adjacency vlan 99 detail

查看处于CEF glean 状态的邻接(IP地址没有对应的MAC回应叫做 CEF glean状态)
switch#show ip cef adjacency glean
switch#show ip interface vlan 101
switch#show ip interface brief
switch#show ip cef

查看当前的DHCP绑定
switch#show ip dhcp binding
switch#clear ip dhcp binding 清除DHCP 绑定信息
switch#show dhcp ipv6 dhcp binding
switch#show dhcp ipv6 dhcp pool

查看NTP状态(network time protocol 网络时间协议 用来给日志打时间戳和给内网交换机和服务器包括PC 提示时钟,一般制定多个内网时间源IP)
switch#show ntp status
switch#show ntp association
switch#show clock detail

查看当前IP SLA状态(用来做链路状态自动检测用的一个自动化脚本)
switch#show ip sla coonfiguration
switch#show ip sla statictics 100

查看当前活动的SPAN会话
switch#show monitor

查看supervisor引擎模块的冗余模式和状态
switch#show redundancy status

查看SWITCH B的HSRP路由器角色
switch#show standby brief
switch#show standby interface fa0/1
switch#show standby vlan 50 brief
switch#show standby vlan 50

查看负载均衡交换机的VRRP状态
switch#show vrrp brief
switch#show vrrp interface fa0/1

查看交换机的GLBP状态
switch#show glbp
switch#show glbp brief

查看端口的安全状态
switch#show port-security interface gig1/0/1
switch#show port-security

查看广播风暴抑制
switch#show storm-control broadcast/multicast/unicast

查看交换机DNCP SNOOPING状态
switch#show ip dhcp snooping

验证交换机IP源防护状态(通过结合DHCP snooping 形成表项根据ARF做的一个端口和MAC IP 的合法性检测)
switch#show ip verify source

验证交换机IP源绑定数据库信息
switch#show ip source binding

查看DAI状态信息(通过结合DHCP SNOOPING 的状态化表项做ARP动态检测的技术)
switch#show ip arp inspection

查看交换机目前的运行配置文件
switch#show run

其余常用的命令 可以通过模拟器给出 关键是掌握理论 才能各种show 不然show 了没用
在这里插入图片描述
在这里插入图片描述
show的层次性 交换机 基于linux开发 show 命令通过后面+空格 ? 显示每个层次下的所有可能选项 或者通过TAB补全命令,如下是一个三层结构的show 命令用来查看vpn SA 状态
在这里插入图片描述
在这里插入图片描述

  • 15
    点赞
  • 15
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值