PG1X WIKI

My Knowledge Base

User Tools

Site Tools


tech:network:cisco:routing:prefix-list:prefix-list

Cisco: Route Filtering ip prefix-list

My Learning topics result may not be accurate because of my misunderstanding!!!!

I STRONGLY RECOMMENDED to read the Official Documents(cisco.com a.k.a. CCO) and RFCs, any other books, sites.

And learn foundation, create lab yourself, configure, and verify any topics.

TODO

  1. ip prefix-list lab 1
  2. ip prefix-list lab 2
  3. ip prefix-list lab 3
  4. ip prefix-list lab 4
  5. ip prefix-list lab 5
  6. ip prefix-list lab 6
  7. ip prefix-list lab 7
  8. ip prefix-list lab 8
  9. ip prefix-list lab 9
  10. ip prefix-list lab 10

Topology 42bc1e5c-e081-4f89-82d4-4ea181c272c6 ip prefix-list lab

Lab Specification

  1. Environment: CML-P 2.0
  2. IGP: EIGRP

Base Configuration

Common Configuration Snippet

R1

R2

R3

Configure ip prefix-list basics 28773325-623a-41d7-9b43-389b7f293208

  • R2
configure terminal
!
ip prefix-list PRE01 permit 172.16.0.0/24
ip prefix-list PRE01 permit 172.16.1.0/24
ip prefix-list PRE01 permit 172.16.2.0/26
ip prefix-list PRE01 permit 172.16.3.0/26
ip prefix-list PRE01 permit 172.16.4.0/28
!
ip prefix-list PRE02 permit 172.16.0.0/16 ge 27
!
ip prefix-list PRE03 permit 172.16.0.0/16 le 28
!
ip prefix-list PRE04 permit 172.16.0.0/22 le 32
!
ip prefix-list PRE05 permit 172.16.0.0/16 ge 25 le 27
!
ip prefix-list PRE06 permit 0.0.0.0/0
!
ip prefix-list PRE07 permit 0.0.0.0/0 ge 32
!
ip prefix-list PRE08 deny 172.16.2.0/23 ge 26
ip prefix-list PRE08 permit 0.0.0.0/0 le 32
!
access-list 9 permit 172.16.4.0 0.0.1.255
! is euqivalent
ip prefix-list PRE09 permit 172.16.4.0/23 le 32
!
! if you want to match only 172.16.0.0/24 route
! ACL is matches 172.16.0.0/24 but also matches 172.16.0.16/28, 172.16.0.32/28
access-list 10 permit 172.16.0.0 0.0.0.255
! ip prefix-list is match only 172.16.0.0/24
ip prefix-list PRE10 permit 172.16.0.0/24
!
router eigrp 1
 distribute-list prefix PRE01 out GigabitEthernet 0/0
 ! or
 distribute-list prefix PRE02 out GigabitEthernet 0/0
 ! or
 distribute-list prefix PRE03 out GigabitEthernet 0/0
 ! or
 distribute-list prefix PRE04 out GigabitEthernet 0/0
 ! or
 distribute-list prefix PRE05 out GigabitEthernet 0/0
 ! or
 distribute-list prefix PRE06 out GigabitEthernet 0/0
 ! or
 distribute-list prefix PRE07 out GigabitEthernet 0/0
 ! or
 distribute-list prefix PRE08 out GigabitEthernet 0/0
 ! or
 distribute-list 9 out GigabitEthernet 0/0
 distribute-list prefix PRE09 out GigabitEthernet 0/0
 ! or
 distribute-list 10 out GigabitEthernet 0/0
 distribute-list prefix PRE10 out GigabitEthernet 0/0
exit
!
end

Verification ip prefix-list basics 28773325-623a-41d7-9b43-389b7f293208

show ip route eigrp
show ip prefix-list detail
show access-lists
traceroute 172.16.12.2
traceroute 172.16.0.1

R1 Console Log

R2 Console Log

R2 Console Log

References

tech/network/cisco/routing/prefix-list/prefix-list.txt · Last modified: 2020/06/28 16:35 by wnoguchi