Bug 982316 - Quantum agent configuration files missing root_helper, stops ovs agent from starting
Quantum agent configuration files missing root_helper, stops ovs agent from s...
Status: CLOSED EOL
Product: Fedora
Classification: Fedora
Component: openstack-packstack (Show other bugs)
19
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Martin Magr
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-07-08 11:58 EDT by Jonathan Barber
Modified: 2015-09-12 18:55 EDT (History)
6 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-02-17 10:58:58 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Jonathan Barber 2013-07-08 11:58:08 EDT
Description of problem:
After running packstack (from commit feef9b09f1) the quantum-openvswitch-agent.service doesn't start and the quantum dhcp_agent reports errors in /var/log/messages.

Both of these are due to sudo errors.

Version-Release number of selected component (if applicable):
openstack-packstack feef9b09f1

How reproducible:
Always

Steps to Reproduce:
1. Install f19 @core
2. git clone --recursive https://github.com/stackforge/packstack.git
3. cd packstack
4. git checkout feef9b09f1
5. (apply patches to make packstack use mariadb)
6. ./bin/packstack --allinone

Actual results:
Packstack completes, but the quantum-openvswitch-agent.service doesn't start and shows errors in /var/log/messages relating to sudo configuration. Later, the dhcp agent shows errors. 

I believe this is because the OVS plugin configuration (/etc/quantum/plugins/openvswitch/ovs_quantum_plugin.ini) in the AGENT section, and the dhcpd agent configuratoin (/etc/quantum/dhcp_agent.ini) in the DEFAULT section are missing "root_helper" definitions.

The sudo errors look like this:
Jul  5 12:31:45 cas01 quantum-ovs-cleanup[4759]: Command: ['sudo', 'ovs-vsctl', '--timeout=2', 'list-br']
Jul  5 12:31:45 cas01 quantum-ovs-cleanup[4759]: Exit code: 1

Jul  8 12:40:58 cas01 quantum-dhcp-agent[1387]: Command: ['sudo', 'ip', 'netns', 'exec', 'qdhcp-96c697b8-58b4-4f87-b13d-b8df001ef51d', 'quantum-ns-metadata-proxy', '--pid_file=/var/lib/quantum/external/pids/96c697b8-58b4-4f87-b13d-b8df001ef51d.pid', '--network_id=96c697b8-58b4-4f87-b13d-b8df001ef51d', '--state_path=/var/lib/quantum', '--metadata_port=80', '--verbose', '--log-file=quantum-ns-metadata-proxy96c697b8-58b4-4f87-b13d-b8df001ef51d.log', '--log-dir=/var/log/quantum']
Jul  8 12:40:58 cas01 quantum-dhcp-agent[1387]: Exit code: 1

Expected results:
There should be no sudo related errors and the OVS agent should start correctly.

Additional info:
Applying the following patches corrects the configuration:

--- a/manifests/agents/dhcp.pp
+++ b/manifests/agents/dhcp.pp
@@ -41,7 +41,8 @@ class quantum::agents::dhcp (
   $resync_interval  = 30,
   $interface_driver = 'quantum.agent.linux.interface.OVSInterfaceDriver',
   $dhcp_driver      = 'quantum.agent.linux.dhcp.Dnsmasq',
-  $use_namespaces   = true
+  $use_namespaces   = true,
+  $root_helper      = 'sudo /usr/bin/quantum-rootwrap /etc/quantum/rootwrap.conf'
 ) {
 
   include quantum::params
@@ -72,6 +73,7 @@ class quantum::agents::dhcp (
     'DEFAULT/interface_driver':   value => $interface_driver;
     'DEFAULT/dhcp_driver':        value => $dhcp_driver;
     'DEFAULT/use_namespaces':     value => $use_namespaces;
+    'DEFAULT/root_helper':        value => $root_helper;
   }
 
   if $::quantum::params::dhcp_agent_package {


index 1329fe2..343cd64 100644
--- a/manifests/plugins/ovs.pp
+++ b/manifests/plugins/ovs.pp
@@ -14,7 +14,8 @@ class quantum::plugins::ovs (
   # because the list of networks there is still important
   # even if the ranges aren't specified
   $network_vlan_ranges  = 'physnet1:1000:2000',
-  $tunnel_id_ranges     = '1:1000'
+  $tunnel_id_ranges     = '1:1000',
+  $root_helper          = 'sudo /usr/bin/quantum-rootwrap /etc/quantum/rootwrap.conf'
 ) {
 
   include 'quantum::params'
@@ -52,6 +53,7 @@ class quantum::plugins::ovs (
     'DATABASE/sql_max_retries':     value => $sql_max_retries;
     'DATABASE/reconnect_interval':  value => $reconnect_interval;
     'OVS/tenant_network_type':      value => $tenant_network_type;
+    'AGENT/root_helper':            value => $root_helper;
   }
 
   if($tenant_network_type == 'gre') {

I don't know if more root_helper's are needed for the other quantum agents. It would be preferable to refactor the common $root_helper into a class parameter, but I don't understand well enough how the module works to suggest an alternative.
Comment 1 Jonathan Barber 2013-07-08 12:10:58 EDT
The Openstack quantum packages are:
openstack-quantum-2013.1-0.6.rc2.fc19.noarch
openstack-quantum-openvswitch-2013.1-0.6.rc2.fc19.noarch
Comment 2 Fedora Admin XMLRPC Client 2013-10-14 05:51:01 EDT
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.
Comment 3 Fedora Admin XMLRPC Client 2013-10-14 05:51:51 EDT
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.
Comment 4 Fedora End Of Life 2015-01-09 13:46:30 EST
This message is a notice that Fedora 19 is now at end of life. Fedora 
has stopped maintaining and issuing updates for Fedora 19. It is 
Fedora's policy to close all bug reports from releases that are no 
longer maintained. Approximately 4 (four) weeks from now this bug will
be closed as EOL if it remains open with a Fedora 'version' of '19'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 19 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.
Comment 5 Fedora End Of Life 2015-02-17 10:58:58 EST
Fedora 19 changed to end-of-life (EOL) status on 2015-01-06. Fedora 19 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.

Note You need to log in before you can comment on or make changes to this bug.