placement of virtual containers on numa systems · placement of virtual containers on numa systems...

30
Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere , and Alexandra Fedorova, University of British Columbia Baptiste Lepers, EPFL David Vengerov and Jean-Pierre Lozi, Oracle Labs Vivien Quéma, IMAG 1 * Currently Huawei R&D Currently Arista Networks

Upload: others

Post on 18-Mar-2020

9 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Placement of Virtual Containers on

NUMA Systems

Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British Columbia

Baptiste Lepers, EPFL

David Vengerov and Jean-Pierre Lozi, Oracle Labs

Vivien Quéma, IMAG

1

* Currently Huawei R&D† Currently Arista Networks

Page 2: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Motivation

2

Data Centers:

3% of global electricity usage

86% used by servers+cooling

Page 3: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Motivation – Server Packing

3

Container/Application

Server

Resource Node

Page 4: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Motivation – Server Packing

4

Container/Application

Server

Resource Node

Page 5: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Motivation – Server Packing

▪ Half as many servers!

▪ Half as much energy!

▪ Half as much infrastructure!

▪ Performance?

5

VS.

Page 6: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Motivation – Server Packing

6

Container/Application

Server

Resource Node

Application Thread

Page 7: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Background – “Module”

7

Page 8: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Background – NUMA Node

8

Page 9: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Background – Interconnect Topology

9

Page 10: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Assumptions

▪ The number of vCPUs a container uses is

fixed

▪ Max of one vCPU per core

▪ Containers packed together should not

interfere with each other – containers will not

share NUMA nodes

10

Page 11: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Placements

11

Page 12: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Placements

12

Page 13: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Placements

13

Page 14: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Motivation – ua.B (scientific simulation)

14

Page 15: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Motivation – Spark Pagerank

15

Page 16: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Workload Placement Overview

16

Run Training

Benchmarks on

Important Placements

Train Model

Multi-Output Random

Forest Model

Performance/Packing

Trade-Offs

Performance

MeasurementsHardware

Description

Performance

Predictions

Important

Placements

Scheduling

Concerns

Abstract Machine Model (Offline) Performance Prediction Model (Online)

Page 17: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Abstract Machine Model

▪ How to represent placements?▪ Too many (e.g. trillions for 16 threads on 64 cores) for a

naïve approach

▪ Need to exploit symmetry

17

Page 18: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Scheduling Concerns

18

Placement:

Scheduling Concern:

Score: 4

Page 19: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Scheduling Concern Example – L3

19

Placement:

Scheduling Concern:

Score = # L3 Caches In-Use 4

Page 20: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Scheduling Concern Example – L2

20

Placement:

Scheduling Concern:

Score = # L2 Caches In-Use 2

Page 21: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Abstract Machine Model – Important Placements

21

▪ Scheduling concerns + Important placements:

▪ ~1014 Placements → 12 Placements

− 16 threads on 64 cores

▪ Can train on all important placements

Page 22: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Performance Prediction Model – Features/Inputs

▪ Hardware Performance Events (HPEs)

− Standard in existing work

− Surprisingly, poor predictive performance!

− Excessive training time

▪ Performance Measurements

22

Page 23: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Performance Predictions, Online Inference

23

Page 24: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Performance Predictions – ua.B (scientific sim.)

24

Page 25: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Performance Predictions – Spark Pagerank

25

Page 26: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Performance Predictions – is.D (sort)

26

Page 27: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Machine Learning – Prediction Accuracy

27

Page 28: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Conclusion

▪ Data centers: 3% world’s electricity (86%

servers+cooling)

▪ Packing containers onto servers

− Increase efficiency

− Maintain performance goals

▪ 2-4× better utilization in many cases!

▪ Abstract machine model

▪ Performance prediction model

28

Page 29: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Questions?

29

Page 30: Placement of Virtual Containers on NUMA Systems · Placement of Virtual Containers on NUMA Systems Justin Funston*, Maxime Lorrillere†, and Alexandra Fedorova, University of British

Workload Placement – Related Work

30

Predicts Performance Multiple Hardware

Resources

Easily Adapted Deployable Online

Our Solution ✓ ✓ ✓ ✓

Pandia (EuroSys ‘17) ✓ ✓ ✗ ✗

SMiTe (Micro ‘14) ✓ ✓ ✗ ✓

Bubble-Flux (ISCA

‘13)✓ ✓ ✗ ✓

Asymsched (ATC ‘15) ✗ ✗ ✓ ✓

DINO (ASPLOS ‘10) ✗ ✗ ✓ ✓

Thread Clustering

(EuroSys ‘07)✗ ✗ ✓ ✓