Friday 11 January 2013

checking cisco devices for errors

Quick command to see if there are any errors on any interfaces
# sh interface | i error
0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort
0 output errors, 0 collisions, 0 interface resets
10 input errors, 0 CRC, 0 frame, 10 overrun, 0 ignored, 0 abort
0 output errors, 0 collisions, 0 interface resets
0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort
0 output errors, 0 collisions, 0 interface resets
142 input errors, 0 CRC, 0 frame, 142 overrun, 0 ignored, 0 abort
0 output errors, 0 collisions, 0 interface resets
0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort
0 output errors, 0 collisions, 0 interface resets
0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort
0 output errors, 0 collisions, 0 interface resets


We can see there are errors on two interfaces lets find the one with 10 errors.
# sh interface | b 10 input errors
10 input errors, 0 CRC, 0 frame, 10 overrun, 0 ignored, 0 abort
4116571872 packets output, 3222361986 bytes, 0 underruns
0 output errors, 0 collisions, 0 interface resets
0 babbles, 0 late collisions, 0 deferred
0 lost carrier, 0 no carrier
input queue (curr/max blocks): hardware (128/128) software (0/128)
output queue (curr/max blocks): hardware (0/128) software (0/29)
interface ethernet2 "dmz-mgmt" is up, line protocol is up


With this command we see the next interface is ethernet2, so the problem interface is ethernet1. Running the commands "sh interface" and "sh ip interface brief" can be useful for finding the interface you are looking for. Collisions usually suggest a speed/duplex mismatch. Common practice is to set auto for desktops but configure it for servers, network equipment etc.

This command will give you more detail on the interface
# sh interface ethernet1
interface ethernet1 "dmz-mon" is up, line protocol is up
  Hardware is i82559 ethernet, address is 0012.438a.f237
  IP address 172.19.131.1, subnet mask 255.255.255.0
  MTU 1500 bytes, BW 100000 Kbit full duplex
        291592760 packets input, 1207931955 bytes, 0 no buffer
        Received 475697 broadcasts, 0 runts, 0 giants
        10 input errors, 0 CRC, 0 frame, 10 overrun, 0 ignored, 0 abort
        4116575267 packets output, 3224176751 bytes, 0 underruns
        0 output errors, 0 collisions, 0 interface resets
        0 babbles, 0 late collisions, 0 deferred
        0 lost carrier, 0 no carrier
        input queue (curr/max blocks): hardware (128/128) software (0/128)
        output queue (curr/max blocks): hardware (0/128) software (0/29)


At this point we should investigate what is connected to the other end of the interface. You need to investigate the errors that appear in the syslog. Check that the speed and duplex are configured correctly on each end. It can help to start graphing the errors so you can pin point when the errors are happening. It can help you narrow it down. The clear counters command can be used to clear counters when errors have been resolved. If the errors are occuring in realtime you can clear counters and watch the rate at which the errors are increasing.

You should also check that the clock is in sync and that ntp is configured.

No comments:

Post a Comment