tests fail when run with noexec /tmp

Bug #1359463 reported by Gregory Haynes
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ironic
Fix Released
Low
Vladyslav Drok

Bug Description

I am given the following traceback for some tests when I run them on a system with a noexec /tmp

Traceback (most recent call last):
  File "/home/greghaynes/tripleo/ironic/.tox/py27/local/lib/python2.7/site-packages/eventlet/hubs/hub.py", line 449, in fire_timers
    timer()
  File "/home/greghaynes/tripleo/ironic/.tox/py27/local/lib/python2.7/site-packages/eventlet/hubs/timer.py", line 58, in __call__
    cb(*args, **kw)
  File "/home/greghaynes/tripleo/ironic/.tox/py27/local/lib/python2.7/site-packages/eventlet/greenthread.py", line 207, in main
    result = function(*args, **kwargs)
TypeError: <lambda>() takes no arguments (1 given)
Traceback (most recent call last):
  File "/home/greghaynes/tripleo/ironic/.tox/py27/local/lib/python2.7/site-packages/eventlet/hubs/hub.py", line 449, in fire_timers
    timer()
  File "/home/greghaynes/tripleo/ironic/.tox/py27/local/lib/python2.7/site-packages/eventlet/hubs/timer.py", line 58, in __call__
    cb(*args, **kw)
  File "/home/greghaynes/tripleo/ironic/.tox/py27/local/lib/python2.7/site-packages/eventlet/greenthread.py", line 207, in main
    result = function(*args, **kwargs)
  File "/home/greghaynes/tripleo/ironic/ironic/tests/conductor/test_task_manager.py", line 500, in func
    raise Exception()
Exception
Traceback (most recent call last):
  File "/home/greghaynes/tripleo/ironic/.tox/py27/local/lib/python2.7/site-packages/eventlet/queue.py", line 114, in switch
    self.greenlet.switch(value)
  File "/home/greghaynes/tripleo/ironic/.tox/py27/local/lib/python2.7/site-packages/eventlet/greenthread.py", line 207, in main
    result = function(*args, **kwargs)
  File "/home/greghaynes/tripleo/ironic/ironic/tests/conductor/test_task_manager.py", line 485, in func
    raise Exception()
Exception
INFO [alembic.migration] Context impl SQLiteImpl.
INFO [alembic.migration] Will assume non-transactional DDL.
INFO [alembic.migration] Context impl SQLiteImpl.
INFO [alembic.migration] Will assume non-transactional DDL.
======================================================================
ERROR: test_utils.ExecuteTestCase.test_no_retry_on_success
----------------------------------------------------------------------
Empty attachments:
  pythonlogging:''

Traceback (most recent call last):
  File "/home/greghaynes/tripleo/ironic/ironic/tests/test_utils.py", line 103, in test_retry_on_failure
    delay_on_retry=False)
  File "/home/greghaynes/tripleo/ironic/.tox/py27/local/lib/python2.7/site-packages/testtools/testcase.py", line 393, in assertRaises
    self.assertThat(our_callable, matcher)
  File "/home/greghaynes/tripleo/ironic/.tox/py27/local/lib/python2.7/site-packages/testtools/testcase.py", line 404, in assertThat
    mismatch_error = self._matchHelper(matchee, matcher, message, verbose)
  File "/home/greghaynes/tripleo/ironic/.tox/py27/local/lib/python2.7/site-packages/testtools/testcase.py", line 454, in _matchHelper
    mismatch = matcher.match(matchee)
  File "/home/greghaynes/tripleo/ironic/.tox/py27/local/lib/python2.7/site-packages/testtools/matchers/_exception.py", line 108, in match
    mismatch = self.exception_matcher.match(exc_info)
  File "/home/greghaynes/tripleo/ironic/.tox/py27/local/lib/python2.7/site-packages/testtools/matchers/_higherorder.py", line 62, in match
    mismatch = matcher.match(matchee)
  File "/home/greghaynes/tripleo/ironic/.tox/py27/local/lib/python2.7/site-packages/testtools/testcase.py", line 385, in match
    reraise(*matchee)
  File "/home/greghaynes/tripleo/ironic/.tox/py27/local/lib/python2.7/site-packages/testtools/matchers/_exception.py", line 101, in match
    result = matchee()
  File "/home/greghaynes/tripleo/ironic/.tox/py27/local/lib/python2.7/site-packages/testtools/testcase.py", line 902, in __call__
    return self._callable_object(*self._args, **self._kwargs)
  File "ironic/common/utils.py", line 63, in execute
    result = processutils.execute(*cmd, **kwargs)
  File "ironic/openstack/common/processutils.py", line 175, in execute
    env=env_variables)
  File "/home/greghaynes/tripleo/ironic/.tox/py27/local/lib/python2.7/site-packages/eventlet/green/subprocess.py", line 45, in __init__
    subprocess_orig.Popen.__init__(self, args, 0, *argss, **kwds)
  File "/usr/lib/python2.7/subprocess.py", line 710, in __init__
    errread, errwrite)
  File "/usr/lib/python2.7/subprocess.py", line 1327, in _execute_child
    raise child_exception
OSError: [Errno 13] Permission denied

We should either be passing or failing with a more graceful error message in this situation.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to ironic (master)

Fix proposed to branch: master
Review: https://review.openstack.org/115827

Changed in ironic:
assignee: nobody → Gregory Haynes (greghaynes)
status: New → In Progress
Dmitry Tantsur (divius)
Changed in ironic:
importance: Undecided → Low
Changed in ironic:
assignee: Gregory Haynes (greghaynes) → Vladyslav Drok (vdrok)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to ironic (master)

Reviewed: https://review.openstack.org/115827
Committed: https://git.openstack.org/cgit/openstack/ironic/commit/?id=e6ac648e41f6316b81bdc3d7aec8fd86f7857efa
Submitter: Jenkins
Branch: master

commit e6ac648e41f6316b81bdc3d7aec8fd86f7857efa
Author: Gregory Haynes <email address hidden>
Date: Wed Aug 20 17:16:37 2014 -0700

    More helpful failure for tests on noexec /tmp

    When tests are run with a noexec /tmp they may can fail with a
    not-so-clear error message. Making this more clear.

    Closes-Bug: #1359463
    Change-Id: I67086c960dd249a88680958a3f8aaba54db1e691

Changed in ironic:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in ironic:
milestone: none → kilo-1
status: Fix Committed → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to ironic-python-agent (master)

Related fix proposed to branch: master
Review: https://review.openstack.org/144294

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to ironic-python-agent (master)

Reviewed: https://review.openstack.org/144294
Committed: https://git.openstack.org/cgit/openstack/ironic-python-agent/commit/?id=fa0e710a40b2362928a9a78e860d72cd20697ffd
Submitter: Jenkins
Branch: master

commit fa0e710a40b2362928a9a78e860d72cd20697ffd
Author: Vladyslav Drok <email address hidden>
Date: Mon Dec 29 14:17:41 2014 +0200

    Skip failing execute tests when using /tmp noexec

    test_retry_on_failure and test_no_retry_on_success from
    ExecuteTestCase are failing when running system with /tmp noexec.
    These tests should be skipped in this case.

    Related-bug: #1359463
    Change-Id: I32fa8f90a6292229bd23eec6d648fab617e59ec3

Thierry Carrez (ttx)
Changed in ironic:
milestone: kilo-1 → 2015.1.0
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.