Floodlight OpenFlow Contoller - Updated Overview

20
OpenFlow Controller http://floodlight.openflowhub.org

description

We're starting to present an overview of Floodlight to a number of parties. Thought folks would be interested in our slides.

Transcript of Floodlight OpenFlow Contoller - Updated Overview

Page 1: Floodlight OpenFlow Contoller - Updated Overview

OpenFlow Controller

http://floodlight.openflowhub.org

Page 2: Floodlight OpenFlow Contoller - Updated Overview

©2012 – Big Switch Networks Inc. 2

About Us

Big Switch Networks builds and promotes Open Software Defined Networking Solutions

We use and help support Floodlight and a number of other OpenFlow tools

Yes, you can contact us about jobs and internships at [email protected]

Big Switch Networks

Page 3: Floodlight OpenFlow Contoller - Updated Overview

©2012 – Big Switch Networks Inc. 3

Introduction

Floodlight overview

Floodlight architecture

Demo!

Page 4: Floodlight OpenFlow Contoller - Updated Overview

4

Floodlight Overview

Floodlight is a completely open, free, Apache-licensed Java-based OpenFlow controller.

©2012 – Big Switch Networks Inc.

Page 5: Floodlight OpenFlow Contoller - Updated Overview

5

Floodlight Controller

Research and commercial friendly

A great platform for OpenFlow

Easy to build, run, and develop

Rich set of build and debugging tools

Community of OpenFlow experts, access to commercial upgrades, and frequent testing

Toolchain

©2012 – Big Switch Networks Inc.

Page 6: Floodlight OpenFlow Contoller - Updated Overview

6

Building Floodlight

$ git clone git://github.com/floodlight/floodlight.git

$ sudo apt-get install build-essential default-jdk ant python-dev

$ cd floodlight; ant

$ java –jar target/floodlight.jar

Fast…an easy…

Download from Github

$ wget http://floodlight.openflowhub.org/files/floodlight-vm.zip

(login as “floodlight” user, no password)

Get the VM (including mininet)

©2012 – Big Switch Networks Inc.

Page 7: Floodlight OpenFlow Contoller - Updated Overview

7

Other Floodlight Highlights

Floodlight Controller

Java A

pp

Jytho

n A

ppOF Switch

OF Switch

Switch

OF Switch

OF Switch

Static Flow

Pusher Active work in

defining standard “Northbound” APIs

REST-based App

1 Java event APIs

REST-based APIs

Ability to push flows

2

Support for integrating with non-OpenFlow networks

3

©2012 – Big Switch Networks Inc.

Page 8: Floodlight OpenFlow Contoller - Updated Overview

Submit a project

Write a blog post

http://www.openflowhub.org

Contact: [email protected]

OpenFlowHub

1. A community of open source OpenFlow developers

2. An OpenFlow Blog (available for guest authors)

3. Free hosting, tools, and marketing for open source projects

Wiki, forums, bug tracking tools, logos, etc.

A community of open source OpenFlow developers

©2012 – Big Switch Networks Inc.

What it is: Get involved:

Projects:

Page 9: Floodlight OpenFlow Contoller - Updated Overview

Internals

Page 10: Floodlight OpenFlow Contoller - Updated Overview

©2012 – Big Switch Networks Inc. 10

Architecture Overview

Everything is a module: modules export servicesSynchronous service callsAsynchronous publish/subscribe eventsAutomatic dependency resolution

Programming environmentCore and all current modules written in JavaRich, extensible REST APIRecently added Jython: could dev in Python

Main Module: Floodlight “Provider”Manages OpenFlow switch I/O with NettyTranslates OpenFlow messages to Floodlight Events

Page 11: Floodlight OpenFlow Contoller - Updated Overview

IFloodlightModule Interface

1. getModuleDependencies() What services does this module require?

2. getModuleServices(), getServiceImpls() Services does this module provide and how?

3. init(FloodlightModuleContext context) Internal, before dependencies have init()’d

4. startup(FloodlightModuleContext context) External, with dependencies initialization

Function Description

getModuleDependencies() What services does this module require?

getModuleServices() Services does this module provide and how?

init(FloodlightModuleContext context) Internal, before dependencies have init()’ed

startup(FloodlightModuleContext context)

External, with dependencies initialization

Page 12: Floodlight OpenFlow Contoller - Updated Overview

©2012 – Big Switch Networks Inc. 12

Netty

An asynchronous event-driven network application framework

Page 13: Floodlight OpenFlow Contoller - Updated Overview

©2012 – Big Switch Networks Inc. 13

Threading Model

All inter-module communication is through services Inter-service calls need to be thread safe

Event handling happens in publisher’s thread contextDon’t block, use a bottom half handler

Thread pool executer service existsAllows modules to share threads

Number of shared data structures protected by locksAny Java object can be an eventStandard locks apply : synchronized

Page 14: Floodlight OpenFlow Contoller - Updated Overview

©2012 – Big Switch Networks Inc. 14

Floodlight Provider Module

Manages I/O from OF SwitchesTracks switch add/removesTranslates OF messages to Floodlight events

IFloodlightProvider ServiceaddOFMessageListener(OFType type)

Ordering defined by caller with OFMessageListener iface

Map<dpid,Switches> getSwitches();addOFSwitchListener(); injectOfMessage(IOFSwitch sw, OFMessage msg);

Used for recirculation-style hacks

Page 15: Floodlight OpenFlow Contoller - Updated Overview

©2012 – Big Switch Networks Inc. 15

Topology Module

OpenFlow and non-OF networksSwitchClusters – managing OF-islands

Controller sends active probes via packet out/inProbes are formatted to look like LLDPs

ITopologyService interfacegetLinks()addListeners() inSameCluster(switch1, switch2)Set<Switches> getSwitchesInCluster(switch1)

Floodlight Automatically discover topologies

Page 16: Floodlight OpenFlow Contoller - Updated Overview

©2012 – Big Switch Networks Inc. 16

Device Manager Module

Tracks End-Host Locations in the networkMac to ( Switch, Port) mappingMac to IP IP to Mac

IDeviceManager ServiceList<Device> getDevices()addListener()Device getDeviceByIPv4Address(ip)Device getDeviceByDataLayerAddress(mac)

TODO: Extend Device definition, include Vlan?

Host location tracking

Page 17: Floodlight OpenFlow Contoller - Updated Overview

©2012 – Big Switch Networks Inc. 17

REST API Module

Implementation uses Restlets internally www.restlets.org

IRestAPI Service addRestletRoutable(RestletRoutable rr)

Your module implements RestletRoutable String basePath()

“/rest/version1/myMod”

Restlet getRestlet(Context)New Router(context).attach(“/switch/all/{statType}/json”,

MyStatClass.class}

MyStatClass extends org.restlet.resources.ServerResource

Any module can export via REST

Page 18: Floodlight OpenFlow Contoller - Updated Overview

Demo

Page 19: Floodlight OpenFlow Contoller - Updated Overview

©2012 – Big Switch Networks Inc. 19

Demo

Problem:

Track the last N Packet-Ins seen by the controller and expose it via a REST API

What you will see:

1. Adding a new module

2. Creating a REST API

3. Running Floodlight

Page 20: Floodlight OpenFlow Contoller - Updated Overview

Interested in Learning More?

Check out the websitehttp://floodlight.openflowhub.org

Join the mailing list:http://groups.google.com/a/openflowhub.org/group/floodli

ght-dev/topicsOr just email [email protected]

Get the code:http://floodlight.openflowhub.org/download

©2012 – Big Switch Networks Inc.