Prefix list removal

Hi,

What is the correct way to remove a prefix list associated with a route-map or a BGP neighbor? I deleted the prefix list in question but it seems it is still associated with the route-map and neighbor in question. What is the correct procedure to follow to correctly and completely remove a prefix lis?

Thanks!

Can you post your config, and the command you used to remove the prefix list?

Hi,

Config before:

policy {
prefix-list FILTER-IN {
rule 10 {
action permit
le 32
prefix 172.16.0.0/12
}
}
route-map AS-PREPEND-OUT {
rule 10 {
action permit
set {
as-path-prepend 65000
}
}
}
}
protocols {
bgp 65000 {
neighbor 169.254.0.1 {
as-override
prefix-list {
import FILTER-IN
}
remote-as 7224
route-map {
export AS-PREPEND-OUT
}
soft-reconfiguration {
inbound
}
timers {
holdtime 30
keepalive 10
}
}
neighbor 169.254.0.5 {
as-override
remote-as 7224
soft-reconfiguration {
inbound
}
timers {
holdtime 30
keepalive 10
}
}
network 172.16.2.0/26 {
}
}
}

Below the command to remove the prefix list:

delete policy prefix-list FILTER-IN

Config after:

policy {
route-map AS-PREPEND-OUT {
rule 10 {
action permit
set {
as-path-prepend 65000
}
}
}
}
protocols {
bgp 65000 {
neighbor 169.254.0.1 {
as-override
prefix-list {
import FILTER-IN
}
remote-as 7224
route-map {
export AS-PREPEND-OUT
}
soft-reconfiguration {
inbound
}
timers {
holdtime 30
keepalive 10
}
}
neighbor 169.254.0.5 {
as-override
remote-as 7224
soft-reconfiguration {
inbound
}
timers {
holdtime 30
keepalive 10
}
}
network 172.16.2.0/26 {
}
}
}

Notice the prefix-list is still referenced within the BGP config.

I managed to clean this up by using the below:

delete protocols bgp 65000 neighbor 169.254.0.1 prefix-list import FILTER-IN

I was just under the impression that once a prefix-list was deleted, it would be removed everywhere in the config. Not a train-smash though.