Prefix list filtering allows filtering of routes on a specific neighbour basis by using a prefix list.
To create a prefix list, use the command ip prefix-list then apply it to a neighbour using the neighbour x.x.x.x prefix-list y
followed by in
or out
. In will filter inbound, and out will filter outbound.
! Allow routes between 192.168.0.0 - 192.168.255.255 with a subnet mask of 255.255.255.0 ip prefix-list FILTER-IN seq 10 permit 192.168.0.0/16 ge 24 router bgp 65300 address-family ipv4 unicast ! Filter inbound routes according to prefix list neighbor 10.0.0.1 prefix-list FILTER-IN in
Leave a Reply