Can someone please let me know if the prefix ip prefix-list emea seq 30 permit 10.9.1.0/24 ge 25
will include 10.9.1.0/24 network, or just 10.9.1.0./25, 10.9.1.0./26 etc if they existed?
Regards
Network Engineering Stack Exchange is a question and answer site for network engineers. It only takes a minute to sign up.
Sign up to join this communityYou can use two statements to allow /24 and greater
prefix-list emea seq 30 permit 10.9.1.0/24
prefix-list emea seq 31 permit 10.9.1.0/24 ge 25
The ge 25
suffix basically requires the prefix length to be 25 or higher (ge = greater than or equal).
In other words, the entry could be rephrased to: permit any network which is inside the network 10.9.1.0/24 and has a prefix length of 25 or higher. This would include 10.9.1.0/25, 10.9.1.0/26 as you have indicated (up to /32 as the le n
attribute is omitted) but not 10.9.1.0/24.
It would however also include things like 10.9.1.128/25 or 10.9.1.200/30, as all those networks are within the 10.9.1.0/24 network having a subnet mask greater than or equal to 25.
Another example would be prefix-list emea seq 30 permit 10.9.1.0/24 ge 25 le 25
.
This would exactly match the following two prefixes:
10.9.1.0/25 and 10.9.1.128/25
As the logic now is: permit any networks within the 10.9.1.0/24 range which prefix length is greater than or equal 25 and lower than or equal 25, in other words, exactly 25.
ge 25 le 25
the key is that the prefix length must be exactly /25 in order to be matched. Consider it that way: the prefix length has to be both greater than or equal to 25 and lower than or equal to 25 at the same time, which leaves us with an exact match of 25.