Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Community Member

Deleting ACL

Hi All,

How can I remove single ACL line from my ACL list?

6 REPLIES
Hall of Fame Super Bronze

Re: Deleting ACL

Let's take this ACL as an example:

R2#sh ip access-lists

Extended IP access list 101

10 permit ip host 1.1.1.1 host 2.2.2.2

20 permit ip host 1.1.1.1 host 3.3.3.3

30 permit ip host 1.1.1.1 host 4.4.4.4

You noticed how the output has a number from 10 to 30 on each ACE?

Now, let's say I want to knock out line number 20.

R2(config)#ip access-list extended 101

R2(config-ext-nacl)#no 20 permit ip host 1.1.1.1 host 3.3.3.3

R2(config-ext-nacl)#end

R2#sh ip access-lists

Extended IP access list 101

10 permit ip host 1.1.1.1 host 2.2.2.2

30 permit ip host 1.1.1.1 host 4.4.4.4

HTH,

__

Edison.

Please rate helpful posts

Community Member

Re: Deleting ACL

Edison,

That's pretty handy - I didn't know you could edit a numbered ACL as if it was a named ACL.

Re: Deleting ACL

When you edit an ACL, it requires special attention. For example, if you intend to delete a specific line from a numbered ACL that exists as shown here, the entire ACL is deleted

http://www.cisco.com/en/US/products/sw/secursw/ps1018/products_tech_note09186a00800a5b9a.shtml#editacls

Rate if helpful

Bronze

Re: Deleting ACL

Also, i believe you need at least version 12.3 of the IOS in order to delete numbered access-lists line by line

Silver

Re: Deleting ACL

just tested on 65k with 12.2 - all good. I suspect this method has been available for longtime, it's just been hidden (not to be confused with 'hidden' commands).

Ajaz

Community Member

Re: Deleting ACL

Hi Edison,

The problem fix by your instruction.

Thanks a lot.

300
Views
10
Helpful
6
Replies
CreatePlease to create content