SLIDE 1 WiFi Can Be the Weakest Link of Round Trip Network Latency in the Wild
Changhua Pei†, Youjian Zhao†, Guo Chen†, Ruming Tang†, Yuan Meng†, MinghuaMa†, Ken Ling‡, Dan Pei† †Tsinghua University ‡Carnegie Mellon University
1
SLIDE 2 WiFi is indispensable in our daily lives
v Overall WiFi Traffic Growth
2
Source: Cisco VNI Mobile, 2016
SLIDE 3 WiFi is indispensable in our daily lives!
v Booming of the Access Points:
3 Number of Access Points!
Source: Maravedis, Cisco VNI Mobile, 2016
SLIDE 4 CDF(%) RTT (ms) wired part wireless part 20 40 60 80 100 0.1 1 10 100 1000 10000
4
WiFi performance is far from satisfactory
Unsatisfactory
Stringent Threshold: 20~30ms
25ms
SLIDE 5 5
WiFi performance is far from satisfactory
47%
PAGE LOAD TIME > 3 SECONDS
USERS WILL ABANDON THE PAGES
40%
PAGE LOAD TIME < 2 SECONDS
USERS EXPECT LEADS TO
Akamai study. http://goo.gl/2pwozG.
SLIDE 6 6
WiFi performance is far from satisfactory
10
ms LAST-MILE DELAY increase
1000
ms PAGE LOAD TIME increase
Bismark Paper: S. Sundaresan, N. Feamster, R. Teixeira, N. Magharei, et al. Measur- ing and mitigating web performance bottlenecks in broadband access
- networks. In ACM Internet Measurement Conference, 2013.
SLIDE 7
7
WiFi performance is far from satisfactory
Stringent Threshold: 20~30ms
SLIDE 8
Challenge: Large Search Space of AP parameters
8 Transmit Power?
Channel? Location?
1 11 6
BLIND SEARCH among all re- configuration possibilities Don’t know the effect before the re- configuration
Channel Width?
SLIDE 9 Airtime Utilization Retry Ratio RSSI Throughput Physical Rate Queuing Length
Transmit Power?
Channel? Location? Channel Width? DELAY
Gap
Model Domain Knowledge
Configurable Parameters WiFi Factors WiFi Hop Latency
10
- 1. How to accurately measure the WiFi hop latency ?
- 2. How to predictthe WiFi hop latency usingWiFi factors
effectively?
- 3. How to use this model to help AP owners to tune their APs?
SLIDE 10
Trace Training ML Model WiFi Factors for this AP Optimization
12
Problematic AP Measurement
Transmit Power?
Channel? Location? Channel Width? Reconfigure which ?
SLIDE 11
Transmit Power?
Channel? Location? Channel Width? Reconfigure which ?
Problematic AP WiFi Factors for this AP ML Model Training Trace Optimization Measurement
14
SLIDE 12 Measuring WiFi Hop Latency: Background
12
UL PL WL+S PL DL RTT S TCP SYN TCP SYN-ACK TCP ACK
Client AP Server
SLIDE 13 13
v RTT: Using PING at client side: RTT = t3-t0
client-side assistance
UL PL WL+S PL DL RTT S TCP SYN TCP SYN-ACK TCP ACK
Client AP Server
Measuring WiFi Hop Latency: existing approaches need client-side involvement
SLIDE 14 Measuring WiFi Hop Latency: existing approaches need client-side involvement
14
v RTT: Using PING at client side: RTT = t3-t0 v DL: Packet Capture: DL = t3 – t2’
Time synchronization
client-side assistance
UL PL WL+S PL DL RTT S TCP SYN TCP SYN-ACK TCP ACK
Client AP Server
SLIDE 15 Delay Type Description 3-way handshake packets WL t2’-t1’ √
Measuring WiFi Hop Latency: all measurements on APs
15
UL PL WL+S PL DL RTT TCP SYN TCP SYN-ACK TCP ACK
Client AP Server
SLIDE 16 Delay Type Description 3-way handshake packets WL t2’-t1’ √ DL
Measuring WiFi Hop Latency: all measurements on APs
16
UL PL WL+S PL DL RTT TCP SYN TCP SYN-ACK TCP ACK
Client AP Server
MAC layer ACK
SLIDE 17 Delay Type Description 3-way handshake packets WL t2’-t1’ √ DL t3’-t2’ √
17
UL PL WL+S PL DL RTT TCP SYN TCP SYN-ACK TCP ACK
Client AP Server
Measuring WiFi Hop Latency: all measurements on APs
MAC layer ACK
SLIDE 18 Delay Type Description 3-way handshake packets WL t2’-t1’ √ DL t3’-t2’ √ UL t4’-t3’ √
18
UL PL WL+S PL DL RTT TCP SYN TCP SYN-ACK TCP ACK
Client AP Server
Measuring WiFi Hop Latency: all measurements on APs
MAC layer ACK
SLIDE 19 Delay Type Description 3-way handshake packets WL t2’-t1’ √ DL t3’-t2’ √ UL t4’-t3’ √ Data packets DL t3’-t2’ √
19
UL PL WL+S PL DL RTT TCP SYN TCP SYN-ACK TCP ACK
Client AP Server
Measuring WiFi Hop Latency: all measurements on APs
MAC layer ACK
SLIDE 20 Delay Type Description 3-way handshake packets WL t2’-t1’ √ DL t3’-t2’ √ UL t4’-t3’ √ Data packets DL t3’-t2’ √ UL delay-ACK
UL PL WL+S PL DL RTT TCP SYN TCP SYN-ACK TCP ACK
Client AP Server
Measuring WiFi Hop Latency: all measurements on APs
MAC layer ACK
SLIDE 21 Delay Type Description 3-way handshake packets WL t2’-t1’ √ DL t3’-t2’ √ UL t4’-t3’ √ Data packets WL S
t3’-t2’ √ UL delay-ACK
UL PL WL+S PL DL RTT TCP SYN TCP SYN-ACK TCP ACK
Client AP Server
Use the latest 3-way handshake packet to approximate data packets’ WL and UL!
Measuring WiFi Hop Latency: all measurements on APs
MAC layer ACK
SLIDE 22
Data collection
v Real deployment in Tsinghua University in China. v 47 free Netgear WNDR4300 router equipped with Openwrt v 44 in dormitory, 3 in department of computer science v Continuously collected from May 20th to July 20th v Collected about 2 terabytes raw data trace
22
SLIDE 23
Measurement Result
23 50% packets’ WiFi hop latency >20ms 10% packets’ WiFi hop latency >100ms
SLIDE 24
Measurement Result
24 For nearly 50% of the domestic packet, over 60% of the time is occupied by WiFi hop delay.
SLIDE 25
Transmit Power?
Channel? Location? Channel Width? Reconfigure which ?
WiFi Factors for this AP Problematic AP ML Model Measurement Trace Optimization Training
28
SLIDE 26
Predicting the Latency using WiFi factors
26
Machine Learning
WiFi Hop Latency (Fast vs. Slow) as labels WiFi Factors as features Predicting Model
SLIDE 27 Abbr. WiFi factors Description Generated By AU airtime utilization % of channel time used by all the traffic iw info Q queue length snapshot Number of packets queued in hardware queue. debugfs RR retry ratio %packets retried in IEEE 802.11 MAC-layer. iw info RSSI RSSI Received signal strength of UE associated on AP. iw info Ttx transmitting throughput Bytes sent to UE every 10s. ifconfig info Trx receiving throughput Bytes received from UE every 10s. ifconfig info RPR receiving physical rate Snapshot of physical rate for receiving packets from UE. iw info TPR transmitting physical rate Snapshot of physical rate for sending packets to UE. iw info
27
SLIDE 28 Visualization and Correlation analysis
Purposes:
- Intermediate results to gain some intuitions
- Help explain the ML results.
28
SLIDE 29 Visualization of the correlation
29
Airtime Utilization Transmitting Physical Rate Receiving Throughput Transmitting Throughput RSSI Retry Ratio Queue Snapshot Receiving Physical Rate
Positive Trends Negative Trends No Clear Trends
SLIDE 30 Visualization of the correlation
30
Airtime Utilization Transmitting Physical Rate Receiving Throughput Transmitting Throughput RSSI Retry Ratio Queue Snapshot Receiving Physical Rate
Positive Trends Negative Trends No Clear Trends
No strong effect on WiFi hop latency when : AU < 0.5 or TPR > 60 Mbps or RSSI > -60 dbm
The model is general because almost all parameter spaces are covered thanks to the variety of the data.
SLIDE 31 Correlation Analysis
v Kendall correlation: (Kendall) v Relative Information Gain: (RIG) how much a factor helps to predict the final latency
31
Quality Metric Kendall RIG AU 0.86 0.05 RSSI
0.06 RR 0.4 0.08 TPR
0.11 RPR
0.09 Trx
0.01 Q 0.15 0.007 Ttx
0.02
!"# = &'(&')*"(! +",)- − *,-&')*"(! +",)- ((( − 1)/2
SLIDE 32 Correlation Analysis
32
v TPR is the best choice to present the latency. This is because of the rate adaption algorithm. Quality Metric Kendall RIG AU 0.86 0.05 RSSI
0.06 RR 0.4 0.08 TPR
0.11 RPR
0.09 Trx
0.01 Q 0.15 0.007 Ttx
0.02
SLIDE 33
Decision Tree
33
Decision Tree
( AU, RR, RSSI, Trx,Ttx, TPR, RPR) Predicting Model SLOW/FAST
SLIDE 34
Decision Tree
v4 FAST: :;, =; < 12.5 A-, :; + =; < 25 A- SLOW::;, =; ≥ 12.5 A-, :; + =; ≥ 25 A- vPackage: scikit learn package vEvaluation: 10-fold validation
34
SLIDE 35
Decision Tree
35 Method Latency Type Accuracy Truth Positive Rate False Positive Rate Decision Tree DL 0.78 0.76 0.24 UL 0.68 0.67 0.27 DL+UL 0.77 0.79 0.31
SLIDE 36
Decision Tree
36
vThe Random Forest, ( tree number = 200, tree depth = 100), Accuracy > 0.8 with 0.21 False Positive Rate for DL. vWhy Decision Tree instead of Random Forest? interpretability+ usability
Method Latency Type Accuracy Truth Positive Rate False Positive Rate Decision Tree DL 0.78 0.76 0.24 UL 0.68 0.67 0.27 DL+UL 0.77 0.79 0.31
SLIDE 37
Decision Tree
37
SLIDE 38
Training Measurement Trace Optimization
38
ML Model WiFi Factors for this AP Problematic AP
Transmit Power?
Channel? Location? Channel Width? Reconfigure which ?
SLIDE 39 39
45 >0.42 >55
TPR RSSI AU AU FAST
0.42
TPR FAST SLOW RR
68
SLOW
>0.16
RR SLOW
>0.42
RPR
0.42
SLOW
62
TPR
>62
SLOW FAST AU
RR
0.53 >35
FAST
0.52 78 >0.53
FAST SLOW SLOW
35
SLOW
>0.52 b1 b2 b3 b4 b5 b6 b7 b8 b9 b10 b11 b12 b13 >78 >-45 >68 0.55 >0.55 0.16
branch B1 B2 B5 B6 B7 B10 B11 B12 b13 before after 0.1% 0.8% 3% 58% 6.7% 13.4% 4.2% 13.8% 0% 0% 0.5% 61.2 0.4% 3.5% 0.4% 34%
- 1. Classifying WiFi factor traces
- 2. Locate theworst branch
- 3. Reconfigure the AP
Case Study 1: Relocate the AP
SLIDE 40 40
Case Study 1: Relocate the AP
CDF of OAP DL one week before and one week after
- ptimization under the guidance of decision tree.
50ms 10ms
5X improvement!
SLIDE 41
Three Steps for Optimization
vCollect raw WiFi factor traces from the AP we want to diagnose and use the decision tree to classify these samples.
41
SLIDE 42 Three Steps for Optimization
vCollect raw WiFi factor traces from the AP we want to diagnose and use the decision tree to classify these samples. vFind the worst branch and locate the candidate factors for
42
SLIDE 43 Three Steps for Optimization
vCollect raw WiFi factor traces from the AP we want to diagnose and use the decision tree to classify these samples. vFind the worst branch and locate the candidate factors for
vReconfigure the AP to change the value of certain split criterion.
43
SLIDE 44
44
Case Study 2: Channel Switching
SLIDE 45
45
Case Study 2: Channel Switching
CDF of AU and DL one week before and one week after the channel selection.
0.6
0.52
250ms 50ms
SLIDE 46
Trace Training ML Model WiFi Factors for this AP Optimization
12
Problematic AP Measurement
Transmit Power?
Channel? Location? Channel Width? Reconfigure which ?
SLIDE 47 Conclusion & Future Work
- Effectively measuring the Round Trip Network Latency.
- Comprehensive measurement on 47 APs in the wild.
- Train a decision tree based model which shows good
- ptimization results in the wild.
- This work can be further extended by: Delay ACK packets
filtering
- This work can be applied to other applications such as :
dynamic channel selection.
47
SLIDE 48
48
Thank you!
peich14@mails.tsinghua.edu.cn