nova-consoleauth memcached

Bug #1213660 reported by Federico Iezzi
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Undecided
Liyingjun
oslo-incubator
Fix Released
Medium
Liyingjun

Bug Description

Hello Guys,

If memcached doesn't respond there isn't any error messages

https://github.com/openstack/nova/blob/stable/grizzly/nova/consoleauth/manager.py#L85

Looking the code I found this problem in my environment but looking the logs seems that there is memcached.

Regards,
Federico

Tags: console
tags: added: consoleauth
Revision history for this message
Russell Bryant (russellb) wrote :

Did you actually hit this error? I would actually expect a traceback in the nova-consoleauth log if it fails based on that code.

Changed in nova:
status: New → Incomplete
Revision history for this message
Federico Iezzi (fiezzi) wrote :

If memcached is missing, nova-consoleauth doesn't send any traceback

Allison Randal (allison)
tags: added: console
removed: consoleauth
Revision history for this message
Scott Devoid (scott-devoid) wrote :

Bug is in openstack.common.memorycache:
https://github.com/openstack/nova/blob/stable/grizzly/nova/openstack/common/memorycache.py

Specifically get_client should not pass on ImportError since the CONF declared memcached_servers.

def get_client(memcached_servers=None):
    client_cls = Client

    if not memcached_servers:
        memcached_servers = CONF.memcached_servers
    if memcached_servers:
        try:
            import memcache
            client_cls = memcache.Client
        except ImportError:
            pass

Changed in nova:
status: Incomplete → Confirmed
Changed in oslo:
importance: Undecided → Medium
status: New → Triaged
Liyingjun (liyingjun)
Changed in oslo:
assignee: nobody → Liyingjun (liyingjun)
Changed in nova:
assignee: nobody → Liyingjun (liyingjun)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (master)

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

Changed in nova:
status: Confirmed → In Progress
Revision history for this message
Openstack Gerrit (openstack-gerrit) wrote : Fix proposed to oslo-incubator (master)

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

Changed in oslo:
status: Triaged → In Progress
Revision history for this message
ChangBo Guo(gcb) (glongwave) wrote :

memcache is not in requirements.txt for nova and oslo-incubator, that means memcahe might be missing.
From the original commit https://github.com/openstack/oslo-incubator/commit/844123e2197358a2aeb39feb7275305f55b03e38. It behaves as memory cache if missing package memcache, That seems reasonable. What's the best solution for this , add log warning here ?

Revision history for this message
Scott Devoid (scott-devoid) wrote :

I replied to the review, but I think it should still be an error since it would only fail after memcached_servers was set in a config.

Revision history for this message
ChangBo Guo(gcb) (glongwave) wrote :

@Scott Devoid,
agreed,

Revision history for this message
Openstack Gerrit (openstack-gerrit) wrote : Fix merged to oslo-incubator (master)

Reviewed: https://review.openstack.org/87822
Committed: https://git.openstack.org/cgit/openstack/oslo-incubator/commit/?id=297d772b780db18dd4debc23dddef089f4ba8b7a
Submitter: Jenkins
Branch: master

commit 297d772b780db18dd4debc23dddef089f4ba8b7a
Author: liyingjun <email address hidden>
Date: Tue Apr 15 23:17:07 2014 +0800

    Raise exception when importing memcache error

    Remove the exception handle and let the ImportError propagate out. This
    will provide all of the information that a user would need to figure
    out what's wrong.

    Change-Id: I0e608ee15a0826e28dceb162d71d9a1191f0723d
    Closes-bug: 1213660

Changed in oslo:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/87565
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=39678234ba2be9ac1f9bc142b44cbc8113817218
Submitter: Jenkins
Branch: master

commit 39678234ba2be9ac1f9bc142b44cbc8113817218
Author: liyingjun <email address hidden>
Date: Mon Apr 14 23:54:46 2014 +0800

    Handle situation when key not memcached

    LOG a warning message if the key not memcached successful. This will
    happen if memcached module is used but the memcached servers are not
    reachable.

    Change-Id: Ia3c51fe8fc82060586a014f5cb1083d5695ab455
    Closes-bug: 1213660

Changed in nova:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in nova:
milestone: none → juno-1
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in oslo:
milestone: none → juno-1
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: juno-1 → 2014.2
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.