Vous êtes sur la page 1sur 22

MultiNets: A System for Real-Time Switching

between Multiple Network Interfaces


on Mobile Devices
Angela Nicoara
Deutsche Telekom Innovation Labs, Silicon Valley Innovation Center, US
Joint work with: Shahriar Nirjon, Cheng-Hsin Hsu,
Jatinder Pal Singh, John Stankovic
University of Virginia, US
Department of Electrical Engineering, Stanford University, US
National Tsing Hua University, Taiwan
November 14, 2013
1

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 14, 2013

Challenges in Todays Global Mobile Industry

788 million mobile-only Internet users by 2015


Global mobile traffic will increase by a factor of 26 by 2015
Mobile apps have increased the demand for more bandwidth
Meet todays functional demands and the explosive wireless market
growth that is expected over the next years

*Source: Cisco VNI Mobile, 2012

Widening Energy Gap Chalamala, Proceedings of the IEEE, 2007

Slow battery energy density growth


*Source: Ciscos Global Mobile Data Traffic Forecast, 2012
Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

Heterogeneous Network Access


Devices leave the choice of selecting the network to the end-user
Real-time network switching system that allows each end-user to select a
high-level goal, and automatically switches to the suitable network interface
Goals: 1) Save energy, 2) Higher throughput, 3) Offload data traffic
Heterogeneous Network Access

Phone usability is limited by battery life

Back haul

Base Station

IP1

IP2

Web Server
IP3

Phone

Internet

WiFi AP

Intelligently design system support to switch interfaces in real-time


to save energy, achieve higher throughput, offload data traffic
Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

Switching Network Interfaces


Switching Interfaces

WiFi 3G/2G

Activating a new interface and deactivating the

current interface:

Dynamically

Without interruptions

Based on policy

The difficulty is:

TCP is ConnectionOriented

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

Migrating Network Flows


Base Station

Web Server

Android
Mobile
Device

Backhaul

Internet

WiFi APs

Our novel solution for migrating flows between different network interfaces
without requiring changes to the existing applications, networking protocols, nor
backend servers, no extra support from the existing network infrastructure, no
user interventions, and with minimal impact to the user.

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

TCP Characteristics in Android


Our study

3-months long experiment to collect the usage

data from 13 Android phone users.

Users used a total of 221 apps, and 35 of these

apps require Internet connectivity.

Challenges / Questions
How many concurrent TCP sessions are there

at any instant of time within a mobile device?

CDF of number of concurrent TCP sessions

What are the durations of these sessions?


How much activities are there over these

sessions?

TCP Characteristics

Average lifetime of TCP sessions are ~2 sec.


Average concurrency of TCP sessions are < 2.
TCP activities are in bursts average ~3 sec.

Velocity Europe 2013

Data activity of the longest TCP session for 100 sec

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

Switching between Network Interfaces


X

Switching Algorithm (X => Y)


Step 1: Count #of TCP connections on X.
Step 2: Add routes for all existing

TCP connections on X.

Step 3: Activate Y and start all new

sessions over Y.

Step 4: Deactivate X when there is no

session on X or timeout.

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

MultiNets System Architecture


abcdABCD
Implementation

ABCD Architecture
abcd System
MultiNets

MultiNet Switching API

Switching Engine
Switching Core
(2)
getstate

(1) select
policy
(3) switching
needed?

State
Machine

Based on 3 policies:

Selection Policy
Offload
traffic

Energy
Saving

Perform
ance

(4) query

(6) switching
action

Monitoring Engine

Switching
Utility

Network
Flow

(7) change connectivity

Power

(5) read

Kernel

Performs switching
dynamically

Wireless

Energy Saving

Performance

Offload data traffic

Supports simultaneous

multiple network access

Design and principles are

general enough to be
adopted in other mobile OSes

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

MultiNets System Layered Architecture


ABCD
abcd
MultiNets
System
Layered Architecture

Native Codes

JNI

Internal API

Public API

Android

MultiNets

ConnectivityManager

WiFiManager

SwitchingManager

NetworkInfo

WiFiInfo

SwitchingInfo

ConnectivityService

Implementation

WiFiService

SwitchingService

Layered architecture
Modular design that allows:

Extending the system


capabilities without
requiring any changes
to the architecture

Isolate the mechanism,


policy and monitoring
tasks

MonitoringService
MobileStateTracker

WiFiStateTracker

NetworkUtils

WiFiNative

SwitchingUtils

android_net_wifi_WiFi.cpp

android_net_Netutils.cpp

switching_utils.cpp

wifi.c

ifc_utils.c

swi_utils.c

SelectionPolicy

~860 lines of code


No modification to kernel

Kernel

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

Multiple Network Access


MultiNets API

ABCD
abcd Usage
Simultaneous
of Network Interfaces

API for using multiple network


interfaces simultaneously for
sending and receiving data to
separate remote devices.

Apps can request to use a

specific network interface for


communicating with a specific
remote device.

Example transferring

sensitive data (e.g., user


credentials) over a secured
cellular network, and less
sensitive data over a public
WiFi network.

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

10

Switching Time and TCP Interruptions


Switching time duration between the instant when

the engine decides to switch and the instant when it


completely connects to the new interface and
disconnects the old one.

Example of switching: start sending data over 3G,

switch to WiFi when the data rate over 3G exceeds


16KBps, and switch back to 3G when the WiFi is
idle for the last 30 sec.
Type

Switching time
(msec)

3G to WiFi

1212

WiFi to 3G

196

Switching time overhead:


Switching to WiFi takes ~1sec more than switching

Switching time illustration

to 3G involving steps: scanning for access points,


associating with one of them, handshaking and a
dhcp request that are not required for 3G

11

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

11

Switching Time and TCP Interruptions

Switching time in presence of data activity for different timeout values


Timeout value of 30 sec or more makes the switching time ~15 sec,

and keeps the TCP disconnections < 1

12

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

12

Energy Measurement System

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

13

Energy for Download & Upload Data


over 3G and WiFi

Average energy needed for downloading & uploading 4KB to 4MB over 3G and WiFi

Energy consumption during data activity is higher for 3G than WiFi


Upload data is more costly than download data
Upload energy increases with the amount of data being uploaded

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

14

Where the energy goes?


Who killed my battery?

Measurements

Average idle power consumed by the WiFi network interface

295.85 mW

Average idle power consumed by the 3G network interface

3.11 mW

Turning on WiFi network interface

7.19 J

Turning on 3G network interface

13.13 J

3G setup cost before the first byte can be sent

12 J

WiFi setup cost before the first byte can be sent

1J

Energy for

data transfers, turning and keeping on the network interfaces (3G & WiFi)
Screen brightness configured to minimum
A data transfer request contains an energy setup cost of roughly 12 Joules for 3G
and 1 J for WiFi

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

15

Trace Driven Evaluation: Energy Saving


Energy Savings Heuristic:
Remains in 3G during the idle time
Switches to WiFi during data activity
Switches back to 3G when WiFi is idle

Energy saving heuristic cuts down the average daily


energy usage by 27.4% and is close to optimum.

16

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

16

Trace Driven Evaluation: Throughput

Performance Policy:
Switches to

the interface that has higher bandwidth


Uses signal strength to estimate bandwidth
Achievable throughput is 7 times higher with switching

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

17

Trace Driven Evaluation: Offloading

Offload Policy: Switch to

WiFi if available to connect


Compute the average daily WiFi usage and compare it to the
amount of data that is possible to offload if MultiNets was used
With switching we are able to offload on average 79.82% of the
average daily usage

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

18

System Overhead
Benchmark

Running MultiNets every 5 sec, we keep the overhead below 5%

Lines of code

Added

Modified

C / C++

209

Java

642

Description

Linpack

Solves dense NxN system of linear equations.

Fps2d

Measures 2D graphics frames per second.

CMark

CaffeineMark embedded benchmark. Measures


performance of Java programs involving prime
generation, loop, logic, method, floats.

Graphics

Draws opacity and transparent bitmaps.

Cpu

CPU performance of MWIPS, MFLOPS, and


VAX MIPS (SP and DP).

Mem

Memory copy operation.

File

File create, write, read, and delete.

Lines of code

19

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

19

Real Deployment
Experiments:
3 Android phones: one into the energy efficiency

mode, other 2 phones run Android one with


WiFi enabled, and the other staying over 3G only.

Use a traffic generator to replay the same data

traffic in all the phones

37 WiFi APs, average signal strengths of -64.46

dBm (inside) and -82.34 dBm (outside), and


28 WiFi disconnections during the tour.

The Stanford University campus tour

Energy saving mode saves about 33.75%


as compared to Android

MultiNets

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

20

Conclusion
Presented the problem of real-time switching between multiple
network interfaces on mobile devices
3-month long empirical study to understand the TCP characteristics
on Android mobile devices
Client-based system for dynamically and seamlessly switching
between WiFi and cellular networks based on 3 policies:
1) energy efficiency, 2) higher throughput, 3) offload data traffic

Tools for measuring the precise energy consumption on mobile


devices
System outperforms state-of-the-art Android either by saving up to
33.75% energy, or achieving near-optimal offloading, or achieving
near-optimal throughput
Techniques and principles are applicable to any mobile OSs and
extensible to any number of interfaces
Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

21

Thank You!

Velocity Europe 2013

MultiNets: Heterogeneous Network Access for Mobile Devices | November 2013 by Dr. Angela Nicoara

22

Vous aimerez peut-être aussi