CVSROOT:        /cvs
Module name:    src
Changes by:     [email protected] 2026/07/21 02:23:44

Modified files:
        usr.sbin/bgpd  : control.c session.c session.h session_bgp.c 

Log message:
Rework the IdleHoldTimer and how fast reconnects are implemented.

On first error bgpd should allow a fast reconnect - this is especially
helpful for passive sessions. The way this was implemented was error
prone with a special case in session_accept().

Adjust the FSM so that on the first IDLE transistion the session uses
a IdleHoldTime of 0 sec but then increased to INTERVAL_IDLE_HOLD_INITIAL.
At the same time the outgoing connection is delatyed via ConnectRetryTimer.
Doing this moves the session quickly into active state and allows new
connections in but delays the reconnect like before.

Additionally the STATE_ACTIVE / EVNT_START FSM case is adjusted to initiate
a connect immediatly. This allows a 'bgpctl nei X up' to work also for
sessions in ACTIVE state. Also passive sessions will initiate a connection
in this case, which is a new behaviour.

OK tb@

Reply via email to