I am trying to build resilient core networking by using BGP. I have two routers, R1 and R2, which are connected to the single ISP. ISP has two routers (let's call them R3 and R4). My have successfully configured BGP peering with R3 from R1 and R4 from R2. The ISP is announcing the default gateway via both links. However, I am having difficulties with BGP not reannouncing the default gateway over iBGP session between R1 and R2. My topology looks like this.
I am attaching config files (relevant information is replaced):
R1 config
hostname Router log file /var/log/quagga.log log stdout log timestamp precision 6 hostname bgpd bgp config-type cisco ! debug bgp as4 debug bgp events debug bgp keepalives debug bgp updates debug bgp fsm debug bgp filters debug bgp zebra ! password zebra enable password zebra ! interface bge0 ipv6 nd suppress-ra no link-detect ! interface bge1 ipv6 nd suppress-ra no link-detect ! interface igb0 ipv6 nd suppress-ra no link-detect ! interface igb1 ipv6 nd suppress-ra no link-detect ! interface igb2 ipv6 nd suppress-ra no link-detect ! interface igb3 ipv6 nd suppress-ra no link-detect ! interface lagg0 ipv6 nd suppress-ra no link-detect ! interface lo0 no link-detect ! interface lo1 no link-detect ! interface pfsync0 ipv6 nd suppress-ra no link-detect ! interface vlan3 ipv6 nd suppress-ra no link-detect ! interface vlan4 ipv6 nd suppress-ra no link-detect ! interface vlan5 ipv6 nd suppress-ra no link-detect ! interface vlan101 ipv6 nd suppress-ra no link-detect ! interface vlan106 ipv6 nd suppress-ra no link-detect ! interface vlan107 ipv6 nd suppress-ra no link-detect ! interface vlan109 ipv6 nd suppress-ra no link-detect ! router bgp 6001 no synchronization bgp router-id 1.1.2.253 bgp log-neighbor-changes network 1.1.1.0 network 1.1.2.0 neighbor 2.1.1.249 remote-as 6000 neighbor 2.1.1.249 soft-reconfiguration inbound neighbor 2.1.1.249 prefix-list 3 in neighbor 2.1.1.249 route-map R1-DC-MAP out neighbor 1.1.2.254 remote-as 6001 neighbor 1.1.2.254 next-hop-self neighbor 1.1.2.254 soft-reconfiguration inbound maximum-paths 2 no auto-summary ! ip route 1.1.1.0/24 Null0 ip route 1.1.2.0/24 Null0 ! ip prefix-list 1 seq 5 permit 1.1.1.0/24 ip prefix-list 2 seq 5 permit 1.1.2.0/24 ip prefix-list 3 seq 5 deny 1.1.1.0/23 ip prefix-list 3 seq 10 permit any ! route-map R1-DC-MAP permit 10 match ip address prefix-list 1 set as-path prepend 6001 6001 6001 ! route-map R1-DC-MAP permit 20 match ip address prefix-list 2 ! ip forwarding ! line vty ! end
R2 config:
hostname Router log timestamp precision 6 hostname bgpd log file /var/log/quagga.log log stdout bgp config-type cisco ! debug zebra events debug zebra packet debug zebra rib debug bgp as4 debug bgp events debug bgp updates ! password zebra enable password zebra ! interface bge0 ipv6 nd suppress-ra no link-detect ! interface bge1 ipv6 nd suppress-ra no link-detect ! interface igb0 ipv6 nd suppress-ra no link-detect ! interface igb1 ipv6 nd suppress-ra no link-detect ! interface igb2 ipv6 nd suppress-ra no link-detect ! interface igb3 ipv6 nd suppress-ra no link-detect ! interface lagg0 ipv6 nd suppress-ra no link-detect ! interface lo0 no link-detect ! interface lo1 ipv6 nd suppress-ra no link-detect ! interface pfsync0 ipv6 nd suppress-ra no link-detect ! interface vlan3 ipv6 nd suppress-ra no link-detect ! interface vlan4 ipv6 nd suppress-ra no link-detect ! interface vlan5 ipv6 nd suppress-ra no link-detect ! interface vlan101 ipv6 nd suppress-ra no link-detect ! interface vlan106 ipv6 nd suppress-ra no link-detect ! interface vlan107 ipv6 nd suppress-ra no link-detect ! interface vlan109 ipv6 nd suppress-ra no link-detect ! router bgp 6001 no synchronization bgp router-id 1.1.2.254 bgp log-neighbor-changes network 1.1.1.0 network 1.1.2.0 neighbor 3.1.1.25 remote-as 6000 neighbor 3.1.1.25 soft-reconfiguration inbound neighbor 3.1.1.25 prefix-list 3 in neighbor 3.1.1.25 route-map R2-SIX-MAP out neighbor 1.1.2.253 remote-as 6001 neighbor 1.1.2.253 next-hop-self neighbor 1.1.2.253 soft-reconfiguration inbound no auto-summary ! ip route 1.1.1.0/24 Null0 ip route 1.1.2.0/24 Null0 ! ip prefix-list 1 seq 5 permit 1.1.2.0/24 ip prefix-list 2 seq 5 permit 1.1.1.0/24 ip prefix-list 3 seq 5 deny 1.1.1.0/23 ip prefix-list 3 seq 10 permit any ! route-map R2-SIX-MAP permit 10 match ip address prefix-list 1 set as-path prepend 6001 6001 6001 ! route-map R2-SIX-MAP permit 20 match ip address prefix-list 2 ! ip forwarding ! line vty ! end
I am using Quagga with latest FreeBSD (10.2).