mirror_frr/bgpd
Pradosh Mohapatra 8da8689d91 bgpd: fix fast external fallover behavior
ISSUES

1. When an interface goes down, the zclient callbacks are invoked
   in the following order: (a) address_delete() that removes the
   connected address list: ifp->connected, (b) interface_down()
   that performs "fast external fallover" operation. The operation
   relies on ifp->connected to look for peers that should be brought
   down. That's a cyclic dependency.

2. 'ttl-security' configuration handler sets peer->ttl to
   MAXTTL (so that BGP packets are sent with TTL=255, as per the
   requirement of ttl-security). This, however, is incompatible
   with 'fast external fallover' as the fallover operation checks
   for (ttl == 1) to determine directly connected peers.

3. The current fallover operation does not work for IPv6 address family.

PATCH

1. The patch removes the dependency on 'ifp->connected' list for fast
   fallover. The peer already contains a nexthop structure that reflects
   the peering address. The nexthop structure has a pointer to the
   interface (ifp) that peering address resolves to. Everytime the TCP
   connection succeeds, the ifp is updated. The patch uses this ifp in
   the interface_down() callback for a match for the peers that should be
   brought down.

2. The evaluation for directly connected peering is enhanced as
   'peer->ttl == 1' OR 'peer->gtsm_hops == 1'. Thus a ttl-security
   configuration on the peer with one hop is directly connected and
   should be brought down under 'fast external fallover'.

3. Because of fix (1), IPv6 address family works automatically.

Signed-off-by: Pradosh Mohapatra <pmohapat@cumulusnetworks.com>
Reviewed-by: Dinesh G Dutt <ddutt@cumulusnetworks.com>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2014-05-19 23:25:39 +02:00
..
.gitignore [administrivia] Update gitignore files 2008-08-22 20:02:08 +01:00
BGP4-MIB.txt Initial revision 2002-12-13 20:15:29 +00:00
bgp_advertise.c bgpd: Try fix extcommunity resource allocation probs, particularly with 'set extcom..' 2011-03-21 13:51:14 +00:00
bgp_advertise.h 2005-06-28 Paul Jakma <paul.jakma@sun.com> 2005-06-28 12:44:16 +00:00
bgp_aspath.c hash: force size to be a power of 2 2013-02-24 20:42:40 +01:00
bgp_aspath.h bgpd: optimize aspath string representation and assegments handling 2012-05-22 20:25:02 +02:00
bgp_attr.c bgpd: track correct originator-id in reflected routes 2014-05-15 19:15:45 +02:00
bgp_attr.h bgpd: Move up flag-check calls, parcel up attr-parser args, and other cleanups 2012-02-28 18:35:45 +00:00
bgp_btoa.c Initial revision 2002-12-13 20:15:29 +00:00
bgp_clist.c bgpd: Try fix extcommunity resource allocation probs, particularly with 'set extcom..' 2011-03-21 13:51:14 +00:00
bgp_clist.h [bgpd] Stability fixes including bugs 397, 492 2009-07-19 18:28:08 +01:00
bgp_community.c bgpd: optimize loops on [e]community_hash_make() 2012-05-22 20:25:44 +02:00
bgp_community.h Revert "bgpd: "Intern" communities in route maps" 2011-04-01 15:58:27 +01:00
bgp_damp.c bgpd: Fix crash when disabling dampening (BZ#687) 2012-04-16 18:37:17 +02:00
bgp_damp.h Fix "show ip bgp dampened-paths" garbage output. 2009-06-23 14:25:20 +01:00
bgp_debug.c bgpd: improve logging of invalid BGP Notifications 2013-01-15 17:22:01 +01:00
bgp_debug.h [bgpd/cleanup] make message lists read only 2009-06-18 20:18:29 +01:00
bgp_dump.c Revert "bgpd: flock() dump files (BZ#742)" 2013-01-16 01:45:57 +01:00
bgp_dump.h [bgpd] Stability fixes including bugs 397, 492 2009-07-19 18:28:08 +01:00
bgp_ecommunity.c bgpd: optimize loops on [e]community_hash_make() 2012-05-22 20:25:44 +02:00
bgp_ecommunity.h Merge branch 'quagga' into google-bgp-multipath 2012-04-09 00:25:15 -07:00
bgp_filter.c [bgpd] Stability fixes including bugs 397, 492 2009-07-19 18:28:08 +01:00
bgp_filter.h bgp: compiler warning fix 2009-08-13 09:59:58 +01:00
bgp_fsm.c bgpd: stricter packet handling in OpenSent 2013-07-30 20:20:07 +02:00
bgp_fsm.h [bgpd] Bug #302 fixes. ClearingCompleted event gets flushed, leaving peers stuck in Clearing. 2006-10-15 23:39:59 +00:00
bgp_main.c lib/command.c: rewrite command matching/parsing 2014-04-01 20:21:41 +02:00
bgp_mpath.c bgpd: remove calls to peer_sort() from fast-path 2012-05-22 20:25:10 +02:00
bgp_mpath.h bgpd: When advertising a multipath route, the attribute set to be 2011-07-20 20:49:11 -07:00
bgp_mplsvpn.c bgpd: Fix memory leak of some "show ip bgp neighbor" commands 2012-05-02 17:03:27 +02:00
bgp_mplsvpn.h 2005-06-28 Paul Jakma <paul.jakma@sun.com> 2005-06-28 12:44:16 +00:00
bgp_network.c bgpd: increase TCP socket buffer size 2014-05-15 20:34:53 +02:00
bgp_network.h bgpd: increase TCP socket buffer size 2014-05-15 20:34:53 +02:00
bgp_nexthop.c bgpd, zebra: support NEXTHOP_IPV4_IFINDEX in bgp import check 2013-08-06 12:41:46 +02:00
bgp_nexthop.h bgpd: optimize bgp_nexthop_self() 2012-05-22 20:25:07 +02:00
bgp_open.c bgpd: relax ORF capability length handling 2013-02-01 17:55:04 +01:00
bgp_open.h bgpd, lib: adopt afi_t and safi_t in several places 2010-10-06 12:33:05 -04:00
bgp_packet.c bgpd: write NOTIFY non-blockingly 2013-07-31 14:44:24 +02:00
bgp_packet.h bgpd: code cleanup 2009-12-17 13:14:28 +03:00
bgp_regex.c [bgpd] Pass NOSUB to regexec 2007-08-23 23:22:02 +00:00
bgp_regex.h [configure] add configure support for PCRE Posix library 2009-06-19 15:01:16 +01:00
bgp_route.c bgpd: display multipath status in "show ip bgp" 2014-05-15 19:23:36 +02:00
bgp_route.h Merge branch 'quagga' into google-bgp-multipath 2012-04-09 00:25:15 -07:00
bgp_routemap.c bgpd: fix a memleak on "set community none" 2013-01-14 16:09:19 +01:00
bgp_snmp.c snmp: let handlers accept OID from a lesser prefix 2012-06-25 19:03:23 +02:00
bgp_snmp.h 2005-06-28 Paul Jakma <paul.jakma@sun.com> 2005-06-28 12:44:16 +00:00
bgp_table.c bgpd: make bgp_table a wrapper around table library 2012-09-26 21:50:48 +02:00
bgp_table.h lib/table: add route_table_get_next() and iterator 2012-09-26 21:50:48 +02:00
bgp_vty.c bgpd: add 'bgp bestpath as-path multipath-relax' 2014-05-15 19:15:22 +02:00
bgp_vty.h [bgpd] Merge AS4 support 2007-10-14 22:32:21 +00:00
bgp_zebra.c bgpd: fix fast external fallover behavior 2014-05-19 23:25:39 +02:00
bgp_zebra.h Merge branch 'quagga' into google-bgp-multipath 2012-04-09 00:25:15 -07:00
bgpd.c bgpd: send notify in OpenSent when stopping manually 2014-05-15 19:54:04 +02:00
bgpd.conf.sample Initial revision 2002-12-13 20:15:29 +00:00
bgpd.conf.sample2 Initial revision 2002-12-13 20:15:29 +00:00
bgpd.h bgpd: send notify in OpenSent when stopping manually 2014-05-15 19:54:04 +02:00
IMPLEMENTATION.txt Adjust size complexity estimates. Still not quite right, but closer. 2005-02-15 17:10:03 +00:00
Makefile.am build: use net-snmp-config to configure NetSNMP 2012-06-25 19:03:23 +02:00