forked from outscale/butterfly
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
tests: add tcp test on two butterflies
closed outscale#34 Signed-off-by: Thiery Ouattara <thiery.ouattara@outscale.com>
- Loading branch information
1 parent
d21df17
commit 6b7e922
Showing
4 changed files
with
93 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# Description | ||
|
||
``` | ||
+-----------+ +-----------+ | ||
(vni 42) [ VM 1 ]-----| | | |-----[ VM 3 ] (vni 42) | ||
| Butterfly +======+ Butterfly | | ||
(vni 42) [ VM 2 ]-----| | | |-----[ VM 4 ] (vni 42) | ||
+-----------+ +-----------+ | ||
``` | ||
|
||
This scenario connects four virtual machines through two butterfly. | ||
Each VM are in the same network (VNI) and can send udp message. |
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,33 @@ | ||
#!/bin/bash | ||
|
||
BUTTERFLY_SRC_ROOT=$1 | ||
BUTTERFLY_BUILD_ROOT=$2 | ||
|
||
source $BUTTERFLY_SRC_ROOT/tests/functions.sh | ||
|
||
network_connect 0 1 | ||
server_start 0 | ||
server_start 1 | ||
add_nic_full_open 0 1 42 | ||
add_nic_full_open 0 2 42 | ||
add_nic_full_open 1 3 42 | ||
add_nic_full_open 1 4 42 | ||
qemu_start 1 | ||
qemu_start 2 | ||
qemu_start 3 | ||
qemu_start 4 | ||
ssh_tcp 1 2 1234 | ||
ssh_tcp 1 3 5554 | ||
ssh_tcp 1 4 4123 | ||
ssh_tcp 4 1 5004 | ||
ssh_tcp 4 2 5964 | ||
ssh_tcp 4 3 5554 | ||
qemu_stop 1 | ||
qemu_stop 2 | ||
qemu_stop 3 | ||
qemu_stop 4 | ||
server_stop 0 | ||
server_stop 1 | ||
network_disconnect 0 1 | ||
return_result | ||
|
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,14 @@ | ||
# Description | ||
|
||
``` | ||
+-----------+ +-----------+ | ||
(vni 42) [ VM 1 ]-----| | | |-----[ VM 3 ] (vni 1337) | ||
| Butterfly +======+ Butterfly | | ||
(vni 1337) [ VM 2 ]-----| | | |-----[ VM 4 ] (vni 42) | ||
+-----------+ +-----------+ | ||
``` | ||
|
||
This scenario connects four virtual machines through two butterfly. | ||
VM 1 & VM 4 are on the same VNI (42). | ||
VM 2 & VM 3 are on the same VNI (1337). |
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,33 @@ | ||
#!/bin/bash | ||
|
||
BUTTERFLY_SRC_ROOT=$1 | ||
BUTTERFLY_BUILD_ROOT=$2 | ||
|
||
source $BUTTERFLY_SRC_ROOT/tests/functions.sh | ||
|
||
network_connect 0 1 | ||
server_start 0 | ||
server_start 1 | ||
add_nic_full_open 0 1 42 | ||
add_nic_full_open 0 2 1337 | ||
add_nic_full_open 1 3 1337 | ||
add_nic_full_open 1 4 42 | ||
qemu_start 1 | ||
qemu_start 2 | ||
qemu_start 3 | ||
qemu_start 4 | ||
ssh_tcp 1 4 4445 | ||
ssh_tcp 4 1 4335 | ||
ssh_no_tcp 1 2 5445 | ||
ssh_no_tcp 1 3 1545 | ||
ssh_no_tcp 4 2 2905 | ||
ssh_no_tcp 4 3 1250 | ||
qemu_stop 1 | ||
qemu_stop 2 | ||
qemu_stop 3 | ||
qemu_stop 4 | ||
server_stop 0 | ||
server_stop 1 | ||
network_disconnect 0 1 | ||
return_result | ||
|