ciscoerrdisable.docx

上传人:b****6 文档编号:6726156 上传时间:2023-01-09 格式:DOCX 页数:11 大小:48.22KB
下载 相关 举报
ciscoerrdisable.docx_第1页
第1页 / 共11页
ciscoerrdisable.docx_第2页
第2页 / 共11页
ciscoerrdisable.docx_第3页
第3页 / 共11页
ciscoerrdisable.docx_第4页
第4页 / 共11页
ciscoerrdisable.docx_第5页
第5页 / 共11页
点击查看更多>>
下载资源
资源描述

ciscoerrdisable.docx

《ciscoerrdisable.docx》由会员分享,可在线阅读,更多相关《ciscoerrdisable.docx(11页珍藏版)》请在冰豆网上搜索。

ciscoerrdisable.docx

ciscoerrdisable

cisco-errdisable

关于ciscoerrdisable

showinterstatus

showinterstatuserr

showerrdisablerecovery

errdisablerecoverycause?

(config)#noerrdisabledetectcauseall

errdisablerecoveryinterval300

(config-if)#nokeep

交换机端口假死(err-disable)解决方法

--------------------------------------------------------------------------------

出现了这个问题,我们不得不重视起交换机端口“假死”的现象,寻求在交换机不重启的状态下将该端口“拯救”回来

的方法。

拯救步骤1:

查看日志/端口的状态

  

  登录进入交换机后,执行showlog,会看到如下的提示:

  21w6d:

%ETHCNTR-3-LOOP_BACK_DETECTED:

Keepalivepacketloop-backdetectedonFastEthernet0/20.

  21w6d:

%PM-4-ERR_DISABLE:

loopbackerrordetectedonFa0/20,puttingFa0/20inerr-disablestate

  以上信息就明确表示由于检测到第20端口出现了环路,所以将该端口置于了err-disable状态。

  

查看端口的状态

  

  Switch#showinterfa0/20status

  PortNameStatusVlanDuplexSpeed

state

  dhcp-rate-limitEnabletimertorecoverfromdhcp-rate-limiterrordisablestate

  dtp-flapEnabletimertorecoverfromdtp-flaperrordisablestate

  gbic-invalidEnabletimertorecoverfrominvalidGBICerrordisablestate

  l2ptguardEnabletimertorecoverfroml2protocol-tunnelerrordisablestate

  link-flapEnabletimertorecoverfromlink-flaperrordisablestate

  loopbackEnabletimertorecoverfromloopbackdetecteddisablestate

  pagp-flapEnabletimertorecoverfrompagp-flaperrordisablestate

  psecure-violationEnabletimertorecoverfrompsecureviolationdisablestate

  security-violationEnabletimertorecoverfrom802.1xviolationdisablestate

  udldEnabletimertorecoverfromudlderrordisablestate

  unicast-floodEnabletimertorecoverfromunicastflooddisablestate

  vmpsEnabletimertorecoverfromvmpsshutdownerrordisablestate

  

  从列出的选项中,我们可以看出,有非常多的原因会引起端口被置于错误状态,由于我们明确的知道这台交换机上的端口是由于环路问题而被置于错误状态的,所以就可以直接键入命令:

  

  Switch(config)#errdisablerecoverycauseloopback

  是啊,就这么简单的一条命令,就把困挠我们很长时间的问题解决了,真的就这么神奇。

那么如何验证这条命令是

生效了呢?

拯救步骤3:

显示被置于错误状态端口的恢复情况

  

  Switch#showerrdisablerecovery

  ErrDisableReasonTimerStatus

  -------------------------------

  udldDisabled

  bpduguardDisabled

  security-violatioDisabled

  channel-misconfigDisabled

  vmpsDisabled

  pagp-flapDisabled

  dtp-flapDisabled

  link-flapDisabled

  gbic-invalidDisabled

  l2ptguardDisabled

  psecure-violationDisabled

  gbic-invalidDisabled

  dhcp-rate-limitDisabled

  unicast-floodDisabled

  loopbackEnabled

  Timerinterval:

300seconds

  Interfacesthatwillbeenabledatthenexttimeout:

  InterfaceErrdisablereasonTimeleft(sec)

  ----------------------------------------

  Fa0/8loopback276

  Fa0/17loopback267

  Fa0/20loopback250

  

  从以上显示的信息可以看出,这台交换机有三个端口(Fa0/8、Fa0/17、Fa0/20)会分别在276、267、250秒之后恢复为正常的状态,实际情况也是这样,等了几分钟以后,我们找了一台笔记本电脑,分别接到这几个端口上试了一下,端口都可以正常工作了。

这下总算在不重交换机的情况下,将几个处于“假死”状态的端口“拯救”了回来。

关于接口处于err-disable的故障排查

故障症状:

线路不通,物理指示灯灭或者显示为橙色(不同平台指示灯状态不同)

showinterface输出显示接口状态:

FastEthernet0/47isdown,lineprotocolisdown(err-disabled)

接口状态是err-disable。

sw1#showinterfacesstatus

PortNameStatusVlanDuplexSpeedType

Fa0/47err-disabled1autoauto10/100BaseTX

如果出现了接口状态为err-disable,showinterfacesstatuserr-disabled命令能查看触发err-disable的原因。

下面示例原因为bpduguard,在连接了交换机的端口配置了spanning-treebpduguardenable。

sw1#showinterfacesstatuserr-disabled

PortNameStatusReason

Fa0/47err-disabledbpduguard

接口产生err-disable的原因可以由以下的命令来查看,系统缺省的配置是所有列出的原因都能导致接口被置为err-disable。

sw1#showerrdisabledetect

ErrDisableReasonDetectionstatus

---------------------------------

udldEnabled

bpduguardEnabled

security-violatioEnabled

channel-misconfigEnabled

psecure-violationEnabled

dhcp-rate-limitEnabled

unicast-floodEnabled

vmpsEnabled

pagp-flapEnabled

dtp-flapEnabled

link-flapEnabled

l2ptguardEnabled

gbic-invalidEnabled

loopbackEnabled

dhcp-rate-limitEnabled

unicast-floodEnabled

从列表中,我们可以看出常见的原因有udld,bpduguard,link-flap以及loopback等。

具体由什么原因导致当前接口err-disable可以由showinterfacestatuserr-disable来查看。

在接口模式下采用shutdown,noshutdown进行手动的激活。

在缺省配置下,一旦接口被置为err-disable,IOS将不会试图恢复接口。

这个可以由showerrdisablerecovery来查看,timerstatus下面所有的值都是disable。

下面的示例中,由于手工配置了bpduguard恢复,所以timerstatus的值变为Enable。

sw1#showerrdisablerecovery

ErrDisableReasonTimerStatus

-------------------------------

udldDisabled

bpduguardEnabled

security-violatioDisabled

channel-misconfigDisabled

vmpsDisabled

pagp-flapDisabled

dtp-flapDisabled

link-flapDisabled

l2ptguardDisabled

psecure-violationDisabled

gbic-invalidDisabled

dhcp-rate-limitDisabled

unicast-floodDisabled

loopbackDisabled

Timerinterval:

300seconds

Interfacesthatwillbeenabledatthenexttimeout:

InterfaceErrdisablereasonTimeleft(sec)

----------------------------------------

Fa0/47bpduguard217

配置IOS重新激活errdisable的接口,使用以下命令:

sw1(config)#errdisablerecoverycausebpduguard

sw1(config)#errdisablerecoverycause?

allEnabletimertorecoverfromallcauses

bpduguardEnabletimertorecoverfromBPDUGuarderrordisablestate

channel-misconfigEnabletimertorecoverfromchannelmisconfigdisablestate

dhcp-rate-limitEnabletimertorecoverfromdhcp-rate-limiterrordisablestate

dtp-flapEnabletimertorecoverfromdtp-flaperrordisablestate

gbic-invalidEnabletimertorecoverfrominvalidGBICerrordisablestate

l2ptguardEnabletimertorecoverfroml2protocol-tunnelerrordisablestate

link-flapEnabletimertorecoverfromlink-flaperrordisablestate

loopbackEnabletimertorecoverfromloopbackdetecteddisablestate

pagp-flapEnabletimertorecoverfrompagp-flaperrordisablestate

psecure-violationEnabletimertorecoverfrompsecureviolationdisablestate

security-violationEnabletimertorecoverfrom802.1xviolationdisablestate

udldEnabletimertorecoverfromudlderrordisablestate

unicast-floodEnabletimertorecoverfromunicastflooddisablestate

vmpsEnabletimertorecoverfromvmpsshutdownerrordisable

配置完上述命令后,IOS在一段时间后试图恢复被置为err-disable的接口,这段时间缺省为300秒。

但是,如果引起err-disable的源没有根治,在恢复工作后,接口会再次被置为err-disable。

调整err-disable的超时时间,可以使用以下命令:

sw1(config)#errdisablerecoveryinterval?

<30-86400>timer-interval(sec)

可以调整在30-86400秒,缺省是300秒。

如果产生err-disable的原因是udld,下面有一条命令非常管用:

sw1#udldreset

NoportsaredisabledbyUDLD.

同时,接口在被置为err-disable的时候,通常有一系列的日志产生,如下:

*Mar1515:

47:

19.984:

%SPANTREE-2-BLOCK_BPDUGUARD:

ReceivedBPDUonportFastEthernet0/47withBPDU

Guardenabled.Disablingport.

sw1#

*Mar1515:

47:

19.984:

%PM-4-ERR_DISABLE:

bpduguarderrordetectedonFa0/47,puttingFa0/47inerr-

disablestate

sw1#

*Mar1515:

47:

21.996:

%LINK-3-UPDOWN:

InterfaceFastEthernet0/47,changedstatetodown

收集这些日志也非常管用。

所以建议配置一个syslogserver,收集log信息。

sw1#showinterfacesstatusPortNameStatusVlanDu...开启errdisable功能,这样可以使用showerrdisable来查看引发errdisable的原因是什么,再更加信息内容进行解决。

你要是想不影响使用的话,先用noerrdisabledetectcauseloopback执行一下,将已经死掉的端口,nosh一下

如果没问题,肯定是环路了,你可再找时间,对怀疑有问题的switch用拔插法,一个一个拔掉网线去查,当然,有更有效的方法,你可查看有问题的switch的所有rj45和gi口的状态,哪个有errdisable信息哪个就有问题。

switch#showinterfacesstatuserr-disabled

PortNameStatusReason

Fa0/22err-disabledlink-flap

Fa0/37Forofficein100Kerr-disabledlink-flap

Fa0/41unknowerr-disabledlink-flap

Fa0/42TrainingDc066err-disabledlink-flap

Fa0/45ProductionlineVMerr-disabledlink-flap

switch#showerrdisabledetect

ErrDisableReasonDetectionstatus

---------------------------------

pagp-flapEnableddtp-flapEnabledlink-flapEnabledl2ptguardEnabledgbic-invalidEnabledloopback

Enabled

switch#showinterfacesstatuserr-disabled

PortNameStatusReason

Fa0/22err-disabledlink-flap

Fa0/37Forofficein100Kerr-disabledlink-flap

Fa0/41unknowerr-disabledlink-flap

Fa0/42TrainingDc066err-disabledlink-flap

Fa0/45ProductionlineVMerr-disabledlink-flap

switch#sherrdisableflap-values

ErrDisableReasonFlapsTime(sec)---------------------------------

pagp-flap330dtp-flap330link-flap510(link-flap这就是因为链路质量不好导致的)关闭errdisable

detectswitch#noerrdisabledetectcauseall

导致交换机接口出现err-disable的几个常见原因:

1.EtherChannelmisconfiguration

2.Duplexmismatch

style="TEXT-INDENT:

2em">3.BPDUportguard

4.UDLD

5.Link-flaperror

6.Loopbackerror

7.Portsecurityviolation

第一个当FEC两端配置不匹配的时候就会出现err-disable.假设SwitchA把FEC模式配置为on,这时SwitchA是不会发送PAgP包和相连的SwitchB去协商FEC的,它假设SwitchB已经配置好FEC了。

但实事上SwtichB并没有配置FEC,当SwitchB的这个状态超过1分钟后,SwitchA的STP就认为有环路出现,因此也就出现了err-disable.解决办法就是把FEC的模式配置为channel-group1modedesirablenon-silent这个意思是只有当双方的FEC协商成功后才建立channel,否则接口还处于正常状态。

第二个原因就是双工不匹配。

一端配置为half-duplex后,他会检测对端是否在传输数据,只有对端停止传输数据,他才会发送类似于ack的包来让链路up,但对端却配置成了full-duplex,他才不管链路是否是空闲的,他只会不停的发送让链路up的请求,这样下去,链路状态就变成err-disable了。

三、第三个原因BPDU,也就是和portfast和BPDUguard有关。

如果一个接口配置了portfast,那也就是说这个接口应该和一个pc连接,pc是不会发送spanning-tree的BPDU帧的,因此这个口也接收BPDU来生成spanning-tree,管理员也是出于好心在同一接口上配置了BPDUguard来防止未知的BPDU帧以增强安全性,但他恰恰不小心把一个交换机接到这个同时配置了portfast和BPDUguard接口上,于是这个接口接到了BPDU帧,因为配置了BPDUguard,这个接口自然要进入到err-disable状态。

解决办法:

nospanning-treeportfastbpduguarddefault,或者直接把portfast关了。

第四个原因是UDLD.UDLD是cisco的私有2层协议,用于检测链路的单向问题。

有的时候物理层是up的,但链路层就是down,这时候就需要UDLD去检测链路是否是真的up的。

当AB两端都配置好UDLD后,A给B发送一个包含自己portid的UDLD帧,B收到后会返回一个UDLD帧,并在其中包含了收到的A的portid,当A接收到这个帧并发现自己的portid也在其中后,认为这链路是好的。

反之就变成err-disable状态了。

假设A配置了UDLD,而B没有配置UDLD:

A给B发送一个包含自己portid的帧,B收到后并不知道这个帧是什么,也就不会返回一个包含A的portid的UDLD帧,那么这时候A就认

为这条链路是一个单向链路,自然也就变成err-disable状态了。

第五个原因就是链路的抖动,当链路在10秒内反复up、down五次,那么就进入err-disable状态。

第六个原因就是keepaliveloopback.在12.1EA之前,默认情况下交换机会在所有接口都发送keepalive信息,由

于一些不通交换机协商spanning-tree可能会有问题,一个接口又收到了自己发出的keepalive,那么这个接口就会变

成err-disable了。

解决办法就是把keepalive关了。

或者把ios升到12.2SE.

最后一个原因,相对简单,就是由于配

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

当前位置:首页 > 总结汇报

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1