Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am trying to reset the hitcnt stats on all the access-list on all interfaces on my ASA5550.

I know about the clear <access-list> counters command.

But isn't there a way to clear the counters on ALL access-lists?

share|improve this question
add comment

2 Answers 2

up vote 1 down vote accepted
+100

You'll have to manually go through and clear every access list. If you want a short list of which ACLs are applied to interfaces do a show run access-group. Or reboot your ASA.

share|improve this answer
    
Thanks, that's pretty stupid from Cisco...obviously a reboot of the ASA is out of the question. –  Alex May 30 '12 at 22:47
add comment

You could use a tcl script to reset hitcnt on all access-list.

#tclsh

set al [ exec "show access-list\" ]
set my_al [regexp -all -nocase -line -inline {#TODO} $al]

foreach nb $my_al {
       exec "clear $nb counters"
}

Edit : Start a small example in tcl but I have no router on hand, so it is not complete.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.