1d3373029SBjoern A. Zeeb 2d3373029SBjoern A. ZeebThis directory holds scripts and a support program for multiple test cases 3d3373029SBjoern A. Zeebexercising multi-IP FIBs. At this time only IPv6 test cases are provided. 4d3373029SBjoern A. Zeeb 5d3373029SBjoern A. ZeebMakefile 6d3373029SBjoern A. Zeebreflect.c 7d3373029SBjoern A. Zeeb 8d3373029SBjoern A. Zeeb Makefile just builds reflect, a program to echo data on a TCP or UDP 9d3373029SBjoern A. Zeeb socket in very simplistic ways. It has a couple of options to provide 10d3373029SBjoern A. Zeeb an address or port, a FIB to bind to or a FIB to add to a reflected 11d3373029SBjoern A. Zeeb message as well as some "magic" keyword handling to let the intiators 12d3373029SBjoern A. Zeeb control it. 13d3373029SBjoern A. Zeeb 14d3373029SBjoern A. Zeebinitiator.sh and reflector.sh 15d3373029SBjoern A. Zeeb 16d3373029SBjoern A. Zeeb intiator.sh runs two local test cases, one which shows a documented 17d3373029SBjoern A. Zeeb limitation. 18d3373029SBjoern A. Zeeb 19d3373029SBjoern A. Zeeb All further tests are either exercising the sending or receiving of 20d3373029SBjoern A. Zeeb ICMP6, TCP or UDP packets with multiple FIBs. initiator.sh and 21d3373029SBjoern A. Zeeb reflector.sh must run on two different nodes both having a network 22d3373029SBjoern A. Zeeb interface in the same broadcast domain (be it cross-over or on a 23d3373029SBjoern A. Zeeb bridge/switch). The tests will use the IPv6 benchmarking working 24d3373029SBjoern A. Zeeb group (BMWG) prefix. The prefix is hard coded into some tests. 25d3373029SBjoern A. Zeeb Control messages will synchronize reflector with initiator. The 26d3373029SBjoern A. Zeeb reflector needs the reflect binary. Apart from that the scripts 27d3373029SBjoern A. Zeeb depend on ping6, netcat, awk, tr and ipfw. The interface to use can 28d3373029SBjoern A. Zeeb be set from the environment. The commands can be run like: 29d3373029SBjoern A. Zeeb 30d3373029SBjoern A. Zeeb env IFACE=ifname sh intiator.sh 31d3373029SBjoern A. Zeeb env IFACE=ifname sh reflector.sh 32d3373029SBjoern A. Zeeb 33d3373029SBjoern A. Zeeb Both scripts also support a DEBUG environment variable for additional 34d3373029SBjoern A. Zeeb output. A special value of 42 will enable sh(1) xtrace printing. 35d3373029SBjoern A. Zeeb 36d3373029SBjoern A. Zeeb The output format is modeled after Test::Harness Perl as used in 37*0e7ed5d6SBjoern A. Zeeb tools/regression/ but not always compliant following the test case name. 38d3373029SBjoern A. Zeeb 39d3373029SBjoern A. Zeeb NOTE: at the time of writing reflector.sh can trigger kernel races 40d3373029SBjoern A. Zeeb unrelated to multi-FIB test leading to a panic(9). "delay" calls 41d3373029SBjoern A. Zeeb are used to mitigate the problem some but are not always good enough. 42d3373029SBjoern A. Zeeb It is suggested to run one test case at a time manually disabling 43d3373029SBjoern A. Zeeb the others in both scripts. 44d3373029SBjoern A. Zeeb 45d3373029SBjoern A. Zeebforwarding.sh 46d3373029SBjoern A. Zeeb 47d3373029SBjoern A. Zeeb forwarding.sh tests FIBs in the forwarding path, making sure that 48d3373029SBjoern A. Zeeb packets tagged on input are leaving on the correct FIB. 49d3373029SBjoern A. Zeeb The script must be run on three nodes with both edge nodes (left 50d3373029SBjoern A. Zeeb and right) being connected to the middle node on separate interfaces. 51d3373029SBjoern A. Zeeb 52d3373029SBjoern A. Zeeb The script operates on the same principles and requirements as the 53d3373029SBjoern A. Zeeb two afore described ones. Environment options equally apply, with 54d3373029SBjoern A. Zeeb the middle node also taking an IFACEFAR variable to name the interface 55d3373029SBjoern A. Zeeb to the right. See the ASCII art at the beginning of the script for 56d3373029SBjoern A. Zeeb details. The script needs to be told which node it is running with 57d3373029SBjoern A. Zeeb the first argument: 58d3373029SBjoern A. Zeeb 59d3373029SBjoern A. Zeeb env IFACE=ifname sh forwarding.sh left 60d3373029SBjoern A. Zeeb env IFACE=leftifname IFACEFAR=rightifname sh forwarding.sh middle 61d3373029SBjoern A. Zeeb env IFACE=ifname sh forwarding.sh right 62d3373029SBjoern A. Zeeb 63d3373029SBjoern A. Zeeb# end 64