Two-tier Dynamic Load Balancing with SDN

Download Report

Transcript Two-tier Dynamic Load Balancing with SDN

Two-tier Dynamic Load Balancing with SDN
Check points of Implementation:


Communication


Calculation


In Controller
Detection

1
Between Controller and Devices
In devices
Two-tier Dynamic Load Balancing with SDN
Communication:

Wi-Fi Device
Ryu Controller
Switch Enter
Calculation
Switch
Features
Switch
Experimenter
Packet In
Switch Leave
2
1. TCP socket
Boot up/
Report info.
2.SwitchFeature
3. Experimenter Msg
Update info.
Shutdown/
Crash/ Kill ps.
Detection
Two-tier Dynamic Load Balancing with SDN
Communication logs:


3
switchEnter, switchLeave, switchFeatures, switchExperimenter:
Two-tier Dynamic Load Balancing with SDN

Packet_In log in device:

Packet_In log in Controller:
4
Two-tier Dynamic Load Balancing with SDN
PACKET_IN message type:



5
dp_control.c
Create packet
Two-tier Dynamic Load Balancing with SDN
PACKET_IN message type:


6
Assign message data:
Two-tier Dynamic Load Balancing with SDN
Calculation:





New AP joins network
New Station joins network
AP leaves network
Balanced: Controller makes decision
i 
7
 na i  ns i , j


* max load
M

 j 1  i , j

 
i, j


na i
 ns i , j

na i *  
* max load
M

j 1 
i, j

2



i, j


2




 na i  ns i , j
* max load
 
M
 j 1  i , j
Li  
na i




 
i, j





Two-tier Dynamic Load Balancing with SDN
Init phase:

Calculation
1. TCP socket
Switch
Features
2.SwitchFeature
Switch
Experimenter 3. Experimenter msg.
Monitor phase:

Calculation
2. Packet_in
Packet In
3. datapath.send_msg with Experimenter
8
Boot up/
Report info./
Listen Exp.
1. Changed
Update info.
Listen Exp.
Action/ Apply
Detection
Two-tier Dynamic Load Balancing with SDN
9
Two-tier Dynamic Load Balancing with SDN
10
Two-tier Dynamic Load Balancing with SDN

The todo list of Detection:

Monitor:


Pthread_create: done
Get the real information of device: partial done


Report/Update: done


isChanged and PACKET_IN
Decision (Action/ Apply): progressing

TxPower apply:





iw dev <devname> set txpower <auto|fixed|limit> [<tx power in mBm>]
Under loaded: no need to change
Over loaded: disassociate station command

11
Max_conn, SNR, PER need to calculate
hostapd_cli deauthenticate <STA_MAC>
hostapd_cli disassociate <STA_MAC>
Balanced: report association table to controller

iwinfo wlan0 assoclist
Two-tier Dynamic Load Balancing with SDN

The data structures of device information:
12
Two-tier Dynamic Load Balancing with SDN

Show and configuration of device:


OpenWRT (AP222)
UCI system






13
uci show wireless
uci set wireless.xxx=yyy; uci commit wireless
Cat /etc/config/wireless
iw commands
iwinfo commands
hostapd_cli commands
Two-tier Dynamic Load Balancing with SDN

Critical
section:
14
Two-tier Dynamic Load Balancing with SDN

Unit test plan (1/3):

Controller
New AP:
High
loading:
CPU, MEM,
PER(?)
Lower
Signal
strength
Controller
AP-1
New
AP
AP-1
STA-1
STA-2
After add the new AP
STA-1
STA-2
Initialize the topology
Stable time:
1) Start time:
New AP gets the SwitchFeature from controller
2) End time:
New AP detects the changed when station
connected
15
Two-tier Dynamic Load Balancing with SDN

Unit test plan (2/3):

New Station:
Higher
Signal
strength
Controller
AP-1
AP-2
Higher
Signal
strength
Controller
AP-1
STA-1
AP-2
New
station
After add the new Station
STA-1
Initialize the topology
Stable time:
1) Start time:
AP detects the station’s request of link layer
association
2) End time:
New station pings out successfully (?)
16
Two-tier Dynamic Load Balancing with SDN

Unit test plan (3/3):

Remove AP:
Higher
Signal
strength
Controller
AP-1
STA-1
Higher
Signal
strength
Controller
AP-1
AP-2
AP-3
STA-2
Initialize the topology
STA-1
AP-2
STA-2
After remove the AP-3
Stable time:
1) Start time:
STA-2 fails to ping out (?)
2) End time:
STA-2 pings out successfully (?)
17
AP-3
Two-tier Dynamic Load Balancing with SDN

Simulation unit testing (1/4):
Controller
AP-1
Advantages:
1. Communication with OpenFlow
protocol
2. Don’t need more devices
3. The meter function can locate in the
device.
18
Steps:
1. AP-1 reports multiple
packet_in with fake MAC to
controller
2. AP-1 reports its information
with fake connection number
3. AP-1 applys the decision from
controller
Two-tier Dynamic Load Balancing with SDN

Simulation unit testing (2/4):

19
Fake MAC from one AP:
Two-tier Dynamic Load Balancing with SDN

Simulation unit testing (3/4):

Fake stations from one AP:
AP reports the association table
20
Two-tier Dynamic Load Balancing with SDN

Simulation unit testing (4/4):

21
AP receives the decision from controller:
Two-tier Dynamic Load Balancing with SDN

Issues:
 Crash after several packet_in:




AP222 can not assign dhcp ip to station
Openflow does not support pthread : resolved
Device inform controller with PACKET_IN: done
The issues when using the debug message in Openflow switch:



22
[X] OFP_FATAL(0, “xxxx….");
[X] ofp_error ( retval, “zzz……”);
[O] VLOG_WARN_RL(LOG_MODULE, &rl, “yyyy…..”);
Reference

http://tocai.dia.uniroma3.it/compunetwiki/index.php/Installing_and_setting_up_OpenFlow_tools

https://github.com/CPqD/ofsoftswitch13

https://github.com/CPqD/ofsoftswitch13/wiki/OpenFlow-1.3-Tutorial
23