Development of a hardware-abstraction layer for the Baltikum test - - PowerPoint PPT Presentation

development of a hardware abstraction layer for the
SMART_READER_LITE
LIVE PREVIEW

Development of a hardware-abstraction layer for the Baltikum test - - PowerPoint PPT Presentation

Chair of Network Architectures and Services Department of Informatics Technical University of Munich Development of a hardware-abstraction layer for the Baltikum test framework IDP final talk Tobias Betz December 12, 2016 Chair of Network


slide-1
SLIDE 1

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Development of a hardware-abstraction layer for the Baltikum test framework

IDP final talk Tobias Betz

December 12, 2016 Chair of Network Architectures and Services Department of Informatics Technical University of Munich

slide-2
SLIDE 2

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Contents

Baltikum framework Design goals Experiment workflow REST API Baltinet library Case study Conclusion Bibliography

  • T. Betz

– Baltikum framework 2

slide-3
SLIDE 3

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Baltikum framework

  • Framework for conducting networking experiments, currently man-

aging the Baltikum testbed.

  • Partly developed during Bachelor Thesis.
  • T. Betz

– Baltikum framework 3

slide-4
SLIDE 4

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Baltikum framework — Design goals

Main goal: reproducible automated network experiments with hardware- independent framework

  • Modular low-level interfaces for interaction with testbed hardware
  • Interactive control over hosts during the experiment
  • T. Betz

– Baltikum framework 4

slide-5
SLIDE 5

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Baltikum framework — Design goals — Modular low-level interface

Every node provides three functions: start(), command(), and stop()

Listing 1: Old implementation

1 function node.start() { 2

iPXE configuration

3

IPMI command

4

...

5 } 6

Listing 2: New implementation

1 function node.start() { 2

switch(node.boot_module)

3

case IPMI:

4

IPMI.send_command(...)

5 6

case Wake -on-LAN:

7

WoL.send_magic_packet(...)

8 9

case always -on:

10

nop

11 } 12

Same for command() and stop()

  • T. Betz

– Baltikum framework 5

slide-6
SLIDE 6

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Baltikum framework — Design goals — Interactive control

MGMT Node1 Node2 Deploy/start rolescript

  • configure node
  • testing process
  • synchronize
  • upload results

Figure 1: Old workflow

  • T. Betz

– Baltikum framework 6

slide-7
SLIDE 7

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Baltikum framework — Design goals — Interactive control

MGMT Node1 Node2 Deploy config Foreground command Background command Node3 Queued command Queued command Queued command

Figure 2: New workflow with command types

  • T. Betz

– Baltikum framework 7

slide-8
SLIDE 8

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Baltikum framework — Experiment workflow

  • 1. Allocate resources
  • 2. Configure resources
  • 3. Testing process
  • 4. Free resources
  • T. Betz

– Baltikum framework 8

slide-9
SLIDE 9

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Baltikum framework — Experiment workflow

Modular low-level interface Interactive control Modular low-level interface

  • 1. Allocate resources
  • 2. Configure resources
  • 3. Testing process
  • 4. Free resources
  • T. Betz

– Baltikum framework 8

slide-10
SLIDE 10

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Baltikum framework — REST API

http://.../allocation http://.../cmd http://.../allocation

  • 1. Allocate resources
  • 2. Configure resources
  • 3. Testing process
  • 4. Free resources
  • T. Betz

– Baltikum framework 9

slide-11
SLIDE 11

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Baltikum framework — REST API — /allocation

Allocation status of the nodes

1 { 2

"id": "pc3.r",

3

"user": "betz",

4

"status": "allocated",

5

"test_id": "MyExperiment",

6

"force_reboot": true

7 }

  • T. Betz

– Baltikum framework 10

slide-12
SLIDE 12

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Baltikum framework — REST API — /cmd

Users can send commands for the nodes to execute

1 { 2

"node": "pc3.r",

3

"user": "betz",

4

"payload": "whoami; echo foo = $foo",

5

"background": false ,

6

"queued": false

7 }

Example response

1 { 2

"message": "root\nfoo = bar\n",

3 }

  • T. Betz

– Baltikum framework 11

slide-13
SLIDE 13

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Baltikum framework — REST API — /nodes

Static information about testbed hardware

1 { 2

"id": "pc3.r",

3

"type": "host",

4

"description": "Intel(R) Xeon(R) CPU E3 -1265L V2 @ 2.50GHz , 4 cores",

5

"interfaces": [

6

{

7

"description": "Intel 82580 Gigabit Network Connection",

8

"id": "eth0",

9

"phys -address": "90:e2:ba:2a:91:fc",

10

"speed": "1Gb"

11

},

12

...

13

],

14

"management": {

15

"address": "pc3.r",

16

"configuration": "ssh -jumper -ilab",

17

"initialize": "wake -on-lan -ilab",

18

"phys -address": "bc:5f:f4:4a:49:59"

19

},

20

"config": {}

21 }

  • T. Betz

– Baltikum framework 12

slide-14
SLIDE 14

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Baltinet library

  • User-side Python library to provide abstraction from the REST API
  • User does not have to send HTTP requests by hand
  • T. Betz

– Baltikum framework 13

slide-15
SLIDE 15

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Baltinet library — Overview

Baltinet MGMT Host1 User Baltinet.start() PATCH /allocation IPMI Host1.cmd() POST /cmd SSH

  • T. Betz

– Baltikum framework 14

slide-16
SLIDE 16

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Case study — Experimenting on the iLab testbed

  • Secure Multiparty Computation experiment (ongoing Master The-

sis)

  • iLab hosts have homogeneous hardware, good for P2P protocols
  • Measure time to setup communication in SMC framework
  • T. Betz

– Baltikum framework 15

slide-17
SLIDE 17

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Case study — iLab testbed

Isle S ilab-control Server central switch Isle A Isle B Isle C Isle D Isle R Isle F Isle E network equipment for users KVM switch pc2 pc3 isle switch pc1 KVM switch pc5 pc6 pc4

Figure 3: The iLab testbed [1]

  • T. Betz

– Baltikum framework 16

slide-18
SLIDE 18

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Case study — Framework overview

kaunas Eve REST API MongoDB pcX.Y ilab-control SSH proxy Power management script iPXE DNS DHCP S S H W

  • L

SSH SSH HTTP Experimenter's computer Baltinet script HTTP Baltinet library

Figure 4: Baltikum framework controlling the iLab testbed

  • T. Betz

– Baltikum framework 17

slide-19
SLIDE 19

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Case study— Baltinet script

Listing 3: Example Baltinet script

1 import baltinet 2 3 topo = baltinet.Topo(...) 4 bn = baltinet.Baltinet(topo=topo , exp_id='MyExperiment ') 5 bn.start()

# 1./2. Allocate/Configure resources (/ allocation)

6 7 bn['pc3.r'].cmd('./ install.sh')

# 3. Testing process (/cmd)

8 9 for host in bn.hosts: 10

host.cmd('./run.sh > /tmp/output ') # 3. Testing process (/cmd)

11 12 for host in bn.hosts: 13

# upload results

14

host.cmd('testbed -upload /tmp/output ') # 3. Testing process (/cmd)

15 16 bn.stop()

# 4. Free resources (/ allocation)

  • T. Betz

– Baltikum framework 18

slide-20
SLIDE 20

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Case study— Results

Experiment successfully ran on 11 iLab hosts (2 isles)

Listing 4: SMC Experiment results

1 num ,time ,nodeid ,result ,testid 2 11,764,1,132, parameters_11_8_1600_20 3 11,764,2,132, parameters_11_8_1600_20 4 11,765,3,132, parameters_11_8_1600_20 5 11,765,4,132, parameters_11_8_1600_20 6 11,766,5,132, parameters_11_8_1600_20 7 11,756,6,132, parameters_11_8_1600_20 8 11,765,7,132, parameters_11_8_1600_20 9 11,764,8,132, parameters_11_8_1600_20 10 11,764,9,132, parameters_11_8_1600_20 11 11,763,10,132, parameters_11_8_1600_20 12 11,764,11,132, parameters_11_8_1600_20

  • T. Betz

– Baltikum framework 19

slide-21
SLIDE 21

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Conclusion

  • Successful case study on iLab testbed
  • Restructured REST API

⇒ Optional reboot of hosts, check allocation status, ...

  • Dynamic interaction with hosts during experiment using /cmd end-

point ⇒ No more static role scripts

  • Modular low-level control over testbed (modules for SSH, Wake-
  • n-LAN, ...)

⇒ Easier to refactor and expand

  • T. Betz

– Baltikum framework 20

slide-22
SLIDE 22

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Q&A

  • T. Betz

– Baltikum framework 21

slide-23
SLIDE 23

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

[1] M. Teich, L. Schwaighofer, and B. Hof. ilabos Overview. https://ilab.net.in.tum.de/ilabos/pages/overview.html.

  • T. Betz

– Baltikum framework 22

slide-24
SLIDE 24

Chair of Network Architectures and Services Department of Informatics Technical University of Munich

Baltikum framework — REST API — /status

Dynamic status of the nodes

1 { 2

"id": "pc3.r",

3

"user": "betz",

4

"os": "rebooting",

5

"power": "on",

6

"testbed": "not_deployed"

7 }

  • T. Betz

– Baltikum framework 23