[Xorp-hackers] BGP harness question related to 'runit'

Atanu Ghosh atanu at xorp.org
Fri Apr 23 17:18:20 PDT 2010


Hi,

>From memory, the runit program needs to know that the programs it has
started are ready to accept XRLs. The argument after the '=''s is a
program to run to determine that the program is ready. In the case of
xorp_fea_dummy the call_xrl program makes 10 attempts ("-r 10") to get
the target name. Without this the programs will be started without
delay and XRLs will be sent to the programs before they are ready to
accept them. The runit program does not require the router manager, in
a simpler universe it would have been nice to have been able to use
the router manage to start the programs.

In the xorp/tests directory I was starting to experiment with using
python only for testing. The runit program not only starts the
programs but more importantly notices if they fail.

       Atanu.

On Fri, Apr 23, 2010 at 4:07 PM, Ben Greear <greearb at candelatech.com> wrote:
> I notice that this or similar logic is found in most of the BGP test harness
> scripts:
>
> if [ $START_PROGRAMS = "yes" ]
> then
>     CXRL="$CALLXRL -r 10"
>     runit $QUIET $VERBOSE -c "$0 -s -c $*" <<EOF
>     ../../libxipc/xorp_finder
>     ../../fea/xorp_fea_dummy  = $CXRL finder://fea/common/0.1/get_target_name
>     ../../rib/xorp_rib        = $CXRL finder://rib/common/0.1/get_target_name
>     ../xorp_bgp               = $CXRL finder://bgp/common/0.1/get_target_name
>     ./test_peer -s peer1      = $CXRL finder://peer1/common/0.1/get_target_name
>     ./coord                   = $CXRL finder://coord/common/0.1/get_target_name
> EOF
>     trap '' 0
>     exit $?
> fi
>
>
> Even after tweaking for correct binary paths, the applications fail to properly
> start unless I delete everything after the first token.  For instance:
>
>
> if [ $START_PROGRAMS = "yes" ]
> then
>     CXRL="$CALLXRL -r 10"
>     runit $QUIET $VERBOSE -c "$0 -s -c $*" <<EOF
>     ../../libxipc/xorp_finder
>     ../../fea/xorp_fea_dummy
>     ../../rib/xorp_rib
>     ../xorp_bgp
>     ./test_peer -s peer1
>     ./coord
> EOF
>     trap '' 0
>     exit $?
> fi
>
>
> Anyone know what that CXRL logic was supposed to accomplish?  Maybe it only
> works with xorp_rtrmgr is running?
>
> Thanks,
> Ben
>
>
> --
> Ben Greear <greearb at candelatech.com>
> Candela Technologies Inc  http://www.candelatech.com
>
> _______________________________________________
> Xorp-hackers mailing list
> Xorp-hackers at icir.org
> http://mailman.ICSI.Berkeley.EDU/mailman/listinfo/xorp-hackers
>



More information about the Xorp-hackers mailing list