forked from lf-edge/eden
-
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.
Traffic control for Eden-SDN (lf-edge#880)
With this patch, Eden-SDN now allows to apply traffic control individually for every network port. This can be used to model poor network connectivity and observe how EVE is able to deal with such challenging conditions. Signed-off-by: Milan Lenco <[email protected]>
- Loading branch information
1 parent
4f562e4
commit 0187c3c
Showing
10 changed files
with
453 additions
and
1 deletion.
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,24 @@ | ||
# SDN Example with emulated poor network connectivity | ||
|
||
Eden-SDN Network Model allows to configure traffic control individually for every network port. | ||
Included is traffic shaping, i.e. limiting traffic to meet but not exceed a configured rate, | ||
and emulating network impairments, such as packet delay, loss, corruption, reordering, etc. | ||
This can be used to simulate poor network connectivity and observe how EVE is able to deal | ||
with such challenging conditions. | ||
|
||
In this example, traffic control parameters are set for the single and only network interface. | ||
The intention is to model rather poor network connection with a low bandwidth and a high | ||
percentage of packet loss or corruption. For the purposes of the showcase, we set every | ||
available traffic control attribute to a specific non-default value. | ||
|
||
Run the example with: | ||
|
||
```shell | ||
make clean && make build-tests | ||
./eden config add default | ||
./eden config set default --key sdn.disable --value false | ||
./eden setup | ||
./eden start --sdn-network-model $(pwd)/sdn/examples/poor-network/network-model.json | ||
./eden eve onboard | ||
./eden controller edge-node set-config --file $(pwd)/sdn/examples/poor-network/device-config.json | ||
``` |
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,67 @@ | ||
{ | ||
"deviceIoList": [ | ||
{ | ||
"ptype": 1, | ||
"phylabel": "eth0", | ||
"phyaddrs": { | ||
"Ifname": "eth0" | ||
}, | ||
"logicallabel": "eth0", | ||
"assigngrp": "eth0", | ||
"usage": 1, | ||
"usagePolicy": { | ||
"freeUplink": true | ||
} | ||
} | ||
], | ||
"networks": [ | ||
{ | ||
"id": "6605d17b-3273-4108-8e6e-4965441ebe01", | ||
"type": 4, | ||
"ip": { | ||
"dhcp": 4 | ||
} | ||
} | ||
], | ||
"systemAdapterList": [ | ||
{ | ||
"name": "eth0", | ||
"uplink": true, | ||
"networkUUID": "6605d17b-3273-4108-8e6e-4965441ebe01" | ||
} | ||
], | ||
"configItems": [ | ||
{ | ||
"key": "network.fallback.any.eth", | ||
"value": "disabled" | ||
}, | ||
{ | ||
"key": "newlog.allow.fastupload", | ||
"value": "true" | ||
}, | ||
{ | ||
"key": "timer.config.interval", | ||
"value": "10" | ||
}, | ||
{ | ||
"key": "timer.location.app.interval", | ||
"value": "10" | ||
}, | ||
{ | ||
"key": "timer.location.cloud.interval", | ||
"value": "300" | ||
}, | ||
{ | ||
"key": "app.allow.vnc", | ||
"value": "true" | ||
}, | ||
{ | ||
"key": "timer.download.retry", | ||
"value": "60" | ||
}, | ||
{ | ||
"key": "debug.default.loglevel", | ||
"value": "debug" | ||
} | ||
] | ||
} |
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,66 @@ | ||
{ | ||
"ports": [ | ||
{ | ||
"logicalLabel": "eveport0", | ||
"adminUP": true, | ||
"trafficControl": { | ||
"delay": 250, | ||
"delayJitter": 50, | ||
"lossProbability": 20, | ||
"corruptProbability": 5, | ||
"duplicateProbability": 10, | ||
"reorderProbability": 30, | ||
"rateLimit": 512, | ||
"queueLimit": 1024, | ||
"burstLimit": 64 | ||
} | ||
} | ||
], | ||
"bridges": [ | ||
{ | ||
"logicalLabel": "bridge0", | ||
"ports": ["eveport0"] | ||
} | ||
], | ||
"networks": [ | ||
{ | ||
"logicalLabel": "network0", | ||
"bridge": "bridge0", | ||
"subnet": "172.22.12.0/24", | ||
"gwIP": "172.22.12.1", | ||
"dhcp": { | ||
"enable": true, | ||
"ipRange": { | ||
"fromIP": "172.22.12.10", | ||
"toIP": "172.22.12.20" | ||
}, | ||
"domainName": "sdn", | ||
"privateDNS": ["my-dns-server"] | ||
}, | ||
"router": { | ||
"outsideReachability": true, | ||
"reachableEndpoints": ["my-dns-server"] | ||
} | ||
} | ||
], | ||
"endpoints": { | ||
"dnsServers": [ | ||
{ | ||
"logicalLabel": "my-dns-server", | ||
"fqdn": "my-dns-server.sdn", | ||
"subnet": "10.16.16.0/24", | ||
"ip": "10.16.16.25", | ||
"staticEntries": [ | ||
{ | ||
"fqdn": "mydomain.adam", | ||
"ip": "adam-ip" | ||
} | ||
], | ||
"upstreamServers": [ | ||
"1.1.1.1", | ||
"8.8.8.8" | ||
] | ||
} | ||
] | ||
} | ||
} |
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
Oops, something went wrong.