Ask Your Question
1

OVS plugin Error Failed to create OVS patch port

asked 2013-05-21 07:28:04 -0500

anonymous user

Anonymous

updated 2014-04-09 03:00:57 -0500

smaffulli gravatar image

I just installed a three nodes configuration

  • 1 Controller (mysql, Rabbit, NTP, keystone, glance, quantum, Openvswitch, nova and horizon) 172.17.1.1
  • 2 compute (nova, Quantum, OpenVswitch) 172.17.2.1

Here is my quantum.conf

[DEFAULT]
debug = True
verbose = True
state_path = /var/lib/quantum
bind_host = 0.0.0.0
bind_port = 9696
core_plugin = quantum.plugins.openvswitch.ovs_quantum_plugin.OVSQuantumPluginV2
api_paste_config = /etc/quantum/api-paste.ini
control_exchange = quantum
rabbit_host = 172.17.1.1
rabbit_password = XXXXXXXX
rabbit_port = 5672
rabbit_userid = guest
notification_driver = quantum.openstack.common.notifier.rpc_notifier
default_notification_level = INFO
notification_topics = notifications
[QUOTAS]
[DEFAULT_SERVICETYPE]
[SECURITYGROUP]
[AGENT]
root_helper = sudo quantum-rootwrap /etc/quantum/rootwrap.conf
[keystone_authtoken]
auth_host = 172.17.1.1
auth_port = 35357
auth_protocol = http
admin_tenant_name = service
admin_user = quantum
admin_password = XXXXXXXX
signing_dir = /var/lib/quantum/keystone-signing

Here is ovs_quantum_plugin.ini

   [DATABASE]
sql_connection = mysql://quantumUser:XXXXXXX@172.17.1.1/quantum
reconnect_interval = 2
[OVS]
enable_tunneling = True
tenant_network_type = gre
tunnel_id_ranges = 1:1000
local_ip = 172.18.2.1
integration_bridge = br-int
tunnel_bridge = br-tun
[AGENT]
polling_interval = 2
[SECURITYGROUP]

When i try to run the OVS plugin i have the following error in /var/log/quantum/openvswitch-agent.log

ERROR [quantum.plugins.openvswitch.agent.ovs_quantum_agent] Failed to create OVS patch port. Cannot have tunneling enabled on this agent, since this version of OVS does not support tunnels or patch ports. Agent terminated!

Here is what syslog shows

Aug 30 18:51:29 SSCloud-08 ovs-vsctl: 00001|vsctl|INFO|Called as /usr/bin/ovs-vsctl --timeout=2 -- --if-exists del-port br-int patch-tun
Aug 30 18:51:29 SSCloud-08 ovs-vsctl: 00001|vsctl|INFO|Called as /usr/bin/ovs-vsctl --timeout=2 -- --if-exists del-br br-tun
Aug 30 18:51:29 SSCloud-08 kernel: [  949.133083] device br-tun left promiscuous mode
Aug 30 18:51:29 SSCloud-08 ovs-vsctl: 00001|vsctl|INFO|Called as /usr/bin/ovs-vsctl --timeout=2 add-br br-tun
Aug 30 18:51:29 SSCloud-08 kernel: [  949.321265] device br-tun entered promiscuous mode
Aug 30 18:51:30 SSCloud-08 ovs-vsctl: 00001|vsctl|INFO|Called as /usr/bin/ovs-vsctl --timeout=2 add-port br-int patch-tun
Aug 30 18:51:30 SSCloud-08 ovs-vsctl: 00001|vsctl|INFO|Called as /usr/bin/ovs-vsctl --timeout=2 set Interface patch-tun type=patch
Aug 30 18:51:30 SSCloud-08 ovs-vswitchd: 00223|netdev_vport|ERR|patch-tun: patch type requires valid 'peer' argument
Aug 30 18:51:30 SSCloud-08 ovs-vsctl: 00001|vsctl|INFO|Called as /usr/bin/ovs-vsctl --timeout=2 set Interface patch-tun options:peer=patch-int
Aug 30 18:51:30 SSCloud-08 ovs-vsctl: 00001|vsctl|INFO|Called as /usr/bin/ovs-vsctl --timeout=2 add-port br-tun patch-int
Aug 30 18:51:30 SSCloud-08 ovs-vsctl: 00001|vsctl|INFO|Called as /usr/bin/ovs-vsctl --timeout=2 set Interface patch-int type=patch
Aug 30 18:51:30 SSCloud-08 ovs-vswitchd: 00249|netdev_vport|ERR|patch-int: patch type requires valid 'peer' argument
Aug 30 18:51:30 SSCloud-08 ovs-vsctl: 00001|vsctl|INFO|Called as /usr/bin/ovs-vsctl --timeout=2 set Interface patch-int options:peer=patch-tun

Openvswitch do loaded

# lsmod | grep openvswich
openvswitch            43533  3

dpkg -l openvswitch* says

# dpkg -l openvswitch\*
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status ...
(more)
edit retag flag offensive close merge delete

Comments

You don't say what OS+level and what OVS version you are using?

darragh-oreilly gravatar imagedarragh-oreilly ( 2013-05-22 11:20:49 -0500 )edit

5 answers

Sort by ยป oldest newest most voted
4

answered 2013-05-23 05:31:37 -0500

Bada gravatar image

updated 2014-04-09 03:06:11 -0500

smaffulli gravatar image
aptitude install -y openvswitch-datapath-source
aptitude install module-assistant
module-assistant auto-install openvswitch-datapath

Solved the problem. You may also need to reboot the machines. This is an Ubuntu 12.04 and

ovs-vsctl --version
ovs-vsctl (Open vSwitch) 1.4.0+build0
Compiled Feb 18 2013 13:13:22

on both hosts and

quantum-openvswitch-agent --version

show nothing on both hosts

edit flag offensive delete link more

Comments

There is probably more info in the syslog. Is the datapath module loaded? 'lsmod | grep openvswitch'. What does dpkg -l openvswitch\* say? I think the datapath shipped by ubuntu does not have the support and you have to build it from source.

darragh-oreilly gravatar imagedarragh-oreilly ( 2013-05-23 06:20:43 -0500 )edit

I have the same issue after upgrading the kernel to (3.5.0-32-generic)

james.shimer gravatar imagejames.shimer ( 2013-07-01 13:31:52 -0500 )edit

[quantum] int() argument must be a string or a number, not 'NoneType' Traceback (most recent call last): File "/usr/bin/quantum-openvswitch-agent", line 24, in <module> main() File "/usr/lib/python2.7/dist-packages/quantum/plugins/openvswitch/agent/ovs_quantum_agent.py", line 763, in main

james.shimer gravatar imagejames.shimer ( 2013-07-01 13:32:32 -0500 )edit

Thanks for the effort but this solution does not work for me. I think you are suggesting to user kernel module for OVS, But I don't think it is necessary.

shedoh gravatar imageshedoh ( 2013-08-30 05:54:56 -0500 )edit

It required me to reboot after all those steps mentioned by Bada.

azpekt gravatar imageazpekt ( 2013-09-08 23:57:16 -0500 )edit
1

answered 2013-07-08 13:46:20 -0500

ijab gravatar image

OVS in ubuntu 12.04 is 1.4.x which is compatible with linux kernel from 2.6.x - 3.2, and so if upgrading to 3.5 kernel, OVS can't work.

solution: 1) downgrade to 3.2 kernel 2) build and install latest 1.10.x OVS by yourself.

iJab

edit flag offensive delete link more

Comments

Hi IJab, if i dont want to downgrade to 3.2 Kernel then you suggested to build and install 1.10.x OVS by yourself. Can you please suggest the steps to create it or suggest where can i download and install this from so as to make this lab working. Please suggest.

RohitGupta gravatar imageRohitGupta ( 2013-07-23 16:54:22 -0500 )edit
1

I faced the same problem with 3.8 kernel. Installing openvswitch-datapath-lts-raring-dkms solved the problem.

SivaP gravatar imageSivaP ( 2013-09-27 05:13:56 -0500 )edit
1

answered 2013-09-27 05:26:42 -0500

SivaP gravatar image

I also faced the same problem with 3.8 kernel. Installing openvswitch-datapath-lts-raring-dkms instead of openvswitch-datapath-dkms and rebooting solved my issue.

edit flag offensive delete link more
1

answered 2013-09-08 23:56:33 -0500

azpekt gravatar image

It required me to reboot a server, after I did all steps described by Bada.

edit flag offensive delete link more
-1

answered 2013-07-01 13:37:33 -0500

james.shimer gravatar image

This isn't answer (more questions). Comments are too restrictive to add any new information...

After upgrading Ubuntu 12.04 LTS to 3.5.0-32-generic I started seeing: openvswitch-agent.log: 2013-07-01 14:33:48 DEBUG [quantum.agent.linux.utils] Running command: ['sudo', 'quantum-rootwrap', '/etc/quantum/rootwrap.conf', 'ovs-vsctl', '--timeout=2', 'get', 'Interface', 'patch-int', 'ofport'] 2013-07-01 14:33:48 DEBUG [quantum.agent.linux.utils] Command: ['sudo', 'quantum-rootwrap', '/etc/quantum/rootwrap.conf', 'ovs-vsctl', '--timeout=2', 'get', 'Interface', 'patch-int', 'ofport'] Exit code: 0 Stdout: '-1\n' Stderr: '' 2013-07-01 14:33:48 ERROR [quantum.plugins.openvswitch.agent.ovs_quantum_agent] Failed to create OVS patch port. Cannot have tunneling enabled on this agent, since this version of OVS does not support tunnels or patch ports. Agent terminated!

And the following traceback when starting the service (service quantum-plugin-openvswitch-agent start) : [quantum] int() argument must be a string or a number, not 'NoneType' Traceback (most recent call last): File "/usr/bin/quantum-openvswitch-agent", line 24, in <module> main() File "/usr/lib/python2.7/dist-packages/quantum/plugins/openvswitch/agent/ovs_quantum_agent.py", line 763, in main plugin = OVSQuantumAgent(**agent_config) File "/usr/lib/python2.7/dist-packages/quantum/plugins/openvswitch/agent/ovs_quantum_agent.py", line 180, in __init__ self.setup_tunnel_br(tun_br) File "/usr/lib/python2.7/dist-packages/quantum/plugins/openvswitch/agent/ovs_quantum_agent.py", line 520, in setup_tunnel_br if int(self.patch_tun_ofport) < 0 or int(self.patch_int_ofport) < 0: TypeError: int() argument must be a string or a number, not 'NoneType' ) = 796

I'm thinking I'm going to have to revert back to 3.5.0-23-generic.

edit flag offensive delete link more

Comments

FYI I was able to get things working again by disabling tunneling and going with flat networking. For whatever reason 3.5.0-32-generic has seemed to cause an issue w/ OVS tunneling, where as 3.5.0-23-generic was working fine.

james.shimer gravatar imagejames.shimer ( 2013-07-01 14:46:25 -0500 )edit

Hi James, I am building the lab following the guide on the following link: https://github.com/mseknibilel/OpenStack-Grizzly-Install-Guide/blob/OVS_MultiNode/OpenStack_Grizzly_Install_Guide.rst I am able to create VMs and other things but VM cannot get IP address and inet4 does not show on VM instances. On checking, I found error - ERROR [quantum.plugins.openvswitch.agent.ovs_quantum_agent] Failed to create OVS patch port. Cannot have tunneling enabled on this agent, since this version of OVS does not support tunnels or patch ports. Agent terminated!. I am using Ubuntu 12.04 LTS 3.5.0-36-generic and as per the blogs they say OVS does not compiles with this kernel. You have mentioned to switch to Flat networking and as a newbie I would appreciate if you can specify what all I need to do to transition from current configuration to flat networking. thanks in advance

RohitGupta gravatar imageRohitGupta ( 2013-07-23 11:21:06 -0500 )edit

In order to make this site more useful, ask a different question if it's different than the original one. You can also gain karma and edit questions to make them more general. Don't treat this site as a forum for discussions because it's not.

smaffulli gravatar imagesmaffulli ( 2014-04-09 03:03:32 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

2 followers

Stats

Asked: 2013-05-21 07:28:04 -0500

Seen: 9,524 times

Last updated: Apr 09 '14