35
OpenStack が実現する仮想ネットワーク OpenStack Neutron[Icehouse to Juno] Akihiro Motoki (@ritchey98) Jun 12 th , 2014

Neutron Icehouse Update (Japanese)

Embed Size (px)

DESCRIPTION

Interop Tokyo 2014 SDI (Software Defined Infrustructure) ShowCase Seminoar Presentation. The presentation covers Neutron API models (L2/L3 and Advanced Network services), Neutron Icehouse Update and Juno topics.

Citation preview

Page 1: Neutron Icehouse Update (Japanese)

OpenStack が実現する仮想ネットワーク ~OpenStack Neutron~ [Icehouse to Juno]

Akihiro Motoki (@ritchey98)

Jun 12th, 2014

Page 2: Neutron Icehouse Update (Japanese)

自己紹介

• 元木 顕弘 (@ritchey98)

– NEC 情報・ナレッジ研究所 – IPルータ、広域Ethernet装置、迷惑メールフィルタなどの開発をやっていました。

– ここ数年は、ネットワーク仮想化、OpenStack, OpenFlow 周りで活動しています。

• OpenStack Developer

– Neutron and Horizon Core Developer – I18N (国際化) team sub-lead

• Linux JM (日本語マニュアル) Project Maintainer

2013/12/12 Okinawa OpenDays 2013 2

Page 3: Neutron Icehouse Update (Japanese)

Agenda

• Neutron のネットワークモデルと考え方

– Layer2/Layer3

–ネットワークサービスと Service Insertion

• Icehouse Update

• 次リリース Juno でのトピック

• 最近の OpenStack の動き

Page 4: Neutron Icehouse Update (Japanese)

??? Neutron

OpenStack Project と Neutron

Compute

Storage

Network

Nova

Swift (Objects)

Glance (Images)

Cinder (Block)

Identity Keystone

*-as-a-Service Capability OpenStack Service

Page 5: Neutron Icehouse Update (Japanese)

Neutron の目的 #1

• Network-as-a-Service (NaaS) を提供する

–テナントが自由なネットワーク操作を提供

• 複数のプライベートなネットワークの作成

• IPアドレスの制御

–論理ネットワーク操作API

• 論理操作と物理操作を分離

• 物理レイヤーは Neutron (Plugin/Driver) が設定する

Page 6: Neutron Icehouse Update (Japanese)

Neutron の目的 #2

• 複数のネットワーク技術に対応

– データセンタでは新たな要件が発生 • multi tenancy, remote data center, VM mobility, advanced

network services, …

– Nova は VLAN + Linux iptables のみが利用可能

– 新しいネットワーク技術に対応できるアーキテクチャ • SDN/OpenFlow-based network

• Overlay tunneling (VXLAN, NVGRE, STT, …)

• L2 Fabric (Fabric Path, QFabric, …)

Technology/Vendor に依存しない共通 API を提供

Page 7: Neutron Icehouse Update (Japanese)

Neutron の基本NWモデル

TenantA-VM1 10.0.0.2

TenantA-VM3 9.0.0.2

TenantA-VM2 10.0.0.3

External Net

88.0.0.0/18

Tenant-A Net1 10.0.0.0/24

Tenant-A Net2 9.0.0.0/24

L2 virtual network

virtual port

virtual server

virtual interface (VIF)

virtual subnet

SNAT for external traffic Floating IP

• テナントは複数の Network を作成できる • Network には Subnet (CIDR, GW等) を関連付ける。

– 1つのNWに複数のSubnetを関連付けできる。IPv4+IPv6, IPv4 Address pool 等 – IPアドレスの払い出し (IPAM) – テナント間での IP アドレス重複にも対応

• Networkに複数のPort を作成できる。(L2SWのポートのイメージ) – VM の仮想NICはやルータのINF は Port と関連付けられる。

Neutron

Page 8: Neutron Icehouse Update (Japanese)

Network API • API モデルは基本的に REST • 一般ユーザー向けの API では、論理情報のみが見える • 管理者権限であれば、物理情報を指定した操作も一部では定義。

GET http://localhost:9696/v2.0/networks/20b49737-c718-4f10-8edc-7fe9f8ee7cfd { "network": { "admin_state_up": true, "id": "20b49737-c718-4f10-8edc-7fe9f8ee7cfd", "name": "net1", "router:external": false, "shared": false, "status": "ACTIVE", "subnets": [ "644f729f-1c86-48b3-91a2-761e29398e81" ], "tenant_id": "be11ce3cabc74ee68d4f22253ffbb5e8" } }

GET http://localhost:9696/v2.0/networks/20b49737-c718-4f10-8edc-7fe9f8ee7cfd { "network": { "admin_state_up": true, "id": "20b49737-c718-4f10-8edc-7fe9f8ee7cfd", "name": "net1", "router:external": false, "shared": false, "status": "ACTIVE", "subnets": [ "644f729f-1c86-48b3-91a2-761e29398e81" ], "tenant_id": "be11ce3cabc74ee68d4f22253ffbb5e8", "provider:network_type": "vlan", "provider:physical_network": "physnet_1", "provider:segmentation_id": 201 } } 一般ユーザー 管理者ユーザー

Page 9: Neutron Icehouse Update (Japanese)

Advanced Network Service

• ネットワークサービス

– LBaaS, FWaaS, VPNaaS などなど

– L2/L3 のような単純な転送ではないもの

• このような機能を自由に配置したい

– API でクラウドらしく簡単にデプロイしたい

– SDN と相性がよい

Page 10: Neutron Icehouse Update (Japanese)

サービス配置パターン

Network 1

External Network

Network 2

Network 1

FW on network

FW on Port (security group?)

FW on Router

Firewall

Page 11: Neutron Icehouse Update (Japanese)

サービス配置パターン

Load Balancer

Network 1

Network 1

Network 1

Network 2

Direct Return

2-arm LB

1-arm LB

- terminated - Router

Page 12: Neutron Icehouse Update (Japanese)

Network Service Insertion

Network 1 Network 2

External Network

VPN Connection

Service Insertion

Page 13: Neutron Icehouse Update (Japanese)

Neutron API の位置付け

Virtual Network

Virtual Router VM VM VM

Compute API L2/L3 API

Horizon, Heat or Orchestration

LB Service

VM

Process Based LB (HAProxy)

HW Appliance

LBaaS API

OpenStack が提供するのは Abstraction と Integration (≠ Virtualization)

Neutron には L2/L3 API と Advanced Service API が両方存在している。 両者を区別してみると、理解しやすいと思います。

Page 14: Neutron Icehouse Update (Japanese)

Nova

Neutron の基本構造 • API に対応して、物理操作を行う Plugin が存在

– Plugin を切り替えることで、様々なネットワーク技術を利用可能 – 複数のPlugin (Core + Service *N) が併存。一つのPluginで複数のAPIも対応可

• OpenStack の一部だが、Neutron 単体でも利用可能 – Neutron API を使うことで、特定のベンダーAPI に Lock-In されにくくなるかも

Neutron Server Compute Node

VM VM

vSwitch

HW Switch

L2/L3 Plugin FWaaS Plugin

LBaaS Plugin

Agent

L2 API L3 API FWaaS

API LBaaS

API

Network Controller

OpenFlow Controller など

Neutron API

L3 Agent

HAProxy Agent

Compute API

XXX Driver

最近の構造

Page 15: Neutron Icehouse Update (Japanese)

Neutron

OpenStack と SDN の連携

Nova

NEC OpenFlow Plugin Nova Compute

Virtual Switch

VM VM

Nova Compute

Virtual Switch

VM VM

HW Switch

CLI / Dashboard (Horizon) / Orchestration Tool

OpenFlow Controller

Network

OFC API

Neutron API

OpenFlow Protocol

Nova API

agent agent

NEC OpenFlow OpenDaylight

Page 16: Neutron Icehouse Update (Japanese)

Neutron

OpenStack と SDN の連携

Nova

ML2 Plugin

(OpenFlow Agent) Nova Compute

Virtual Switch

VM VM

Nova Compute

Virtual Switch

VM VM

HW Switch

CLI / Dashboard (Horizon) / Orchestration Tool

Compute Node にそれぞれ OpenFlow Controller を載せる例もある

Neutron API

OpenFlow Protocol

Nova API

agent agent

OpenFlow Controller

OpenFlow Controller

Ryu

Page 17: Neutron Icehouse Update (Japanese)

Neutron ML2 Plugin

• ML2 = Modular Layer 2 – 複数のプラグインを統合する目的で開発 – デフォルトの Reference Implementation となり、OVS / Linux Bridge plugin は今後削除される。

– 複数のネットワーク技術を同時に使えるようになる予定 – Type Driver と Mechanism Driver の2種類のドライバー

• Type Driver – ネットワーク種別に応じたリソースの管理を行う。VLAN の ID 払い出しなど。 – ネットワーク種別は、ネットワーク作成時に provider_network extension の

network_type で指定する – VLAN, VXLAN, GRE, Local, Flat

• Mechanism Driver – 実際のデバイスの操作を行う。複数の mechanism driver を同時に有効にできる (ordered list)。各 mechanism driver は自分が対応しているネットワーク種別であれば処理を行う。

– Open vSwitch agent driver, Linux Bridge agent driver, Hyper-V agent driver – Cisco Nexus 1000V driver, Arista driver, ….. – L2 population driver

• MAC アドレス情報を OVS に展開し、ブロードキャストを削減する

OVS/Linux Bridge Plugin の機能は凍結。機能追加はML2 Plugin に対して行われる。ML2 に移行しましょう

Page 18: Neutron Icehouse Update (Japanese)

Icehouse Update

• 性能、安定性の向上が中心 – Multiple API worker / RPC worker – Improvements in dhcp-agent, l3-agent, OVS agent … – Scenario test / API test coverage in tempest – Third party testing (vendor driver testing)

• nova event callback – Notify nova of port status changes when fixed_ips/floatingips change – It ensure a VM is launched after network connection is available.

• Deprecate OVS Plugin and Linux Bridge plugin – Migration to ML2 plugin is recommended.

• 機能面の変更は少なめ

– これまでの機能追加中心だったが、一度立ち止まって底上げ – 次の機能追加に向けた充電期間と考えるべき

Key New Features During Icehouse cycle the team focused on stability and testing of the Neutron codebase. Many of the existing plugins and drivers were revised to address known performance and stability issues.

Icehouse Release Notes

Page 19: Neutron Icehouse Update (Japanese)

Multiple API/RPC Worker

Neutron server

Message queue

OVS agent

Dhcp agent

l3-agent

OVS agent

Dhcp agent

l3-agent

OVS agent

Dhcp agent

l3-agent

DB

RPC worker

Message queue

OVS agent

Dhcp agent

l3-agent

OVS agent

Dhcp agent

l3-agent

OVS agent

Dhcp agent

l3-agent

DB RPC

worker RPC

worker

API worker

API worker

API worker

API request

RPC message

https://www.openstack.org/assets/presentation-media/junohpneutronatscalefinal.pdf

Page 20: Neutron Icehouse Update (Japanese)

Compute host

VM

Nova event callbacks • Neutron のポートの状態変更を Nova に通知する仕組み • Nova 側では、確実に、ネットワーク接続の準備が整ってから VM 起動を行えるようになる。 – これまでは、Nova は Neutron ポートを作成すると、状態を確認せずに VM 起動を行っていたので、DHCP の IP アドレス割り当て等に失敗することがあった。

nova-compute

VM

OVS

VIF

Neutron Server

OVS agent

(1) Create Port

(2) Tap-dev作成

Network

(3) ネットワーク接続準備

(4) 準備完了通知

(5) Notify Nova

(6) VM Launch

Dhcp server

Neutronから通知があるまで待つ

Page 21: Neutron Icehouse Update (Japanese)

Vendor Plugin/Driver Testing • Vendor Plugin/Driver についても、パッチ投稿の度にシナリオテスト・APIテストを行って結果をレポートすることが必須に。

• テストケースは OpenStack Community で開発したものを実行。 • これまではどこまでテストされているか分からなかった。

http://www.rcbops.com/gerrit/reports/neutron-cireport.html

Page 22: Neutron Icehouse Update (Japanese)

Neutron Icehouse update detail (1/2)

• Main Focuses are “Stabilization” and “Test Coverage” (rather than new features) – Scenario and API test coverage in tempest – Enable parallel testing on tempest

• Nova-Network Feature Parity – Nova-network feature parity towards deprecating nova-network – A lot of progresses but the completion will be Juno (or later)

• Nova Integration : nova-event-callback – Notify nova of port status changes when fixed_ips/floatingips change – It ensure a VM is launched after network connection is available.

• ML2 (Modular Layer2) plugin – Add support for vnic type request to be managed by ML2 mechanism drivers

• Allows nova to request vnic type for a port : normal, direct (pass-through), macvtap

– Implement the binding:profile port attribute in ML2 – Extensible port attribute for plugin to provide details to VIF driver – Migration from OVS / linux bridge plugin to ML2

• Provide a tool to migration DB data from deprecated plugins to ML2.

• L3 : Operational Status for Floating IPs • Advanced Network Services (LBaaS, VPNaaS, FWaaS)

– No major features – Some vendor drivers: Radware/Embrane (LBaaS), Cisco (VPNaaS)

Page 23: Neutron Icehouse Update (Japanese)

Neutron Icehouse update detail (2/2)

• New ML2 mechanism drivers – OpenDayLight plugin (It works with Hydrogen ODL release) – OpenFlow agent (ryu) driver (OpenFlow controller per compute node) – Big Switch, Mellanox, Brocade

• New plugins : IBM SDN-VE, Nuage, OneConvergence • Existing plugins:

– BigSwtich (async ope, secgroup, resync with backend) – Vmware NSX (renamed from Nicira NVP plugin), Plumgrid (provider network) – NEC plugin : packet filter extension support for PFC

• Items deferred to Juno ….

– IPv6 related attributes to control IPv6 RA and address assignments (ipv6-two-attributes) • API layer is defined but backend implementation is not merged.

– Layer 3 HA • L3-agent HA • Distributed Virtual Router (with OVS)

– Advanced Network Service “flavor” support – Advanced service in VM – and so on

Page 24: Neutron Icehouse Update (Japanese)

Neutron topics in “Juno” • Migration from “nova-network”

– OpenStack には nova-network と neutron の二つのネットワーク機能が存在するが、将来的には neutron に統合されることは合意ができている。

– nova-network との機能互換性の実現 – nova-network からの運用環境での移行サポート

• Network/Port/ Security Group などのデータの nova から neutron への移行 • D-Plane トラフィックはダウンさせずに移行する方法が検討中。

TCP セッションが切れないレベルが当面の目標。 • API の停止は伴う見込み。

– Weekly Meeting でもステータスを確認中

• Distributed Virtual Router (DVR) • L3-agent HA • IPv6 full support • Baremetal (Ironic) Integration

– Multi Tenant isolation with baremetal instance

Page 25: Neutron Icehouse Update (Japanese)

Neutron topics in “Juno” • Distributed Virtual Router with Open vSwitch

– 現在は OSS 実装では、仮想ルーターをまたぐトラフィックは必ず l3-agent が動作するノードを経由

– Compute Node で動作する分散ルータを OVS ベースで実装 – nova-network の multi_host 機能 (ネットワークの HA 方法) の代替と期待されている。

Page 26: Neutron Icehouse Update (Japanese)

Neutron topics in “Juno” Network Services • Flavor Framework

– 複数の Load Balancer のサービスレベル、実装などを選択可能にする仕組み。サービス品質に応じて、物理アプライアンス、仮想アプライアンスなどを使い分けることが可能になる。

• Service Insertion / Service Chaining • Traffic Steering

– L2 Transparent な Network Service を実現するため、条件にマッチしたトラフィックを特定のポートに Redirect する仕組みを提案

• Group Policy Framework

Page 27: Neutron Icehouse Update (Japanese)

Neutron topics in “Juno” Network Services • Service VM

– VM でネットワーク機能を実現する枠組み – Service VM 自体は Neutron/Nova など複数プロジェクトにまたがるため、独立したプロジェクト (stackforge) で進めることになった。

– Service VM を実現する上での Neutron に必要機能を整理し、Neutron 側と連携して実装していく。 • Disabling Security Group / Anti-spoofing rule • Trunk VLAN support for VM port • Traffic Steering • ….

– https://etherpad.openstack.org/p/servicevm

Page 28: Neutron Icehouse Update (Japanese)

最近のトピック

• NFV Sub-team

• Cross-Project design summit session

• Ops-Dev Meetup

• Blueprint Spec Review

Page 29: Neutron Icehouse Update (Japanese)

Slide Backup

Page 30: Neutron Icehouse Update (Japanese)

Neutron の機能ブロック • Neutron Server

– 論理ネットワークの管理を行う – Plugin は Neutron Server の一部

• Agent – Neutron Server 以外のサービスプロセス。Neutron Server 以外のサーバでも動作可能。

– Plugin の実現方式に応じて、必要に応じて使用する。 実現方式によっては Agent は不要。

• Agent

– Plugin Agent • 仮想スイッチの情報取得、設定を行う

– DHCP Agent • 仮想ネットワーク単位のDHCPサーバの管理を行う

– L3 Agent • 論理ルータの操作を行う。論理ルータは、iptables を利用して実現

– Metadata Agent • Neutron 環境において Metadata サーバへのアクセスを Nova metadata server にプロキシーする。

Page 31: Neutron Icehouse Update (Japanese)

Nova(CC)

Neutron Server

Compute Node

Compute Node

Data Network

eth1 eth1

eth0 eth0 eth0

OVS (br-int)

OVS (br-int)

Nova Compute

Nova Compute

Plugin Agent Plugin Agent

Management Network

Neutron の機能ブロックと配置

Controller Node

eth0

eth1

OVS (br-int)

DHCP agent

L3 agent

Plugin Agent

OVS (br-ex)

Network Node

eth2

External network

metadata agt

Page 32: Neutron Icehouse Update (Japanese)

Neutron

Nova

Neutron Plugin

Nova Compute

Virtual Switch

VM VM

Nova Compute

Virtual Switch

VM VM

HW Switch

CLI / Dashboard (Horizon) / Orchestration Tool

Physical Network

Neutron API Nova API

agent agent

Page 33: Neutron Icehouse Update (Japanese)

LBaaS • Grizzly で追加

– LBaaS API (tenant API) 策定 – HAProxy reference implementation のみ

• Havana – Service Type Framework

• Backend が指定可能に。複数のドライバーを選択して LB pool を作成できる

– Vendor Driver, LB Plugin の追加

• Icehouse – Multiple VIPs per pool, VIP の pool 間での移動 – Layer7 support – SSL termination – Routed Service Insertion (LVS based) ? – https://etherpad.openstack.org/p/icehouse-neutron-lbaas

Page 34: Neutron Icehouse Update (Japanese)

FWaaS • Havana で追加

– Horizon, Heat support – FWaaS API (rule, policy, firewall resource) – L3-agent based impl, some vendor plugin – 制限事項

• 1 firewall per tenant (with l3-agent) • Firewall applies to all routers

• Icehouse – Service Insertion/Service Type Framework – Zone – Apply Operation – Counters – https://etherpad.openstack.org/p/icehouse-neutron-fwaas

Page 35: Neutron Icehouse Update (Japanese)

VPNaaS

• Havana で追加 – IPSec VPN (L3 VPN) のみサポート – Horizon, Heat support

• Icehouse – Service Type Framework

• 複数種類のVPNのサポート

– SSL-VPN – IPSec Certification Support – MPLS/BGP – (L2-VPN?) – https://etherpad.openstack.org/p/NeutronVPNaaSIce

House