-
Notifications
You must be signed in to change notification settings - Fork 124
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #470 from loxilb-io/main
PR - Merge latest changes to OCI branch
- Loading branch information
Showing
13 changed files
with
150 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
#!/bin/bash | ||
|
||
source ../common.sh | ||
|
||
echo "#########################################" | ||
echo "Spawning all hosts" | ||
echo "#########################################" | ||
|
||
spawn_docker_host --dock-type loxilb --dock-name llb1 | ||
spawn_docker_host --dock-type seahost --dock-name l3h1 | ||
spawn_docker_host --dock-type seahost --dock-name l3ep1 | ||
spawn_docker_host --dock-type seahost --dock-name l3ep2 | ||
spawn_docker_host --dock-type seahost --dock-name l3ep3 | ||
|
||
echo "#########################################" | ||
echo "Connecting and configuring hosts" | ||
echo "#########################################" | ||
|
||
|
||
connect_docker_hosts l3h1 llb1 | ||
connect_docker_hosts l3ep1 llb1 | ||
connect_docker_hosts l3ep2 llb1 | ||
connect_docker_hosts l3ep3 llb1 | ||
|
||
|
||
#L3 config | ||
config_docker_host --host1 l3h1 --host2 llb1 --ptype phy --addr 10.10.10.1/24 --gw 10.10.10.254 | ||
config_docker_host --host1 l3ep1 --host2 llb1 --ptype phy --addr 31.31.31.1/24 --gw 31.31.31.254 | ||
config_docker_host --host1 l3ep2 --host2 llb1 --ptype phy --addr 32.32.32.1/24 --gw 32.32.32.254 | ||
config_docker_host --host1 l3ep3 --host2 llb1 --ptype phy --addr 33.33.33.1/24 --gw 33.33.33.254 | ||
config_docker_host --host1 llb1 --host2 l3h1 --ptype phy --addr 10.10.10.254/24 | ||
config_docker_host --host1 llb1 --host2 l3ep1 --ptype phy --addr 31.31.31.254/24 | ||
config_docker_host --host1 llb1 --host2 l3ep2 --ptype phy --addr 32.32.32.254/24 | ||
config_docker_host --host1 llb1 --host2 l3ep3 --ptype phy --addr 33.33.33.254/24 | ||
sleep 5 | ||
create_lb_rule llb1 20.20.20.1 --sctp=2020:8080 --endpoints=31.31.31.1:1 | ||
create_lb_rule llb1 20.20.20.1 --tcp=2020:8080 --endpoints=31.31.31.1:1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#!/bin/bash | ||
|
||
source ../common.sh | ||
|
||
disconnect_docker_hosts l3h1 llb1 | ||
disconnect_docker_hosts l3ep1 llb1 | ||
disconnect_docker_hosts l3ep2 llb1 | ||
disconnect_docker_hosts l3ep3 llb1 | ||
|
||
delete_docker_host llb1 | ||
delete_docker_host l3h1 | ||
delete_docker_host l3ep1 | ||
delete_docker_host l3ep2 | ||
delete_docker_host l3ep3 | ||
|
||
echo "#########################################" | ||
echo "Deleted testbed" | ||
echo "#########################################" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
#!/bin/bash | ||
source ../common.sh | ||
echo SCENARIO-sctplb | ||
|
||
servArr=( "server1" "server2" "server3" ) | ||
ep=( "31.31.31.1" "32.32.32.1" "33.33.33.1" ) | ||
|
||
$hexec l3ep1 ../common/sctp_server ${ep[0]} 8080 server1 >/dev/null 2>&1 & | ||
$hexec l3ep2 ../common/sctp_server ${ep[1]} 8080 server2 >/dev/null 2>&1 & | ||
$hexec l3ep3 ../common/sctp_server ${ep[2]} 8080 server3 >/dev/null 2>&1 & | ||
|
||
sleep 5 | ||
code=0 | ||
j=0 | ||
waitCount=0 | ||
while [ $j -le 2 ] | ||
do | ||
res=$($hexec l3h1 timeout 10 ../common/sctp_client 10.10.10.1 0 ${ep[j]} 8080) | ||
#echo $res | ||
if [[ $res == "${servArr[j]}" ]] | ||
then | ||
echo "$res UP" | ||
j=$(( $j + 1 )) | ||
else | ||
echo "Waiting for ${servArr[j]}(${ep[j]})" | ||
waitCount=$(( $waitCount + 1 )) | ||
if [[ $waitCount == 10 ]]; | ||
then | ||
echo "All Servers are not UP" | ||
echo SCENARIO-sctplb [FAILED] | ||
sudo pkill sctp_server >/dev/null 2>&1 | ||
exit 1 | ||
fi | ||
|
||
fi | ||
sleep 1 | ||
done | ||
|
||
for i in {1..4} | ||
do | ||
for j in {0..2} | ||
do | ||
res=$($hexec l3h1 timeout 10 ../common/sctp_client 10.10.10.1 0 20.20.20.1 2020) | ||
echo -e $res | ||
if [[ $res != "${servArr[j]}" ]] | ||
then | ||
code=1 | ||
fi | ||
sleep 1 | ||
done | ||
done | ||
sudo pkill sctp_server >/dev/null 2>&1 | ||
if [[ $code == 0 ]] | ||
then | ||
echo SCENARIO-sctplb [OK] | ||
else | ||
echo SCENARIO-sctplb [FAILED] | ||
fi | ||
exit $code | ||
|
Submodule loxilb-ebpf
updated
8 files
+1 −1 | common/common.mk | |
+2 −0 | common/llb_dpapi.h | |
+35 −0 | kernel/llb_kern_cdefs.h | |
+67 −2 | kernel/llb_kern_devif.c | |
+2 −0 | kernel/llb_kern_entry.c | |
+5 −2 | kernel/llb_kern_fcfwd.c | |
+4 −0 | kernel/loxilb_libdp.c | |
+74 −0 | utils/loxilb_dp_tool |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters