exposing ovs statistics for q uantum users tomer shani 19.6.13 advanced topics in storage systems...
TRANSCRIPT
![Page 1: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/1.jpg)
EXPOSING OVS STATISTICS FOR QUANTUM USERS
Tomer Shani19.6.13
Advanced Topics in Storage Systems
Spring 2013
![Page 2: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/2.jpg)
Project goals
• In order to develop QoS for the cloud environment it is necessary to collect network statistics from the different network element.
• This project aims to expose network statistics from the “open virtual switch” so that further functionality can be added to the open stack environment.
![Page 3: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/3.jpg)
Theoretical Overview
• OpenStack Quantum• Quantum Plugin Architecture• Open Virtual Switch• Proposed Solution
![Page 4: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/4.jpg)
Quantum• Introduced as part of OpenStack Folsom release
(sept 2012)• Provides Network as a Service between interface
devices managed by other OpenStack services (most likely Nova).
• Allows users to create their own networks / network services and then attach interfaces to them.
• Quantum has a pluggable architecture to support many popular networking vendors and technologies.
![Page 5: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/5.jpg)
Quantum – the big picture
![Page 6: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/6.jpg)
Quantum – the details
![Page 7: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/7.jpg)
• Quantum server – implements the RESTful API and routes requests to the correct plugin-in
• API abstractions:– Network: layer 2 network object,
attributes: admin state, name & subnets.– Subnet: layer 3 network object, attributes:
admin state, name, ip addr, subnet mask, dhcp, dns …– Port: NIC object, attributes:
network, device (virtual server), mac addr …
Quantum plugin architecture
![Page 8: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/8.jpg)
Quantum plugin architecture• Plugin will typically update the
quantum database• Plugin agent runs on each compute
node, the agent gathers the configuration from the database and communicates directly with the local OVS instance.
• Quantum also provides an “extensibility” mechanism that enables extension of the Core API (resource/attribute/action)
• Quantum client - a command line API for accessing quantum functionality
![Page 9: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/9.jpg)
Open virtual switch• OVS components (www.openvswitch.org):
– Kernel module implementing the data path– User space daemon “ovs-vswitchd” implementing the flow logic layer– User space daemon “ovsdb-server” which holds switch configuration– User space utilities, ovs-ofctl is the OpenFlow switch management
utility which also provides port statistics
![Page 10: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/10.jpg)
Open virtual switch
• Available counters– Rx packets– Rx bytes– Rx drop– Rx errors– Rx crc errors– Rx frame– Rx overruns
– Tx packets– Tx bytes– Tx drop– Tx errors– Tx collisions
![Page 11: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/11.jpg)
Design
Quantum
OVS plugin API
DB
Compute node
OVS instance
Core Utilities vswitchd ovs-ofctl db-server ovs-dpctl ovs_mod.ko ovs-appctl
CLI client
OVSPlugin agent
![Page 12: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/12.jpg)
Design options - discussion
Pros• Data is retrieved as needed,
no constant access to database (saves network bandwidth)
• Data is (close to) “real-time” which may be critical for some applications
Cons• Plugin has longer access
time when compared to local database access.
• If multiple applications require the statistics, traffic is duplicate.
• No “natural” path for providing real-time data on request
• Should plugin-agent be polled or push data• Pros & Cons of “polling solution”
![Page 13: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/13.jpg)
Hands on overview
• Setting up a work environment• Installing OpenStack• Configuring OpenStack • Creating a Cloud
![Page 14: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/14.jpg)
Setting up a work environment
• First attempt: Dual 3 Ghz cores, 2 GB RAM, Ubuntu 12.10 Desktop, SLOW…..
• Second attempt: switched to server installation (no GUI), still sluggish..
• Third attempt: 8 * 3.4 Ghz cores, 4 GB RAM, much better
• Installed SMB to provide remote access to file system (coding).
• Enabled SSH to provide shell access.
![Page 15: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/15.jpg)
Installing OpenStack
• Installed by utilizing Devstack, a shell script to build complete OpenStack development environments. – git clone https://
github.com/openstack-dev/devstack.git (have to install git first)
– cd devstack && ./stack.sh--------------------------------------------------------------------Horizon is now available at http://10.4.2.45/Keystone is serving at http://10.4.2.45:5000/v2.0/Examples on using novaclient command line is in exercise.shThe default users are: admin and demoThe password: 123456--------------------------------------------------------------------
![Page 16: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/16.jpg)
Configuring OpenStack
• Now that we have access to the web server, we can start configuring a virtual networkBut that would be too easy…
• Default devstack installation configures nova networking (pre-quantum days)
• Modify localrc to enable quantum and run devstack again
tomers@ubuntu:~$ cat /opt/stack/devstack/localrc disable_service n-net…..enable_service quantum
![Page 17: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/17.jpg)
And finally
![Page 18: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/18.jpg)
Creating a network
![Page 19: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/19.jpg)
Add a virtual host
![Page 20: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/20.jpg)
Add a virtual host - cont.
![Page 21: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/21.jpg)
And we have a network
![Page 22: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/22.jpg)
Network objects
![Page 23: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/23.jpg)
Quantum client
![Page 24: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/24.jpg)
Generating traffic
![Page 25: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/25.jpg)
It works !
![Page 26: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/26.jpg)
Resources
• Openstackwww.openstack.org
• Devstackhttp://devstack.org/
• Openstack dcumentationhttp://docs.openstack.org/
• Open vSwitchhttp://openvswitch.org/
![Page 27: EXPOSING OVS STATISTICS FOR Q UANTUM USERS Tomer Shani 19.6.13 Advanced Topics in Storage Systems Spring 2013](https://reader036.vdocuments.us/reader036/viewer/2022070413/5697bf991a28abf838c91cc3/html5/thumbnails/27.jpg)
QUESTIONS?