C.15. Administrator-Forced Transitions

 /********************************************************* NAME : signal_end *********************************************************/ static void signal_end( int nosig ) { vrrp_rt *vsrv = &glob_vsrv; /* remove the pid file */ pidfile_rm( vsrv ); /* if the deamon is master, leave this state */ if( vsrv->state == VRRP_STATE_MAST ){ state_leave_master( vsrv, 1 ); } exit( 0 ); } /********************************************************* NAME : signal_user *********************************************************/ static void signal_user( int nosig ) { vrrp_rt *vsrv = &glob_vsrv; if( nosig == SIGUSR1 ){ vsrv->wantstate = VRRP_STATE_MAST; } if( nosig == SIGUSR2 ){ vsrv->wantstate = VRRP_STATE_BACK; } /* rearm ...

Get VRRP: Increasing Reliability and Failover with the Virtual Router Redundance Protocol now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.