friendlier to load balancers making multipath tcp and anycastmultipath...- stateful load balancing...

42
Making Multipath TCP friendlier to Load Balancers and Anycast Fabien Duchêne <[email protected]> Olivier Bonaventure <[email protected]> Université Catholique de Louvain ICNP 2017 - Toronto - October 2017

Upload: others

Post on 28-Sep-2020

1 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Making Multipath TCP friendlier to Load Balancers

and AnycastFabien Duchêne <[email protected]>

Olivier Bonaventure <[email protected]>Université Catholique de Louvain

ICNP 2017 - Toronto - October 2017

Page 2: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Without Multipath TCP

WiFi

4G/LTE

Address 1

Address 2

2

Page 3: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Multipath TCP: one pipe to rule them all

WiFi

4G LTE

A1

A2

WiFi

4G/LTE

3

Page 4: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Multipath TCP in a nutshell

SYN+MP_CAPABLE

A1

A2

4

Page 5: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Multipath TCP in a nutshell

SYN+MP_CAPABLE

SYN+ACK+MP_CAPABLE

A1

A2

5

Page 6: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Multipath TCP in a nutshell

SYN+MP_CAPABLE

SYN+ACK+MP_CAPABLE

SYN+MP_JOIN

A1

A2

6

Page 7: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Multipath TCP in a nutshell

SYN+MP_CAPABLE

SYN+ACK+MP_CAPABLE

SYN+MP_JOIN

SYN+ACK+MP_JOIN

A1

A2

7

Page 8: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

TCP and Load Balancers

SYN

1.2.3.4

10.0.0.1

10.0.0.2

10.0.0.3

A1

8

Page 9: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

TCP and Load Balancers

SYN

1.2.3.4

10.0.0.1

10.0.0.2

10.0.0.3

HASH(src_ip,dst_ip,src_port,dst_port,TCP) = 10.0.0.1

A1

9

Page 10: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

TCP and Load Balancers

SYN

SYN

1.2.3.4

10.0.0.1

10.0.0.2

10.0.0.3

A1

HASH(src_ip,dst_ip,src_port,dst_port,TCP) = 10.0.0.1

10

Page 11: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

TCP and Load Balancers

SYN+ACK

SYN

SYN

SYN+ACK

1.2.3.4

10.0.0.1

10.0.0.2

10.0.0.3

A1

HASH(src_ip,dst_ip,src_port,dst_port,TCP) = 10.0.0.1

11

Page 12: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

TCP and Load Balancers: Direct Server Return

HTTP GET

Web objects12

Page 13: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

The problem: Multipath TCP and Load Balancers

SYN+ACK+MP_CAPABLE

SYN+MP_CAPABLE

SYN+MP_CA

PABLE

SYN+ACK

+MP_CAPAB

LE

1.2.3.4

10.0.0.1

10.0.0.2

10.0.0.3

HASH(A1:src_ip,dst_ip,A1:src_port,dst_port,TCP) = 10.0.0.1

A1

A2

13

Page 14: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

The problem: Multipath TCP and Load Balancers

SYN+MP_JOIN10.0.0.1

10.0.0.2

10.0.0.3

1.2.3.4

A1

A2

14

Page 15: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

The problem: Multipath TCP and Load Balancers

SYN+MP_JOIN

HASH(A2:src_ip,dst_ip,A2:src_port,dst_port,TCP) = 10.0.0.2

10.0.0.1

10.0.0.2

10.0.0.3

1.2.3.4

A1

A2

15

Page 16: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

The problem: Multipath TCP and Load Balancers

SYN+MP_JOIN10.0.0.1

10.0.0.2

10.0.0.3

SYN+MP_JOIN

1.2.3.4

A1

A2 HASH(A2:src_ip,dst_ip,A2:src_port,dst_port,TCP) = 10.0.0.2

16

Page 17: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Existing solutions- This problem has been slowing down the deployment of Multipath TCP- Several solutions [1,2] already proposed but these solutions requires

- Stateful load balancing [1]- Modifications of the load balancers [1,2]

- Multipath TCP was designed to work in the “current” Internet

[1] Simon Liénardy and Benoit Donnet. Towards a Multipath TCP Aware Load Balancer. In Proceedings of the 2016 ANRW ’16[2] Vladimir Olteanu and Costin Raiciu. Datacenter scale load balancing for multipath transport. HotMIddlebox’16

17

Page 18: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Our solution: objectives

- Allow Multipath TCP to work with unmodified load balancers- Minimize the importance of the load balancer

A solution that scales

18

Page 19: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Our solution

1.2.3.4

10.0.0.1 5.6.7.8

Private

Public

19

Page 20: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Our solution

HASH(src_ip,dst_ip,src_port,dst_port,TCP) = 10.0.0.1

1.2.3.4

SYN+ACK+MP_CAPABLE

SYN+MP_CAPABLE

10.0.0.1SYN+ACK+MP_CAPABLE

SYN+MP_CAPABLE

5.6.7.8

20

Page 21: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Our solution

1.2.3.4

SYN+ACK+MP_CAPABLE

SYN+MP_CAPABLE

SYN+ACK+MP_CAPABLE

SYN+MP_CAPABLE

10.0.0.1 5.6.7.8

SYN+MP_JOIN

21

Page 22: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Our solution

1.2.3.4

SYN+ACK+MP_CAPABLE

SYN+MP_CAPABLE

SYN+ACK+MP_CAPABLE

SYN+MP_CAPABLE

10.0.0.1 5.6.7.8

SYN+MP_JOIN

22

Page 23: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Our solution

1.2.3.4

10.0.0.1 5.6.7.8

SYN+MP_JOIN

23

Page 24: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Our solution : advertising the address

SYN+MP_CAPABLE

SYN+ACK+MP_CAPABLE

ADD_ADDR(5.6.7.8)10.0.0.1 5.6.7.8

24

Page 25: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Our solution : advertising the address

SYN+MP_CAPABLE

SYN+ACK+MP_CAPABLE

ADD_ADDR(5.6.7.8)10.0.0.1 5.6.7.8

SYN+MP_JOIN

25

Page 26: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Our solution : advertising the address

SYN+MP_CAPABLE

SYN+ACK+MP_CAPABLE

ADD_ADDR(5.6.7.8)10.0.0.1 5.6.7.8

SYN+MP_JOIN

BACKUP_MODE

26

Page 27: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Our solution: beyond Direct Server Return

27

Page 28: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Implementation- Implementation done in the Linux Kernel- 3 parts:

- Avoiding MP_JOIN on load balanced addresses- Address advertisement reliability- Load balancing path manager

- +- 600 lines of code- https://github.com/fduchene/ICNP2017

28

Page 29: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Application: Layer-4 load balancer 100 Mbps link

1 Gbps link

29

Page 30: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Layer-4 load balancer: results

942Mbits/s

~90Mbits/s

30

Page 31: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Layer-4 load balancer: results

- MPTCP isn’t significantly affected by the loss

- The latency affects only the connection establishment

- Transfer rates (10MB) :- TCP : 16Mbits/sec- MPTCP : 803Mbits/sec

31

Page 32: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Application: Anycast

R1

R2

R4

R3

Anycast addr.1.2.3.4 1.2.3.4

1.2.3.4

32

Page 33: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Application: Anycast

R1

R2

R4

R3

Anycast addr.1.2.3.4 1.2.3.4

1.2.3.4

33

Page 34: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Application: Anycast

R1

R2

R4

R3

Anycast addr.1.2.3.4 1.2.3.4

1.2.3.4

34

Page 35: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Application: Anycast 1Gbps link

10 Gbps link

Anycast addr.1.2.3.4

1.2.3.45.6.7.0/24

1.2.3.48.9.10.0/24

1.2.3.411.12.13.0/24

35

Page 36: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Anycast: results

- ECMP pool of 3 servers- Every 10 sec.: remove a

server for 5 sec.

- 3 servers : 2800Mbit/s- 2 servers : 1900Mit/s- Spikes in RST when a server

is removed and when it’s re-added

36

Page 37: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Anycast: results

- No drop in Bandwidth - No RST sent

Multipath TCP can be deployed to support anycast services.

37

Page 38: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Conclusion- Multipath TCP is now on million of iPhones- Multipath TCP’s deployment has been hindered on servers

- Our solution - Works with unmodified load balancers- Puts the load balancer off-path- Enables the use of Anycast addresses

38

Page 39: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Thank you!

Fabien Duchêne <[email protected]>39

Page 40: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Backup slide : Security- Concerns about exposing the server directly- Possible solutions :

- A firewall (on the server or in the network)- Generate a specific IPv6 address per client- Block everything but MP_JOINS on public address

40

Page 41: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

Our solution : beyond Direct Server Return

NAT Direct Server Return Multipath TCP41

Page 42: friendlier to Load Balancers Making Multipath TCP and AnycastMultipath...- Stateful load balancing [1] - Modifications of the load balancers [1,2] - Multipath TCP was designed to work

A fair comparison? Fair enough!

42