Bug 1049534

Summary: neutron-openvswitch-agent service restart fails; reason: fails to pull dependency - python-psutil
Product: Red Hat OpenStack Reporter: Terry Wilson <twilson>
Component: openstack-neutronAssignee: Terry Wilson <twilson>
Status: CLOSED NEXTRELEASE QA Contact: Nir Magnezi <nmagnezi>
Severity: urgent Docs Contact:
Priority: unspecified    
Version: 5.0 (RHEL 7)CC: apevec, chrisw, kchamart, majopela, pbrady, twilson, yeylon
Target Milestone: ---Keywords: ZStream
Target Release: 5.0 (RHEL 7)   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: openstack-neutron-2013.2.2-1.el6ost Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 1049235 Environment:
Last Closed: 2014-03-03 15:15:29 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1049235    
Bug Blocks:    

Description Terry Wilson 2014-01-07 17:23:48 UTC
+++ This bug was initially created as a clone of Bug #1049235 +++

Description of problem
----------------------

Upgrading openstack-neutron-2013.2-3.fc20.noarch (Havana) to
openstack-neutron-2014.1-0.1.b1.fc21.noarch (IceHouse-M1), and 
restarting openstack-neutron-agent fails with the below:

[. . .]
"/usr/lib/python2.7/site-packages/neutron/agent/linux/async_process.py", ...odule>
Jan 07 02:45:15 node2-compute neutron-openvswitch-agent[3471]: import psutil
Jan 07 02:45:15 node2-compute neutron-openvswitch-agent[3471]: ImportError: No module
named psutil
Jan 07 02:45:15 node2-compute systemd[1]: neutron-openvswitch-agent.service: main process
exited, code=exited, status=1/FAILURE
[. . .]

Workaround: 

  $ yum install python-psutil -y


Version
-------

I upgraded from openstack-neutron-2013.2-3.fc20.noarch to
openstack-neutron-2014.1-0.1.b1.fc21.noarch


Test env
--------

A two node OpenStack RDO set-up configured manually on two Fedora 20
VMs:

  - Controller node: Nova, Keystone, Cinder, Glance, Neutron (using Open
    vSwitch plugin and GRE tunneling).

  - Compute node: Nova (nova-compute), Neutron (openvswitch-agent)


How reproducible: Consistently.


Steps to Reproduce
------------------

Assuming you have openstack-neutron-2013.2-3.fc20.noarch, on your
current Fedora-20 OpenStack setup:

    $ yum install \
      http://repos.fedorapeople.org/repos/openstack/openstack-icehouse/rdo-release-icehouse-1.noarch.rpm

    $ yum update openstack-neutron -y

    $ systemctl restart openstack-neutron


Actual results 
--------------

Restart fails with:

[. . .]
Jan 07 02:45:15 node2-compute neutron-openvswitch-agent[3471]: from neutron.agent.linux import polling
Jan 07 02:45:15 node2-compute neutron-openvswitch-agent[3471]: File "/usr/lib/python2.7/site-packages/neutron/agent/linux/polling.py", line 2...odule>
Jan 07 02:45:15 node2-compute neutron-openvswitch-agent[3471]: from neutron.agent.linux import ovsdb_monitor
Jan 07 02:45:15 node2-compute neutron-openvswitch-agent[3471]: File "/usr/lib/python2.7/site-packages/neutron/agent/linux/ovsdb_monitor.py", ...odule>
Jan 07 02:45:15 node2-compute neutron-openvswitch-agent[3471]: from neutron.agent.linux import async_process
Jan 07 02:45:15 node2-compute neutron-openvswitch-agent[3471]: File "/usr/lib/python2.7/site-packages/neutron/agent/linux/async_process.py", ...odule>
Jan 07 02:45:15 node2-compute neutron-openvswitch-agent[3471]: import psutil
Jan 07 02:45:15 node2-compute neutron-openvswitch-agent[3471]: ImportError: No module named psutil
Jan 07 02:45:15 node2-compute systemd[1]: neutron-openvswitch-agent.service: main process exited, code=exited, status=1/FAILURE
Jan 07 02:45:15 node2-compute systemd[1]: Unit neutron-openvswitch-agent.service entered failed state.
Hint: Some lines were ellipsized, use -l to show in full.
[root@node2-compute ~]# systemctl status neutron-openvswitch-agent -l
neutron-openvswitch-agent.service - OpenStack Quantum Open vSwitch Agent
   Loaded: loaded (/usr/lib/systemd/system/neutron-openvswitch-agent.service; enabled)
[. . .]


Expected results
----------------

On upgrade, openstack-neutron should pull in the python-psutil 
dependency. Restart of neutron-openvswitch-agent should be successful.


Additional info
---------------

I checked in Fedora git for Neutron master branch, for 'Requires' on
python-psutil, it's not present:

    $ git branch
    * master
    
    $ git log | head -1
    commit be96ca650ad6c02310875491d68bb64f139da543

    $ egrep -i 'Requires.*python-psutil' openstack-neutron.spec 
    $ echo $?
    1

--- Additional comment from Kashyap Chamarthy on 2014-01-07 04:40:11 EST ---

This was brought in with this change:

  https://review.openstack.org/#/c/53188/10/requirements.txt

  psutil>=0.6.1,<1.0

--- Additional comment from Pádraig Brady on 2014-01-07 06:14:36 EST ---

I see neutron-openvswitch-agent failing in CI also. thanks

Comment 3 Terry Wilson 2014-01-24 06:37:52 UTC
The change that caused this issue was going to be backported to havana, but now it looks like we may be removing the dependency upstream even for icehouse. Will keep this updated.

Comment 4 Terry Wilson 2014-01-28 17:29:32 UTC
Added gerrit review for removing psutil dependency upstream.

Comment 5 Terry Wilson 2014-03-03 15:15:29 UTC
psutil dependency has been removed upstream.