SlideShare a Scribd company logo
1 of 28
Demystifying OpenVswitch
Start your SDN journey today!
Prasad Mukhedkar
Emerging Technologies Group, Red Hat.
pmukhedk@redhat.com
Objectives and Takeways
Session Objectives :
● High level overveiw of SDN Concepts and introduction of OpenvSwitch,
● Understand how to use OpenVswitch with KVM Virtualization
● Various OpenvSwitch Features with Demo
● SDN - OpenFlow
● SDN Controller (opendaylight project)
Key Takeways :
● Getting familiar with openvswitch and its cli utilities
● When to use which Feature of OpenvSwitch.
● Creating vlans for your TestBeds (KVM).
● Opendaylight controller and OpenFlow
What is SDN? Software Defined Network?
● Separation of the control from the forwarding plane.
● Software programmability for network elements.
● Centralized network control and management .
The control plane is where forwarding/routing decisions are made (Software Logic)
The data plane is where the data forwarding action takes place. (instructions to carry traffic
over hardware )
The SDN architecture decouples the network control and forwarding functions
enabling the network control to become directly programmable and the underlying
infrastructure to be abstracted for the applications and network service.
10000 foot view of SDN Approach
Notice how control and data planes are separated and how this separation helps applications to directly
controls network opening doors for innovation.
Network Infrastructure - This consists the network devices such as
routers and switches, Both physical as well as virtual.
Controller - This encompass the software based on a centralized
controller which could be on a server that talks to all the devices in
the network using open API’s, Like OpenFlow or OVMDB.
Applications : This encompasses the variety of application for which
the network exists. This includes voice, video, enterprise
applications, security appliances such as intrusion detection. These
application can to the controller using open API’s to give them what
they want. For example, Voice traffic may ask the controller to have it
treated with least latency while an enterprise backup server may tell
the controller to give it bandwith whenever it is available.
Limitations of Linux Bridge
Guest (VM) networking in KVM has traditionally been done using linux, It is simple to
configure and manage but is not originally designed for virtual networking and
therefore poses integration and management challenges.
Linux Bridge
An unmanaged software switch !
Robust, Does packet forwarding job very well.
Fast, simple to use, No complexity
Linux Bridge's “root cause problem”
It is Closed for Innovations!
What is OpenvSwitch?
OpenvSwitch is an open source openflow capable virtual switch. If you’re familiar
with VMware, think of it as an open source Distributed
● Flexible Control in user-space with comprehensive management tools
● Fast Datapath (forwarding plane) in kernel
● Adopted in base kernel, since version 3.3
● Open vSwitch was included since RHEL 6 .4 (only datapath, no Control).
● Any netdevice (physical/virtual) can be added as uplink port
OpenvSwitch Architecture
The data path (ovs kernel module) uses netlink socket to interacts with vswitchd daemon that implements
and manages any number ovs switches on local system, SDN Controller interacts with vswitchd using
openflow protocol. The ovsdb-server maintains the switch table database and external clients can talk to
ovsdb-server using json rpc and json being the data format. ovsdb database currently contains around 13
tables and this database is persistent across restarts.
Openvswitch installation
Starting with Fedora 16 the openvswitch user space tools and the
required kernel modules are included in the Fedora distribution.
# sudo dnf install openvswitch
openvswitch package contains all the required user space tools
including the ovsdb and series of command line utilities to
configure, monitor and manage open vswitch instances.
Following are the important configuration files of openvswitch.
RHEL 7 and later (Need openstack or openshift channel)
#rpm -qc openvswitch
/etc/logrotate.d/openvswitch
/etc/openvswitch/conf.db
/etc/openvswitch/system-id.conf
/etc/sysconfig/openvswitch
Starting up the openvswitch service
The Openvswitch.service is comprised by two daemons. One is a database and
another is the switch itself.
#/bin/systemctl start openvswitch.service
#systemctl enable openvswitch.service
1. Kernel module gets loaded. module name is "openvswitch"
#modinfo openvswitch
filename: /lib/modules/4.1.6-200.fc22.x86_64/kernel/net/openvswitch/openvswitch.ko.xz
license: GPL
description: Open vSwitch switching datapath
2. Database is created. copied
/usr/share/openvswitch/vswitch.ovsschema
/etc/openvswitch/conf.db
Openvswitch command-line interfaces
#ovs-vsctl - This command is used to set up, maintain, and inspect various ovs switch
configurations. It provides a high level interface for Open vSwitch Database to query and apply
changes on runtime.
#ovs-ofctl and ovs-dpctl - These two commands are used for administering and monitoring
flow entries. You learned that OVS manages two kinds of flow.
OpenFlows - The flows managed at control plane.
Datapath - Kernel flow. A kind of cached version of the OpenFlow.
ovs-ofctl - speaks to OpenFlow module whereas ovs-dpctl - speaks to Kernel module. Following
two are most used options of each of these commands
ovs-appctl - This command offer a way to send commands to a running Open vSwitch and
gather information that is not directly exposed to ovs-ofctl command. This is swiss army knife of
openflow troubleshooting.
Setting up your first openvswitch bridge
Multiple ways to Setup/Configure .
- The ovs-vsctl is the primary command to create, remove and administer openvswitch. The
operation performed using ovs-vsctl are persistent across system reboot.
[root@kvmHOST1 ~]# ovs-vsctl add-br vswitch001
[root@kvmHOST1 ~]# ovs-vsctl show
- Configuring a openvswitch bridge using network scripts.
[root@kvmHOST1]cat /etc/sysconfig/network-scripts/ifcfg- vswitch002
DEVICE="vswitch002"
BOOTPROTO="dhcp"
DEFROUTE="yes"
IPV4_FAILURE_FATAL="yes"
IPV6INIT=no
ONBOOT="yes"
TYPE="OVSBridge"
DEVICETYPE="ovs" Doc on ifcfg directives for openvswitch
/usr/share/doc/openvswitch/README.RHEL
Integrating KVM VMs and OVS
Edit VM XML Configuration
#virsh edit vm-name
<interface type='bridge'>
<mac address='52:54:00:ce:51:53''/>
<source bridge=vswitch001/>
<virtualport type='openvswitch'/>
<target dev=<vm001_vp01>
<model type='virtio'/>
</interface>
Libvirt Network Pool
#cat ovs-network.xml
<network>
<name>NewNetwork</name>
<forward mode='bridge'/>
<bridge name='vswitch1'/>
<virtualport type='openvswitch'/>
</network>
virsh net-define ovs-network.xml
Network vswitch-net defined from ovs-network.xml
# virsh net-start vswitch-net
Network vswitch-net started
A quick method!
#virt-xml vm_01 --edit --network
virtualport_type='openvswitch',source=vswitch001
,target=vm001_vp01
Feature 1 : Security / L2 Segregation
VLAN isolation enforces VLAN membership of a VM without the knowledge of the guest itself.
VLan1 :
[root@kvmHOST1 ~]# ovs-vsctl set port fed1 tag=10
[root@kvmHOST1 ~]# ovs-vsctl set port fed2 tag=10
vLan2:
[root@kvmHOST1 ~]# ovs-vsctl set port fed3 tag=20
[root@kvmHOST1 ~]# ovs-vsctl set port fed4 tag=20
#ovs-vsctl set port fed1 trunks=20,30,40
Monitor
#ovsdb-client monitor Port name,trunks --
detach
The default, vlan_mode used is "access", Its native mechanism of the vlan. VLAN Tag
is added when packets enter a Access port, and stripped off when leave a access port.
Other vlan_mode are native−tagged, native−untagged and trunk
libvirt Integration
<portgroup name='novlan' default='yes'>
</portgroup>
<portgroup name='vlan-finance'>
<vlan>
<vlan-mode=native-tagged>
<tag id='10'/>
</vlan>
</portgroup>
<portgroup name='vlan-marketing'>
<vlan trunk='yes'>
<tag id='20'/>
<tag id='30'/>
<tag id='30'/>
</vlan>
</portgroup>
portgroup feature of libvirt provides a method of easily putting guest connections to the network into different
classes, with each class potentially having a different level/type of service.
Feature 2 : Overlay Networks
Overlay Networks are industry standard techniques designed achieve Network Virtualization.
Network Overlays such as Virtual eXtensible Local Area Network a(VXLAN) and Generic Routing
Encapsulation (GRE) achieve network virtualization by overlaying layer 2 networks over physical
layer 3 networks which enable network scalability and efficient use of current network
infrastructure.
Openvswitch supports multiple tunneling protocols (GRE, VXLAN, STT, and Geneve, with
IPsec support)
vm1 vm2
10.0.0.1 vxLan tunnle 10.0.0.2
overway N/W
| |
kvmhost1 kvmhost2
192.168.1.10 underlay N/W 192.168.2.20
Configuring Overlay Networks
Host1
#ovs-vsctl add-port vswitch vxlan1 -- set interface vxlan1 type=vxlan options:remote_ip=192.168.1.20
Host2
#ovs-vsctl add-port vswitch vxlan1 -- set interface vxlan2 type=vxlan options:remote_ip=192.168.1.10
Other options : local_ip, in_key, out_key,tos,ttl
Feature 3 : QoS
The network QoS (quality of service) QoS refers to the ability of the network to handle
it traffic such that it meets the service needs of certain applications. It is often used as
a synonym for traffic control.
QoS Policing - Rate Limiting
Qos Shaping - Dedicated Queue
Input(inbound) and output(outbound) traffic
Feature 3 : QoS Configuration
Shaping
Create a queue(q0) with required network
bandwidth. Here in this example I am limiting the
egress traffic bandwidth to 10 MBps.
Create a Queue
#ovs-vsctl --id=@q0 create queue other-config:min-
rate=100000 other-config:max-rate=100000
Create Qos
#ovs-vsctl create qos type=linux-htb
queues=0=05c73c42-3191-4025-96ce-
cd6b86ab2775
Add Qos to a port
#ovs-vsctl set port vent0 qos= 09f5b3c4-
35b7-4326-bae8-780b7ccadb3f
Policing
To apply QoS on a VM to control its inbound traffic, Modify its
interface table to configure an ingress policing rule.
There are two rules to set:
ingress_policing_rate: The maximum rate
(in Kbps) that this VM should be allowed to send.
ingress_policing_burst: A parameter to the
policing algorithm to indicate the maximum amount
of data (in Kb) that this interface can send
beyond the policing rate.
ovs-vsctl set interface fed1 ingress_policing_rate=20000
ovs-vsctl set interface fed1 ingress_policing_burst=200
Feature 4 : Port Mirroring
OpenVswitch support port mirroring features out of the box, This feature is exactly
similar to the port mirroring capability available on the new generation physical
switches. With Port Mirroring Network administrator can get an insight on what kind of
traffic is flowing on the network.
#ovs-vsctl -- --id=@m create mirror name=M1 -- add bridge vswitch001 mirrors @m
$ovs-vsctl set port fed1 -- set mirror M1 select_src_port=@fed1 select_dst_port=@fed2
select_dst_port = Ports on which incoming packets are selected for
select_src_port = Ports on which outgoing packets are selected for mirroring.
select_all = Its boolean, when to true. every packet incoming or outgoing
on any port connected to bridge will be mirrored.
output_port = specify to which port we want to send this mirrored traffic
Feature 4 : Port Mirroring
SPAN (Switched Port Analyzer)
#ip link add dummy0 type dummy
# ovs-vsctl -- --id=@dummy0 get port dummy0 -- set mirror mymirror select_all=true
output-port=@dummy0
SDN Controllers
An SDN controller is an application in software-defined networking (SDN) that manages flow control to enable intelligent
networking.
Flow table is managed by a remote SDN controller, You can install or remove control
flows using the SDN controller connected to the bridge
Managing Openvswitch via a SDN Controller
By connecting an openvswitch to SDN controller, We get level of abstraction and
automation required to revolutionize networking.
#ovs-vsctl set-controller vswitch0 tcp:192.168.1.20:6633
More about openflow
OpenFlow allows creating powerful L2-L4 service insertion, A flow contains entries that
matches packets and apply actions that may include packet forwarding, packet
modification and others.
Basically rules are used to create expression, If expression matches, The defined Action is
applied.
Flow example
Example : 1
cookie=0x0, duration=14.604s, table=0, n_packets=61, n_bytes=7418,
idle_timeout=10, hard_timeout=30,tcp, vlan_tci=0x0000, dl_src=52:54:00:CE:51:52,
dl_dst=52:54:00:CE:51:53, nw_src=10.0.0.1, nw_dst=10.0.0.2, nw_tos=0, tp_src=22,
tp_dst=554 actions=output:1
Example 2 :
Where can I learn more about flow ? https://flowsim.flowgrammable.org/
OpenVswitch Troubleshooting
- openvswitch Services Log files :
/var/log/openvswitch/ovs-vswitchd.log
/var/log/openvswitch/ovsdb-server.log
- VLOG : OpenvSwitch has a built-in logging mechanism called VLOG. The VLOG
facility expose deep internal information of various components. First Determine at
what level your problem is occurring, Is it Bonding problem?
#ovs-appctl vlog/list
ovs-appctl vlog/list | grep -i bond
- Verbosity of logging supported are (must be: emer, err, warn, info, or dbg),
#ovs-appctl vlog/set module[:facility[:level]]
OpenVswitch Troubleshooting
-
ovsdb-client utility to query the ovs database
Tables : #ovsdb-client list-tables
Bridge, Queue,QoS,Port, Interface
# "ovsdb-client list-columns <table_name>" Prints columns in a particular table, There
are many columns in each table.
ovsdb-client monitor <table_name> <cloumn_name> --detach
- Some other handy tools
#ovsdb-tool showlog" to see data inserted into ovsdb, its openvswitch configuration
#ovs-vsctl --format=table --column=name,vlan_mode
OpenVswitch Troubleshooting
"Show My Network State" is good utility to get graphically display of the virtual/physical
network topology inside a single host. The tools is available here for download,
https://sites.google.com/site/showmynetworkstate/
Questions?

More Related Content

What's hot

Introduction of OpenStack cascading solution
Introduction of OpenStack cascading solutionIntroduction of OpenStack cascading solution
Introduction of OpenStack cascading solutionJoe Huang
 
NFV for beginners
NFV for beginnersNFV for beginners
NFV for beginnersDave Neary
 
Proxmox Clustering with CEPH
Proxmox Clustering with CEPHProxmox Clustering with CEPH
Proxmox Clustering with CEPHFahadIbrar5
 
Meshing OpenStack and Bare Metal Networks with EVPN - David Iles, Mellanox Te...
Meshing OpenStack and Bare Metal Networks with EVPN - David Iles, Mellanox Te...Meshing OpenStack and Bare Metal Networks with EVPN - David Iles, Mellanox Te...
Meshing OpenStack and Bare Metal Networks with EVPN - David Iles, Mellanox Te...OpenStack
 
Introduction to OpenFlow
Introduction to OpenFlowIntroduction to OpenFlow
Introduction to OpenFlowrjain51
 
[오픈소스컨설팅]오픈스택에 대하여
[오픈소스컨설팅]오픈스택에 대하여[오픈소스컨설팅]오픈스택에 대하여
[오픈소스컨설팅]오픈스택에 대하여Ji-Woong Choi
 
[OpenStack] 공개 소프트웨어 오픈스택 입문 & 파헤치기
[OpenStack] 공개 소프트웨어 오픈스택 입문 & 파헤치기[OpenStack] 공개 소프트웨어 오픈스택 입문 & 파헤치기
[OpenStack] 공개 소프트웨어 오픈스택 입문 & 파헤치기Ian Choi
 
OpenStack Networking
OpenStack NetworkingOpenStack Networking
OpenStack NetworkingIlya Shakhat
 
오픈스택 기반 클라우드 서비스 구축 방안 및 사례
오픈스택 기반 클라우드 서비스 구축 방안 및 사례오픈스택 기반 클라우드 서비스 구축 방안 및 사례
오픈스택 기반 클라우드 서비스 구축 방안 및 사례SONG INSEOB
 
Deploying IPv6 in OpenStack Environments
Deploying IPv6 in OpenStack EnvironmentsDeploying IPv6 in OpenStack Environments
Deploying IPv6 in OpenStack EnvironmentsShannon McFarland
 
[오픈소스컨설팅] Open Stack Ceph, Neutron, HA, Multi-Region
[오픈소스컨설팅] Open Stack Ceph, Neutron, HA, Multi-Region[오픈소스컨설팅] Open Stack Ceph, Neutron, HA, Multi-Region
[오픈소스컨설팅] Open Stack Ceph, Neutron, HA, Multi-RegionJi-Woong Choi
 
The Basic Introduction of Open vSwitch
The Basic Introduction of Open vSwitchThe Basic Introduction of Open vSwitch
The Basic Introduction of Open vSwitchTe-Yen Liu
 
OpenStack을 중심으로 한 오픈 소스 & 상용 하이브리드 클라우드
OpenStack을 중심으로 한 오픈 소스 & 상용 하이브리드 클라우드OpenStack을 중심으로 한 오픈 소스 & 상용 하이브리드 클라우드
OpenStack을 중심으로 한 오픈 소스 & 상용 하이브리드 클라우드Ian Choi
 
Vxlan deep dive session rev0.5 final
Vxlan deep dive session rev0.5   finalVxlan deep dive session rev0.5   final
Vxlan deep dive session rev0.5 finalKwonSun Bae
 
OpenFlow tutorial
OpenFlow tutorialOpenFlow tutorial
OpenFlow tutorialopenflow
 
Packet flow on openstack
Packet flow on openstackPacket flow on openstack
Packet flow on openstackAchhar Kalia
 
오픈스택 멀티노드 설치 후기
오픈스택 멀티노드 설치 후기오픈스택 멀티노드 설치 후기
오픈스택 멀티노드 설치 후기영우 김
 
Building DataCenter networks with VXLAN BGP-EVPN
Building DataCenter networks with VXLAN BGP-EVPNBuilding DataCenter networks with VXLAN BGP-EVPN
Building DataCenter networks with VXLAN BGP-EVPNCisco Canada
 

What's hot (20)

Meetup 23 - 02 - OVN - The future of networking in OpenStack
Meetup 23 - 02 - OVN - The future of networking in OpenStackMeetup 23 - 02 - OVN - The future of networking in OpenStack
Meetup 23 - 02 - OVN - The future of networking in OpenStack
 
Introduction of OpenStack cascading solution
Introduction of OpenStack cascading solutionIntroduction of OpenStack cascading solution
Introduction of OpenStack cascading solution
 
NFV for beginners
NFV for beginnersNFV for beginners
NFV for beginners
 
Proxmox Clustering with CEPH
Proxmox Clustering with CEPHProxmox Clustering with CEPH
Proxmox Clustering with CEPH
 
Meshing OpenStack and Bare Metal Networks with EVPN - David Iles, Mellanox Te...
Meshing OpenStack and Bare Metal Networks with EVPN - David Iles, Mellanox Te...Meshing OpenStack and Bare Metal Networks with EVPN - David Iles, Mellanox Te...
Meshing OpenStack and Bare Metal Networks with EVPN - David Iles, Mellanox Te...
 
Introduction to OpenFlow
Introduction to OpenFlowIntroduction to OpenFlow
Introduction to OpenFlow
 
[오픈소스컨설팅]오픈스택에 대하여
[오픈소스컨설팅]오픈스택에 대하여[오픈소스컨설팅]오픈스택에 대하여
[오픈소스컨설팅]오픈스택에 대하여
 
[OpenStack] 공개 소프트웨어 오픈스택 입문 & 파헤치기
[OpenStack] 공개 소프트웨어 오픈스택 입문 & 파헤치기[OpenStack] 공개 소프트웨어 오픈스택 입문 & 파헤치기
[OpenStack] 공개 소프트웨어 오픈스택 입문 & 파헤치기
 
OpenStack Networking
OpenStack NetworkingOpenStack Networking
OpenStack Networking
 
오픈스택 기반 클라우드 서비스 구축 방안 및 사례
오픈스택 기반 클라우드 서비스 구축 방안 및 사례오픈스택 기반 클라우드 서비스 구축 방안 및 사례
오픈스택 기반 클라우드 서비스 구축 방안 및 사례
 
Aruba Mobility Controllers
Aruba Mobility ControllersAruba Mobility Controllers
Aruba Mobility Controllers
 
Deploying IPv6 in OpenStack Environments
Deploying IPv6 in OpenStack EnvironmentsDeploying IPv6 in OpenStack Environments
Deploying IPv6 in OpenStack Environments
 
[오픈소스컨설팅] Open Stack Ceph, Neutron, HA, Multi-Region
[오픈소스컨설팅] Open Stack Ceph, Neutron, HA, Multi-Region[오픈소스컨설팅] Open Stack Ceph, Neutron, HA, Multi-Region
[오픈소스컨설팅] Open Stack Ceph, Neutron, HA, Multi-Region
 
The Basic Introduction of Open vSwitch
The Basic Introduction of Open vSwitchThe Basic Introduction of Open vSwitch
The Basic Introduction of Open vSwitch
 
OpenStack을 중심으로 한 오픈 소스 & 상용 하이브리드 클라우드
OpenStack을 중심으로 한 오픈 소스 & 상용 하이브리드 클라우드OpenStack을 중심으로 한 오픈 소스 & 상용 하이브리드 클라우드
OpenStack을 중심으로 한 오픈 소스 & 상용 하이브리드 클라우드
 
Vxlan deep dive session rev0.5 final
Vxlan deep dive session rev0.5   finalVxlan deep dive session rev0.5   final
Vxlan deep dive session rev0.5 final
 
OpenFlow tutorial
OpenFlow tutorialOpenFlow tutorial
OpenFlow tutorial
 
Packet flow on openstack
Packet flow on openstackPacket flow on openstack
Packet flow on openstack
 
오픈스택 멀티노드 설치 후기
오픈스택 멀티노드 설치 후기오픈스택 멀티노드 설치 후기
오픈스택 멀티노드 설치 후기
 
Building DataCenter networks with VXLAN BGP-EVPN
Building DataCenter networks with VXLAN BGP-EVPNBuilding DataCenter networks with VXLAN BGP-EVPN
Building DataCenter networks with VXLAN BGP-EVPN
 

Similar to Demystifying OpenVswitch and SDN

PLNOG16: VXLAN Gateway, efektywny sposób połączenia świata wirtualnego z fizy...
PLNOG16: VXLAN Gateway, efektywny sposób połączenia świata wirtualnego z fizy...PLNOG16: VXLAN Gateway, efektywny sposób połączenia świata wirtualnego z fizy...
PLNOG16: VXLAN Gateway, efektywny sposób połączenia świata wirtualnego z fizy...PROIDEA
 
Understanding network and service virtualization
Understanding network and service virtualizationUnderstanding network and service virtualization
Understanding network and service virtualizationSDN Hub
 
[OpenStack 하반기 스터디] Interoperability with ML2: LinuxBridge, OVS and SDN
[OpenStack 하반기 스터디] Interoperability with ML2: LinuxBridge, OVS and SDN[OpenStack 하반기 스터디] Interoperability with ML2: LinuxBridge, OVS and SDN
[OpenStack 하반기 스터디] Interoperability with ML2: LinuxBridge, OVS and SDNOpenStack Korea Community
 
20151222_Interoperability with ML2: LinuxBridge, OVS and SDN
20151222_Interoperability with ML2: LinuxBridge, OVS and SDN20151222_Interoperability with ML2: LinuxBridge, OVS and SDN
20151222_Interoperability with ML2: LinuxBridge, OVS and SDNSungman Jang
 
An Introduce of OPNFV (Open Platform for NFV)
An Introduce of OPNFV (Open Platform for NFV)An Introduce of OPNFV (Open Platform for NFV)
An Introduce of OPNFV (Open Platform for NFV)Mario Cho
 
PLNOG 13: Nicolai van der Smagt: SDN
PLNOG 13: Nicolai van der Smagt: SDNPLNOG 13: Nicolai van der Smagt: SDN
PLNOG 13: Nicolai van der Smagt: SDNPROIDEA
 
Optimising nfv service chains on open stack using docker
Optimising nfv service chains on open stack using dockerOptimising nfv service chains on open stack using docker
Optimising nfv service chains on open stack using dockerAnanth Padmanabhan
 
Optimising nfv service chains on open stack using docker
Optimising nfv service chains on open stack using dockerOptimising nfv service chains on open stack using docker
Optimising nfv service chains on open stack using dockerSatya Sanjibani Routray
 
OSDC 2014: Yves Fauser - OpenStack Networking (Neutron) - Overview of network...
OSDC 2014: Yves Fauser - OpenStack Networking (Neutron) - Overview of network...OSDC 2014: Yves Fauser - OpenStack Networking (Neutron) - Overview of network...
OSDC 2014: Yves Fauser - OpenStack Networking (Neutron) - Overview of network...NETWAYS
 
Osdc2014 openstack networking yves_fauser
Osdc2014 openstack networking yves_fauserOsdc2014 openstack networking yves_fauser
Osdc2014 openstack networking yves_fauseryfauser
 
SDN: A New Approach to Networking Technology
SDN: A New Approach to Networking TechnologySDN: A New Approach to Networking Technology
SDN: A New Approach to Networking TechnologyIRJET Journal
 
Optimising nfv service chains on open stack using docker
Optimising nfv service chains on open stack using dockerOptimising nfv service chains on open stack using docker
Optimising nfv service chains on open stack using dockerRahul Krishna Upadhyaya
 
Docker Multi Host Networking, Rachit Arora, IBM
Docker Multi Host Networking, Rachit Arora, IBMDocker Multi Host Networking, Rachit Arora, IBM
Docker Multi Host Networking, Rachit Arora, IBMNeependra Khare
 
OpenStack Networking and Automation
OpenStack Networking and AutomationOpenStack Networking and Automation
OpenStack Networking and AutomationAdam Johnson
 
Quantum - Virtual networks for Openstack
Quantum - Virtual networks for OpenstackQuantum - Virtual networks for Openstack
Quantum - Virtual networks for Openstacksalv_orlando
 

Similar to Demystifying OpenVswitch and SDN (20)

PLNOG16: VXLAN Gateway, efektywny sposób połączenia świata wirtualnego z fizy...
PLNOG16: VXLAN Gateway, efektywny sposób połączenia świata wirtualnego z fizy...PLNOG16: VXLAN Gateway, efektywny sposób połączenia świata wirtualnego z fizy...
PLNOG16: VXLAN Gateway, efektywny sposób połączenia świata wirtualnego z fizy...
 
Cloud v2
Cloud v2Cloud v2
Cloud v2
 
Understanding network and service virtualization
Understanding network and service virtualizationUnderstanding network and service virtualization
Understanding network and service virtualization
 
[OpenStack 하반기 스터디] Interoperability with ML2: LinuxBridge, OVS and SDN
[OpenStack 하반기 스터디] Interoperability with ML2: LinuxBridge, OVS and SDN[OpenStack 하반기 스터디] Interoperability with ML2: LinuxBridge, OVS and SDN
[OpenStack 하반기 스터디] Interoperability with ML2: LinuxBridge, OVS and SDN
 
20151222_Interoperability with ML2: LinuxBridge, OVS and SDN
20151222_Interoperability with ML2: LinuxBridge, OVS and SDN20151222_Interoperability with ML2: LinuxBridge, OVS and SDN
20151222_Interoperability with ML2: LinuxBridge, OVS and SDN
 
BuildingSDNmanageableswitch.pdf
BuildingSDNmanageableswitch.pdfBuildingSDNmanageableswitch.pdf
BuildingSDNmanageableswitch.pdf
 
An Introduce of OPNFV (Open Platform for NFV)
An Introduce of OPNFV (Open Platform for NFV)An Introduce of OPNFV (Open Platform for NFV)
An Introduce of OPNFV (Open Platform for NFV)
 
PLNOG 13: Nicolai van der Smagt: SDN
PLNOG 13: Nicolai van der Smagt: SDNPLNOG 13: Nicolai van der Smagt: SDN
PLNOG 13: Nicolai van der Smagt: SDN
 
Opencontrail network virtualization
Opencontrail network virtualizationOpencontrail network virtualization
Opencontrail network virtualization
 
CloudComp 2015 - SDN-Cloud Testbed with Hyper-convergent SmartX Boxes
CloudComp 2015 - SDN-Cloud Testbed with Hyper-convergent SmartX BoxesCloudComp 2015 - SDN-Cloud Testbed with Hyper-convergent SmartX Boxes
CloudComp 2015 - SDN-Cloud Testbed with Hyper-convergent SmartX Boxes
 
OVS-LinuxCon 2013.pdf
OVS-LinuxCon 2013.pdfOVS-LinuxCon 2013.pdf
OVS-LinuxCon 2013.pdf
 
Optimising nfv service chains on open stack using docker
Optimising nfv service chains on open stack using dockerOptimising nfv service chains on open stack using docker
Optimising nfv service chains on open stack using docker
 
Optimising nfv service chains on open stack using docker
Optimising nfv service chains on open stack using dockerOptimising nfv service chains on open stack using docker
Optimising nfv service chains on open stack using docker
 
OSDC 2014: Yves Fauser - OpenStack Networking (Neutron) - Overview of network...
OSDC 2014: Yves Fauser - OpenStack Networking (Neutron) - Overview of network...OSDC 2014: Yves Fauser - OpenStack Networking (Neutron) - Overview of network...
OSDC 2014: Yves Fauser - OpenStack Networking (Neutron) - Overview of network...
 
Osdc2014 openstack networking yves_fauser
Osdc2014 openstack networking yves_fauserOsdc2014 openstack networking yves_fauser
Osdc2014 openstack networking yves_fauser
 
SDN: A New Approach to Networking Technology
SDN: A New Approach to Networking TechnologySDN: A New Approach to Networking Technology
SDN: A New Approach to Networking Technology
 
Optimising nfv service chains on open stack using docker
Optimising nfv service chains on open stack using dockerOptimising nfv service chains on open stack using docker
Optimising nfv service chains on open stack using docker
 
Docker Multi Host Networking, Rachit Arora, IBM
Docker Multi Host Networking, Rachit Arora, IBMDocker Multi Host Networking, Rachit Arora, IBM
Docker Multi Host Networking, Rachit Arora, IBM
 
OpenStack Networking and Automation
OpenStack Networking and AutomationOpenStack Networking and Automation
OpenStack Networking and Automation
 
Quantum - Virtual networks for Openstack
Quantum - Virtual networks for OpenstackQuantum - Virtual networks for Openstack
Quantum - Virtual networks for Openstack
 

Recently uploaded

The Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfThe Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfSeasiaInfotech2
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsMiki Katsuragi
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenHervé Boutemy
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
Vector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector DatabasesVector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector DatabasesZilliz
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr LapshynFwdays
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Manik S Magar
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxhariprasad279825
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 

Recently uploaded (20)

The Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfThe Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdf
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering Tips
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache Maven
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
Vector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector DatabasesVector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector Databases
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptx
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 

Demystifying OpenVswitch and SDN

  • 1. Demystifying OpenVswitch Start your SDN journey today! Prasad Mukhedkar Emerging Technologies Group, Red Hat. pmukhedk@redhat.com
  • 2. Objectives and Takeways Session Objectives : ● High level overveiw of SDN Concepts and introduction of OpenvSwitch, ● Understand how to use OpenVswitch with KVM Virtualization ● Various OpenvSwitch Features with Demo ● SDN - OpenFlow ● SDN Controller (opendaylight project) Key Takeways : ● Getting familiar with openvswitch and its cli utilities ● When to use which Feature of OpenvSwitch. ● Creating vlans for your TestBeds (KVM). ● Opendaylight controller and OpenFlow
  • 3. What is SDN? Software Defined Network? ● Separation of the control from the forwarding plane. ● Software programmability for network elements. ● Centralized network control and management . The control plane is where forwarding/routing decisions are made (Software Logic) The data plane is where the data forwarding action takes place. (instructions to carry traffic over hardware ) The SDN architecture decouples the network control and forwarding functions enabling the network control to become directly programmable and the underlying infrastructure to be abstracted for the applications and network service.
  • 4. 10000 foot view of SDN Approach Notice how control and data planes are separated and how this separation helps applications to directly controls network opening doors for innovation. Network Infrastructure - This consists the network devices such as routers and switches, Both physical as well as virtual. Controller - This encompass the software based on a centralized controller which could be on a server that talks to all the devices in the network using open API’s, Like OpenFlow or OVMDB. Applications : This encompasses the variety of application for which the network exists. This includes voice, video, enterprise applications, security appliances such as intrusion detection. These application can to the controller using open API’s to give them what they want. For example, Voice traffic may ask the controller to have it treated with least latency while an enterprise backup server may tell the controller to give it bandwith whenever it is available.
  • 5. Limitations of Linux Bridge Guest (VM) networking in KVM has traditionally been done using linux, It is simple to configure and manage but is not originally designed for virtual networking and therefore poses integration and management challenges. Linux Bridge An unmanaged software switch ! Robust, Does packet forwarding job very well. Fast, simple to use, No complexity Linux Bridge's “root cause problem” It is Closed for Innovations!
  • 6. What is OpenvSwitch? OpenvSwitch is an open source openflow capable virtual switch. If you’re familiar with VMware, think of it as an open source Distributed ● Flexible Control in user-space with comprehensive management tools ● Fast Datapath (forwarding plane) in kernel ● Adopted in base kernel, since version 3.3 ● Open vSwitch was included since RHEL 6 .4 (only datapath, no Control). ● Any netdevice (physical/virtual) can be added as uplink port
  • 7. OpenvSwitch Architecture The data path (ovs kernel module) uses netlink socket to interacts with vswitchd daemon that implements and manages any number ovs switches on local system, SDN Controller interacts with vswitchd using openflow protocol. The ovsdb-server maintains the switch table database and external clients can talk to ovsdb-server using json rpc and json being the data format. ovsdb database currently contains around 13 tables and this database is persistent across restarts.
  • 8. Openvswitch installation Starting with Fedora 16 the openvswitch user space tools and the required kernel modules are included in the Fedora distribution. # sudo dnf install openvswitch openvswitch package contains all the required user space tools including the ovsdb and series of command line utilities to configure, monitor and manage open vswitch instances. Following are the important configuration files of openvswitch. RHEL 7 and later (Need openstack or openshift channel) #rpm -qc openvswitch /etc/logrotate.d/openvswitch /etc/openvswitch/conf.db /etc/openvswitch/system-id.conf /etc/sysconfig/openvswitch
  • 9. Starting up the openvswitch service The Openvswitch.service is comprised by two daemons. One is a database and another is the switch itself. #/bin/systemctl start openvswitch.service #systemctl enable openvswitch.service 1. Kernel module gets loaded. module name is "openvswitch" #modinfo openvswitch filename: /lib/modules/4.1.6-200.fc22.x86_64/kernel/net/openvswitch/openvswitch.ko.xz license: GPL description: Open vSwitch switching datapath 2. Database is created. copied /usr/share/openvswitch/vswitch.ovsschema /etc/openvswitch/conf.db
  • 10. Openvswitch command-line interfaces #ovs-vsctl - This command is used to set up, maintain, and inspect various ovs switch configurations. It provides a high level interface for Open vSwitch Database to query and apply changes on runtime. #ovs-ofctl and ovs-dpctl - These two commands are used for administering and monitoring flow entries. You learned that OVS manages two kinds of flow. OpenFlows - The flows managed at control plane. Datapath - Kernel flow. A kind of cached version of the OpenFlow. ovs-ofctl - speaks to OpenFlow module whereas ovs-dpctl - speaks to Kernel module. Following two are most used options of each of these commands ovs-appctl - This command offer a way to send commands to a running Open vSwitch and gather information that is not directly exposed to ovs-ofctl command. This is swiss army knife of openflow troubleshooting.
  • 11. Setting up your first openvswitch bridge Multiple ways to Setup/Configure . - The ovs-vsctl is the primary command to create, remove and administer openvswitch. The operation performed using ovs-vsctl are persistent across system reboot. [root@kvmHOST1 ~]# ovs-vsctl add-br vswitch001 [root@kvmHOST1 ~]# ovs-vsctl show - Configuring a openvswitch bridge using network scripts. [root@kvmHOST1]cat /etc/sysconfig/network-scripts/ifcfg- vswitch002 DEVICE="vswitch002" BOOTPROTO="dhcp" DEFROUTE="yes" IPV4_FAILURE_FATAL="yes" IPV6INIT=no ONBOOT="yes" TYPE="OVSBridge" DEVICETYPE="ovs" Doc on ifcfg directives for openvswitch /usr/share/doc/openvswitch/README.RHEL
  • 12. Integrating KVM VMs and OVS Edit VM XML Configuration #virsh edit vm-name <interface type='bridge'> <mac address='52:54:00:ce:51:53''/> <source bridge=vswitch001/> <virtualport type='openvswitch'/> <target dev=<vm001_vp01> <model type='virtio'/> </interface> Libvirt Network Pool #cat ovs-network.xml <network> <name>NewNetwork</name> <forward mode='bridge'/> <bridge name='vswitch1'/> <virtualport type='openvswitch'/> </network> virsh net-define ovs-network.xml Network vswitch-net defined from ovs-network.xml # virsh net-start vswitch-net Network vswitch-net started A quick method! #virt-xml vm_01 --edit --network virtualport_type='openvswitch',source=vswitch001 ,target=vm001_vp01
  • 13. Feature 1 : Security / L2 Segregation VLAN isolation enforces VLAN membership of a VM without the knowledge of the guest itself. VLan1 : [root@kvmHOST1 ~]# ovs-vsctl set port fed1 tag=10 [root@kvmHOST1 ~]# ovs-vsctl set port fed2 tag=10 vLan2: [root@kvmHOST1 ~]# ovs-vsctl set port fed3 tag=20 [root@kvmHOST1 ~]# ovs-vsctl set port fed4 tag=20 #ovs-vsctl set port fed1 trunks=20,30,40 Monitor #ovsdb-client monitor Port name,trunks -- detach The default, vlan_mode used is "access", Its native mechanism of the vlan. VLAN Tag is added when packets enter a Access port, and stripped off when leave a access port. Other vlan_mode are native−tagged, native−untagged and trunk
  • 14. libvirt Integration <portgroup name='novlan' default='yes'> </portgroup> <portgroup name='vlan-finance'> <vlan> <vlan-mode=native-tagged> <tag id='10'/> </vlan> </portgroup> <portgroup name='vlan-marketing'> <vlan trunk='yes'> <tag id='20'/> <tag id='30'/> <tag id='30'/> </vlan> </portgroup> portgroup feature of libvirt provides a method of easily putting guest connections to the network into different classes, with each class potentially having a different level/type of service.
  • 15. Feature 2 : Overlay Networks Overlay Networks are industry standard techniques designed achieve Network Virtualization. Network Overlays such as Virtual eXtensible Local Area Network a(VXLAN) and Generic Routing Encapsulation (GRE) achieve network virtualization by overlaying layer 2 networks over physical layer 3 networks which enable network scalability and efficient use of current network infrastructure. Openvswitch supports multiple tunneling protocols (GRE, VXLAN, STT, and Geneve, with IPsec support) vm1 vm2 10.0.0.1 vxLan tunnle 10.0.0.2 overway N/W | | kvmhost1 kvmhost2 192.168.1.10 underlay N/W 192.168.2.20
  • 16. Configuring Overlay Networks Host1 #ovs-vsctl add-port vswitch vxlan1 -- set interface vxlan1 type=vxlan options:remote_ip=192.168.1.20 Host2 #ovs-vsctl add-port vswitch vxlan1 -- set interface vxlan2 type=vxlan options:remote_ip=192.168.1.10 Other options : local_ip, in_key, out_key,tos,ttl
  • 17. Feature 3 : QoS The network QoS (quality of service) QoS refers to the ability of the network to handle it traffic such that it meets the service needs of certain applications. It is often used as a synonym for traffic control. QoS Policing - Rate Limiting Qos Shaping - Dedicated Queue Input(inbound) and output(outbound) traffic
  • 18. Feature 3 : QoS Configuration Shaping Create a queue(q0) with required network bandwidth. Here in this example I am limiting the egress traffic bandwidth to 10 MBps. Create a Queue #ovs-vsctl --id=@q0 create queue other-config:min- rate=100000 other-config:max-rate=100000 Create Qos #ovs-vsctl create qos type=linux-htb queues=0=05c73c42-3191-4025-96ce- cd6b86ab2775 Add Qos to a port #ovs-vsctl set port vent0 qos= 09f5b3c4- 35b7-4326-bae8-780b7ccadb3f Policing To apply QoS on a VM to control its inbound traffic, Modify its interface table to configure an ingress policing rule. There are two rules to set: ingress_policing_rate: The maximum rate (in Kbps) that this VM should be allowed to send. ingress_policing_burst: A parameter to the policing algorithm to indicate the maximum amount of data (in Kb) that this interface can send beyond the policing rate. ovs-vsctl set interface fed1 ingress_policing_rate=20000 ovs-vsctl set interface fed1 ingress_policing_burst=200
  • 19. Feature 4 : Port Mirroring OpenVswitch support port mirroring features out of the box, This feature is exactly similar to the port mirroring capability available on the new generation physical switches. With Port Mirroring Network administrator can get an insight on what kind of traffic is flowing on the network. #ovs-vsctl -- --id=@m create mirror name=M1 -- add bridge vswitch001 mirrors @m $ovs-vsctl set port fed1 -- set mirror M1 select_src_port=@fed1 select_dst_port=@fed2 select_dst_port = Ports on which incoming packets are selected for select_src_port = Ports on which outgoing packets are selected for mirroring. select_all = Its boolean, when to true. every packet incoming or outgoing on any port connected to bridge will be mirrored. output_port = specify to which port we want to send this mirrored traffic
  • 20. Feature 4 : Port Mirroring SPAN (Switched Port Analyzer) #ip link add dummy0 type dummy # ovs-vsctl -- --id=@dummy0 get port dummy0 -- set mirror mymirror select_all=true output-port=@dummy0
  • 21. SDN Controllers An SDN controller is an application in software-defined networking (SDN) that manages flow control to enable intelligent networking. Flow table is managed by a remote SDN controller, You can install or remove control flows using the SDN controller connected to the bridge
  • 22. Managing Openvswitch via a SDN Controller By connecting an openvswitch to SDN controller, We get level of abstraction and automation required to revolutionize networking. #ovs-vsctl set-controller vswitch0 tcp:192.168.1.20:6633
  • 23. More about openflow OpenFlow allows creating powerful L2-L4 service insertion, A flow contains entries that matches packets and apply actions that may include packet forwarding, packet modification and others. Basically rules are used to create expression, If expression matches, The defined Action is applied.
  • 24. Flow example Example : 1 cookie=0x0, duration=14.604s, table=0, n_packets=61, n_bytes=7418, idle_timeout=10, hard_timeout=30,tcp, vlan_tci=0x0000, dl_src=52:54:00:CE:51:52, dl_dst=52:54:00:CE:51:53, nw_src=10.0.0.1, nw_dst=10.0.0.2, nw_tos=0, tp_src=22, tp_dst=554 actions=output:1 Example 2 : Where can I learn more about flow ? https://flowsim.flowgrammable.org/
  • 25. OpenVswitch Troubleshooting - openvswitch Services Log files : /var/log/openvswitch/ovs-vswitchd.log /var/log/openvswitch/ovsdb-server.log - VLOG : OpenvSwitch has a built-in logging mechanism called VLOG. The VLOG facility expose deep internal information of various components. First Determine at what level your problem is occurring, Is it Bonding problem? #ovs-appctl vlog/list ovs-appctl vlog/list | grep -i bond - Verbosity of logging supported are (must be: emer, err, warn, info, or dbg), #ovs-appctl vlog/set module[:facility[:level]]
  • 26. OpenVswitch Troubleshooting - ovsdb-client utility to query the ovs database Tables : #ovsdb-client list-tables Bridge, Queue,QoS,Port, Interface # "ovsdb-client list-columns <table_name>" Prints columns in a particular table, There are many columns in each table. ovsdb-client monitor <table_name> <cloumn_name> --detach - Some other handy tools #ovsdb-tool showlog" to see data inserted into ovsdb, its openvswitch configuration #ovs-vsctl --format=table --column=name,vlan_mode
  • 27. OpenVswitch Troubleshooting "Show My Network State" is good utility to get graphically display of the virtual/physical network topology inside a single host. The tools is available here for download, https://sites.google.com/site/showmynetworkstate/

Editor's Notes

  1. controller, They are directly use fastpath (Data path). However, Note that each Flow Table entry has two timers: