[Xorp-users] using XORP (bgp) to test third party router

jer log jer_log@hotmail.com
Wed, 11 May 2005 03:12:31 +0000


Thank you so much for that response. Multiple hosts is not really a option 
for me.

I have since tried adding a  '-b'  and '-p' option to specify a local bind 
address/port (to
enforce the source address/port during connect) options to test_peer.cc 
under bgp/harness

The idea is to run each peer with
   testpeer -b <addr1> -p <port>

The 'Third Party' router has an option to specify the destination TCP port 
to connect to
(does not have to be 179, thankfully)

But when i make this change, i get "
"Operation in coordinator still pending try number: 1... and fail"

BTW, i really think the test script can become a great third party BGP test 
tool.
with all the extensible functionality to send arbitrary update and expect 
statements.
(reminds me of Qarobot from Qosnetics)

Thanks for your help.
-jer




>From: Atanu Ghosh <atanu@ICSI.Berkeley.EDU>
>Reply-To: atanu@ICSI.Berkeley.EDU
>To: "jer log" <jer_log@hotmail.com>
>CC: xorp-users@xorp.org
>Subject: Re: [Xorp-users] using XORP (bgp) to test third party router Date: 
>Tue, 10 May 2005 19:09:46 -0700
>
>The bgp test harness was written with the intent of being able to test
>third party BGP implementations:
><http://www.xorp.org/releases/1.1/docs/test_harness/test_harness.pdf>.
>
>We have never tried using the tests against a third party BGP. So
>some dependencies on our BGP may have crept in.
>
>I would experiment with the set of scripts that we use daily in our
>regression runs, they are in Makefile.am:
>
>test_peering1.sh
>test_peering2.sh
>test_routing1.sh
>test_routing2.sh
>test_rib1.sh
>test_rib_fea1.sh
>test_path_attribute1.sh
>test_terminate.sh
>
>A typical BGP will create a single session with a peer. More than one
>session to a peer is clearly a protocol violation. We wanted to be able
>to run our BGP regression tests from a Makefile so we modified our BGP
>to accept connections on any port not just 179. For testing third party
>implementations we need to run each test_peer on a separate host (or
>address).
>
>The test harness has two components a coordinating process and a number
>of test_peers. The test_peers are designed to run on separate hosts
>although we run them on the same host.
>
>Taking test_routing1.sh as an example the top of the file describes
>which process need to be started, clearly when testing a third party BGP
>there is no need to start the XORP processes. We need to start a finder
>process a coordinating process and and three test_peers. All the port
>numbers in script need to be changed to port 179 (PORT? and
>PEER?_PORT). Choose three separate hosts on which to run the test
>peers. Configure you BGP to accept connections from this these
>hosts. Set the HOST variable to the IP address of your BGP router.
>
>The finder process for security reasons will only accept connections on
>localhost. It will need to be started with the "-n" with the network
>that the test_peers are on and "-i" with the interface address that it
>should listen on. Then start a test peer on each host with the "-h"
>flag, with the IP address of the finder host. Each test peer will also
>require a unique name provided with the "-s" flag, (peer1, peer2 and
>peer3).
>
>For simplicity run the test_routing1.sh script on the same host that you
>run the coordinator and finder process.
>
>Now run a test:
>$ ./test_routing1.sh -s -t test1
>
>The configure_bgp does indeed configure the XORP bgp.
>
>There is no way to set the test peer's IP address interesting omission
>on my part. The test_peer is provided with the targets IP address and
>port. In our tests the target is always localhost so the source address
>selected by the system is always localhost. When running the test_peers
>on separate hosts again the source IP address will be selected by the
>operating system.
>
>I have noticed a number of problems in the test scripts while trying to
>compose this email. The most irritating is that I have overloaded the
>configuration on some peerings. For example in test_routing1.sh I use
>the same peerings for IPv4 and IPv6 tests. Your won't be able to run the
>IPv4 and IPv6 tests with the same router configuration. This also means
>that you can't allow the script to run all the tests, each one will need
>to be run individually.
>
>I hope this helps.
>
>In retrospect using the the shell as the scripting language was a
>mistake. We will be rewriting the tests in python during the summer and
>hopefully make the scripts more amenable to testing third party BGP
>implementations. Checkout harness.py and lookup.py.
>
>Sorry for the slow response we had a power failure in our machine room
>today and lost both power supplies on our mail server.
>
>   Atanu.
>
>
> >>>>> "jer" == jer log <jer_log@hotmail.com> writes:
>
>     jer> Folks, I have since got some peering (bgp test harness) with a
>     jer> third party router going...  But i have problems in specifying
>     jer> multiple peers.  Specifically the router requires these peers
>     jer> to come from multiple ip addresses.
>
>     jer>    How do i specify a test peer's ip address?  I am assuming
>     jer> configure_bgp() {} routine configures the peers in XORP.
>
>     jer> Thanks, -Jer
>
>     jer>   So how do i specify the peer programs to From: "jer log"
>     jer> <jer_log@hotmail.com>
>     >> To: xorp-users@xorp.org Subject: [Xorp-users] using XORP (bgp) to
>     >> test third party router Date: Tue, 10 May 2005 16:27:22 +0000
>     >>
>     >> Hi, I am (a newbie) trying to use the bgp harness test suite of
>     >> XORP to test a third party router.  Has this been done?  What are
>     >> the processes i need to run to achieve this?  I have been able to
>     >> compile xorp in a redhat linux.
>     >>
>     >> If i just modify bgp/harness/test1.sh it just stops at coord
>     >> reset.  I guess i must start the coordinator process...
>     >>
>     >> Thanks for your help -Jer
>     >>
>     >> _________________________________________________________________
>     >> Express yourself instantly with MSN Messenger! Download today -
>     >> it's FREE!
>     >> http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/
>     >>
>     >> _______________________________________________ Xorp-users
>     >> mailing list Xorp-users@xorp.org
>     >> http://mailman.ICSI.Berkeley.EDU/mailman/listinfo/xorp-users
>
>     jer> _________________________________________________________________
>     jer> Express yourself instantly with MSN Messenger! Download today -
>     jer> it's FREE!
>     jer> http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/
>
>     jer> _______________________________________________ Xorp-users
>     jer> mailing list Xorp-users@xorp.org
>     jer> http://mailman.ICSI.Berkeley.EDU/mailman/listinfo/xorp-users
>_______________________________________________
>Xorp-users mailing list
>Xorp-users@xorp.org
>http://mailman.ICSI.Berkeley.EDU/mailman/listinfo/xorp-users

_________________________________________________________________
Don’t just search. Find. Check out the new MSN Search! 
http://search.msn.click-url.com/go/onm00200636ave/direct/01/