-
Notifications
You must be signed in to change notification settings - Fork 0
SORA offloading script
SORA offloader is the main script that is responsible for the generation and installation of OpenFlow flows to the swith.
The SORA offloader needs Python 3.
routerPort = 64 #number of multi vlan port on switch, connected to virtual router
portList = [54, 56] #numbers ofports on the switch that are used for routing (connected to peers)
vlanList = [6, 7] #corresponding vlans of portList[] ports (as configured on the software router)
sflowHostAddr = "localhost" #As SORA and sflow-rt both run on the host, the ip is localhost
sflowHostPort = "8008" # this is the default port used for sflow-rt
ryuHostAddr = "localhost" #ryu is also run on the host machine
ryuHostPort = "8080" #default ryu port is 8080
routerAddr = "192.168.122.233" #the ip address of the software router, in this case - the virtual machine
topPrefixCount = 300 #maximum number of prefixes (flows) to offload (generate) in one cycle
offloadValue = 0 #bytes per second, minimum value of traffic necessary to offload a prefix
cooldownPeriod = 1 #time to sleep after swith is detected (when booting up), in seconds
flowTimeout = 60 #hardware timeout for OpenFlow flows, in seconds
loopSleepTime = 20 #time to sleep after each offload cycle, in seconds
tableIdForDefault = 40 #OpenFlow table id to use for default mapping (routed ports), check switch's documentation
tableIdForOffload = 40 #OpenFlow table id to use for offload flows generated from bgp routes
sleepAfterFlowInstall = 0.05 #sleep time in seconds after every flow installed, useful to not overload the switch's cpu
Before starting, ensure that the software router is both running and fully configured. It is recommended to only start the flow of traffic after the bgp tables have fully converged.
-
Start Ryu OpenFlow controller The script to launch Ryu with necesary modules is located at '(root)/Ryu/startryu.sh'.
-
Start Sflow-RT The script to launch Sflow-RT with BGP statistics support is located at '(root)/sflow-rt/start.sh'. NOTE: script must be started as ROOT.
-
Launch the offloading script 'acellerator.py', and after the BGP tables have finished converging, start the trafic flow and observe the load on the router's network interfaces versus the total amount of traffic passing through the switch.