Command
Clear
Use
This command is used to clear various counters in IOS as well as to reset various routing protocol adjacencies.
Syntax
Router#clear <option>
Optional Switches
aaa | Clear AAA values |
access-list | Clear access list statistical information |
access-template | Access-template |
adjacency | Adjacent nodes |
alps | Clear Alps |
appletalk | Reset AppleTalk information |
arp-cache | Clear the entire ARP cache |
backhaul-session-manage | Backhaul Session Manager information |
bgp | Clear BGP connections |
bridge | Reset bridge forwarding cache |
bsc | Clear counters in command |
bstun | Clear counters displayed in show bstun |
call | Call |
cdp | Reset cdp information |
cef | CEF information related to linecard |
clns | CLNS |
cns | CNS agents |
counters | Clear counters on one or all interfaces |
crypto | Encryption subsystem |
decnet | Reset DECnet information |
dialer | Clear dialer statistics |
dlsw | Data Link Switching (DLSw) |
dot1x | Clear Dot1x information |
drip | Clear drip |
dspfarm | clear DSPFARM |
frame-relay | Clear Frame Relay information |
funi | FUNI information |
h323 | Clear H.323 protocol related information |
host | Delete host table entries |
interface | Clear the hardware logic on an interface |
ip | IP |
ipv6 | IPv6 |
ipx | Reset Novell/IPX information |
isis | Clear IS-IS data structures |
kerberos | Clear Kerberos Values |
lane | lane |
line | Reset a terminal line |
logging | Clear logging buffer |
mac-address-table | MAC forwarding table |
memory | Memory counters |
mgcp | clear Media Gateway Control Protocol |
mpls | Reset MPLS statistical information |
mpoa | MPOA clear commands |
mrcp | Clear MRCP statistics |
ncia | Native Client Interface Architecture (NCIA) |
netbios-cache | Clear the entire NetBIOS name cache |
oer | Optimized Exit Routing information |
pagp | Port channel information |
parser | Clear parser data |
ppp | Clear ppp statistics |
pppatm | PPP over ATM |
pppoe | PPP over Ethernet |
radius | Clears radius server information |
rbscp | RBSCP statistics/information |
rif-cache | Clear the entire RIF cache |
route-map | Clear Route Map statistical information |
rpms-proc | Clear RPMS Process Information |
rudpv1 | Clear Rudpv1 information |
sccpold | clear Skinny Client Control Protocol |
scp | Clear SCP commands |
sip-ua | Clear SIP User Agent Information |
snapshot | Clear Snapshot timers |
source-bridge | Clear counters displayed in “show source-bridge” |
sss | Subscriber Service Switch Information |
statistics | Statistics |
stun | Clear counters displayed in show stun |
subscription | Clear Subscriptions |
tag-switching | Reset tag switching information |
tarp | Reset tarp information |
tcp | Clear TGREP counters/session |
vlan | Clear vLAN statistical information |
voice | Clear Voice |
vpdn | Clear a VPDN entity |
vsp | Voice Streaming Processing information |
vtp | Clear VTP items |
webvpn | WebVPN information |
x25 | Clear X.25 circuits |
xot | Clear an XOT (X.25-Over-TCP) VC |
Example
Since there is so many different clear options, we have added a clear section with some of the more useful clear commands for a CCNA candidate.
R2#clear ip ospf process
Reset ALL OSPF processes? [no]: y
R2#
*Mar 1 04:52:42.914: %OSPF-5-ADJCHG: Process 1, Nbr 3.3.3.3 on FastEthernet1/0 from FULL to DOWN, Neighbor Down: Interface down or detached
*Mar 1 04:52:43.110: %OSPF-5-ADJCHG: Process 1, Nbr 3.3.3.3 on FastEthernet1/0 from LOADING to FULL, Loading Done
R2#