CVSROOT: /cvs Module name: src Changes by: clau...@cvs.openbsd.org 2020/12/23 06:20:48
Modified files: usr.sbin/bgpd : bgpd.h session.c session.h Log message: BGP uses KEEPALIVE packets and the HOLD timer to detect stalled sessions. The problem is that this timer only looks at the receive side of the TCP session. If for some reason the send side stalls the system fully depends on the remote BGP peer to reset the session. As seen in an ever growing OutQ and as a result important changes can get stalled and cause routing troubles. This change introduces a SEND HOLD timer. The timer is reset whenever the session engine was able to write data to the TCP socket. If the send hold timer expires bgpd was not able to send any data to that neighbor for at least 90 seconds and therefor the session is forcefully closed with a hold timer expired notification. The send hold timer acts as a last resort to detect faulty peers. On an idle session it can take a long time until this timer triggers but the main goal here is to reset a stuck session at some point which did not happen before. With and OK job@