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

Welcome to Cisco Support Community. We would love to have your feedback.

For an introduction to the new site, click here. And see here for current known issues.

New Member

Prefix-List

Hi, I have to open 112.0.0.0/8, 113.0.0.0/8,114.0.0.0/8,115.0.0.0/8,116.0.0.0/8,117.0.0.0/8,118.0.0.0/8 & 119.0.0.0/8 in Prefix list, but in one line. Please help how can I use le & ge funda for that. I need to use only one line.

5 REPLIES
Cisco Employee

Re: Prefix-List

Rupesh,

These 8 prefixes all fit inside 112/5 as the first 5 bits are identical.

The following line should therefore do the job.

ip prefix-list test seq 5 permit 112.0.0.0/5 ge 8 le 8

Regards

Harold Ritter
Sr. Technical Leader
CCIE 4168 (R&S, SP)
harold@cisco.com
México móvil: +52 1 55 8312 4915
Cisco México 
Paseo de la Reforma 222 Piso 19
Cuauhtémoc, Juárez
Ciudad de México, 06600
México
New Member

Re: Prefix-List

what about if all subnet mask will 24 ?

Should prefix list like-

ip prefix-list test seq 5 permit 112.0.0.0/5 ge 24 le 24 ?

Re: Prefix-List

If they're not ever going to be longer than 24, you should be able to do:

ip prefix-list test permit 112.0.0.0/5 le 24

HTH,

John

HTH, John *** Please rate all useful posts ***
Cisco Employee

Re: Prefix-List

Rupesh,

That is correct. Only the /24 subnets will match.

Regards

Harold Ritter
Sr. Technical Leader
CCIE 4168 (R&S, SP)
harold@cisco.com
México móvil: +52 1 55 8312 4915
Cisco México 
Paseo de la Reforma 222 Piso 19
Cuauhtémoc, Juárez
Ciudad de México, 06600
México

Re: Prefix-List

Harold,

I'm just getting into the prefix-lists. Would you be able to just use the le 24 to match up to 24 bits? You wouldn't need the ge 24, right? Or am I wrong on this?

Thanks,

John

HTH, John *** Please rate all useful posts ***
132
Views
0
Helpful
5
Replies