clear interface

This topic explains the command that clears the statistical counters of an interface.

Syntax

clear interfaces {id} counters

Parameter

id: Specify the interface. The id parameter represents the interface number.

Default

No default value.

Mode

Privileged EXEC

Usage

Use this command to clear statistical counters for a specific interface.

Example

This example shows how to clear the counters on port 1/0/1:
CODE
Switch# clear interfaces 1/0/1 counters
This example shows how to show current counters after clear:
CODE
Switch# show interfaces 1/0/1
1/0/1 is up
 Hardware is Gigabit Ethernet
 Auto-duplex, Auto-speed, media type is Copper
 flow-control is off
 back-pressure is enabled
    0 packets input, 0 bytes, 0 throttles
    Received 0 broadcasts (0 multicasts)
    0 runts, 0 giants, 0 throttles
    0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored
    0 multicast, 0 pause input
    0 input packets with dribble condition detected
    0 packets output, 0 bytes, 0 underrun
    0 output errors, 0 collisions, 0 interface resets
    0 babbles, 0 late collision, 0 deferred
    0 PAUSE output