[Openstack-operators] Glance issues after rdo icehouse -> juno

Kris G. Lindgren klindgren at godaddy.com
Mon Mar 23 15:15:46 UTC 2015


What does the [database] section of the configs look like?

Not only was the string changed but it was moved from the Default section to [database]:
# The SQLAlchemy connection string used to connect to the
# database (string value)
# Deprecated group/name - [DEFAULT]/sql_connection
# Deprecated group/name - [DATABASE]/sql_connection
# Deprecated group/name - [sql]/connection
#connection = <None>
____________________________________________

Kris Lindgren
Senior Linux Systems Engineer
GoDaddy, LLC.


From: Nathan Stratton <nathan at robotics.net<mailto:nathan at robotics.net>>
Date: Monday, March 23, 2015 at 8:50 AM
To: "openstack-oper." <openstack-operators at lists.openstack.org<mailto:openstack-operators at lists.openstack.org>>
Subject: [Openstack-operators] Glance issues after rdo icehouse -> juno

Followed:
http://docs.openstack.org/openstack-ops/content/upgrade-icehouse-juno.html

On the surface everything looked great, I can do a glance image-list, can import an image into glance, but I can't cinder create from glance --image-id. I get the following error:

2015-03-23 10:35:57.703 2954 INFO urllib3.connectionpool [-] Starting new HTTP connection (1): 10.71.0.218
2015-03-23 10:35:57.719 2954 INFO keystonemiddleware.auth_token [-] Auth Token confirmed use of v3.0 apis
2015-03-23 10:35:58.129 2954 INFO glance.wsgi.server [44e7b400-64bc-4042-a699-7bf6ed7118e5 b4397deb6a884a8c8e70fbc255ce6d80 0ebcdedac0a3480
ca81050bfedd97cf1 - - -] Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/eventlet/wsgi.py", line 433, in handle_one_response
    result = self.application(self.environ, start_response)
  File "/usr/lib/python2.7/site-packages/webob/dec.py", line 130, in __call__
    resp = self.call_func(req, *args, **self.kwargs)
  File "/usr/lib/python2.7/site-packages/webob/dec.py", line 195, in call_func
    return self.func(req, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/glance/common/wsgi.py", line 394, in __call__
    response = req.get_response(self.application)
  File "/usr/lib/python2.7/site-packages/webob/request.py", line 1296, in send
    application, catch_exc_info=False)
  File "/usr/lib/python2.7/site-packages/webob/request.py", line 1260, in call_application
    app_iter = application(self.environ, start_response)
  File "/usr/lib/python2.7/site-packages/webob/dec.py", line 130, in __call__
    resp = self.call_func(req, *args, **self.kwargs)
  File "/usr/lib/python2.7/site-packages/webob/dec.py", line 195, in call_func
    return self.func(req, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/osprofiler/web.py", line 99, in __call__
    return request.get_response(self.application)
  File "/usr/lib/python2.7/site-packages/webob/request.py", line 1296, in send
    application, catch_exc_info=False)
  File "/usr/lib/python2.7/site-packages/webob/request.py", line 1260, in call_application
    app_iter = application(self.environ, start_response)
  File "/usr/lib/python2.7/site-packages/keystonemiddleware/auth_token.py", line 748, in __call__
    return self._call_app(env, start_response)
  File "/usr/lib/python2.7/site-packages/keystonemiddleware/auth_token.py", line 684, in _call_app
    return self._app(env, _fake_start_response)
  File "/usr/lib/python2.7/site-packages/webob/dec.py", line 130, in __call__
    resp = self.call_func(req, *args, **self.kwargs)
  File "/usr/lib/python2.7/site-packages/webob/dec.py", line 195, in call_func
    return self.func(req, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/glance/common/wsgi.py", line 394, in __call__
    response = req.get_response(self.application)
  File "/usr/lib/python2.7/site-packages/webob/request.py", line 1296, in send
    application, catch_exc_info=False)
  File "/usr/lib/python2.7/site-packages/webob/request.py", line 1260, in call_application
    app_iter = application(self.environ, start_response)
  File "/usr/lib/python2.7/site-packages/paste/urlmap.py", line 203, in __call__
    return app(environ, start_response)
  File "/usr/lib/python2.7/site-packages/webob/dec.py", line 144, in __call__
    return resp(environ, start_response)
  File "/usr/lib/python2.7/site-packages/routes/middleware.py", line 131, in __call__
    response = self.app(environ, start_response)
  File "/usr/lib/python2.7/site-packages/webob/dec.py", line 144, in __call__
    return resp(environ, start_response)
  File "/usr/lib/python2.7/site-packages/webob/dec.py", line 130, in __call__
    resp = self.call_func(req, *args, **self.kwargs)
  File "/usr/lib/python2.7/site-packages/webob/dec.py", line 195, in call_func
    return self.func(req, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/glance/common/wsgi.py", line 683, in __call__
    request, **action_args)
  File "/usr/lib/python2.7/site-packages/glance/common/wsgi.py", line 707, in dispatch
    return method(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/glance/api/v2/images.py", line 111, in show
    return image_repo.get(image_id)
  File "/usr/lib/python2.7/site-packages/glance/api/authorization.py", line 106, in get
    image = self.image_repo.get(image_id)
  File "/usr/lib/python2.7/site-packages/glance/domain/proxy.py", line 86, in get
    return self.helper.proxy(self.base.get(item_id))
  File "/usr/lib/python2.7/site-packages/glance/api/policy.py", line 179, in get
    return super(ImageRepoProxy, self).get(image_id)
  File "/usr/lib/python2.7/site-packages/glance/domain/proxy.py", line 86, in get
    return self.helper.proxy(self.base.get(item_id))
  File "/usr/lib/python2.7/site-packages/glance/domain/proxy.py", line 86, in get
    return self.helper.proxy(self.base.get(item_id))
  File "/usr/lib/python2.7/site-packages/glance/domain/proxy.py", line 86, in get
    return self.helper.proxy(self.base.get(item_id))
  File "/usr/lib/python2.7/site-packages/glance/db/__init__.py", line 67, in get
    db_api_image = dict(self.db_api.image_get(self.context, image_id))
  File "/usr/lib/python2.7/site-packages/glance/db/sqlalchemy/api.py", line 191, in image_get
    force_show_deleted=force_show_deleted)
  File "/usr/lib/python2.7/site-packages/glance/db/sqlalchemy/api.py", line 214, in _image_get
    session = session or get_session()
  File "/usr/lib/python2.7/site-packages/glance/db/sqlalchemy/api.py", line 97, in get_session
    facade = _create_facade_lazily()
  File "/usr/lib/python2.7/site-packages/glance/db/sqlalchemy/api.py", line 82, in _create_facade_lazily
    _FACADE = session.EngineFacade.from_config(CONF)
  File "/usr/lib/python2.7/site-packages/oslo/db/sqlalchemy/session.py", line 816, in from_config
    retry_interval=conf.database.retry_interval)
  File "/usr/lib/python2.7/site-packages/oslo/db/sqlalchemy/session.py", line 732, in __init__
    **engine_kwargs)
  File "/usr/lib/python2.7/site-packages/oslo/db/sqlalchemy/session.py", line 409, in create_engine
    _test_connection(engine, max_retries, retry_interval)
  File "/usr/lib/python2.7/site-packages/oslo/db/sqlalchemy/session.py", line 549, in _test_connection
    return exc_filters.handle_connect_error(engine)
  File "/usr/lib/python2.7/site-packages/oslo/db/sqlalchemy/exc_filters.py", line 351, in handle_connect_error
    handler(ctx)
  File "/usr/lib/python2.7/site-packages/oslo/db/sqlalchemy/exc_filters.py", line 323, in handler
    context.is_disconnect)
  File "/usr/lib/python2.7/site-packages/oslo/db/sqlalchemy/exc_filters.py", line 254, in _raise_operational_errors_directly_filter
    raise operational_error
OperationalError: (OperationalError) (1045, "Access denied for user 'glance'@'localhost' (using password: YES)") None None

I also found I can't even do a simple glance-manage db_sync because of the same error:

2015-03-23 10:36:28.212 3497 CRITICAL glance [-] OperationalError: (OperationalError) (1045, "Access denied for user 'glance'@'localhost' (
using password: YES)") None None
2015-03-23 10:36:28.212 3497 TRACE glance Traceback (most recent call last):
2015-03-23 10:36:28.212 3497 TRACE glance   File "/usr/bin/glance-manage", line 10, in <module>
2015-03-23 10:36:28.212 3497 TRACE glance     sys.exit(main())
2015-03-23 10:36:28.212 3497 TRACE glance   File "/usr/lib/python2.7/site-packages/glance/cmd/manage.py", line 279, in main
2015-03-23 10:36:28.212 3497 TRACE glance     return CONF.command.action_fn()
2015-03-23 10:36:28.212 3497 TRACE glance   File "/usr/lib/python2.7/site-packages/glance/cmd/manage.py", line 157, in sync
2015-03-23 10:36:28.212 3497 TRACE glance     CONF.command.current_version)
2015-03-23 10:36:28.212 3497 TRACE glance   File "/usr/lib/python2.7/site-packages/glance/cmd/manage.py", line 113, in sync
2015-03-23 10:36:28.212 3497 TRACE glance     migration.db_sync(db_api.get_engine(),
2015-03-23 10:36:28.212 3497 TRACE glance   File "/usr/lib/python2.7/site-packages/glance/db/sqlalchemy/api.py", line 92, in get_engine
2015-03-23 10:36:28.212 3497 TRACE glance     facade = _create_facade_lazily()
2015-03-23 10:36:28.212 3497 TRACE glance   File "/usr/lib/python2.7/site-packages/glance/db/sqlalchemy/api.py", line 82, in _create_facade
_lazily
2015-03-23 10:36:28.212 3497 TRACE glance     _FACADE = session.EngineFacade.from_config(CONF)
2015-03-23 10:36:28.212 3497 TRACE glance   File "/usr/lib/python2.7/site-packages/oslo/db/sqlalchemy/session.py", line 816, in from_config
2015-03-23 10:36:28.212 3497 TRACE glance     retry_interval=conf.database.retry_interval)
2015-03-23 10:36:28.212 3497 TRACE glance   File "/usr/lib/python2.7/site-packages/oslo/db/sqlalchemy/session.py", line 732, in __init__
2015-03-23 10:36:28.212 3497 TRACE glance     **engine_kwargs)
2015-03-23 10:36:28.212 3497 TRACE glance   File "/usr/lib/python2.7/site-packages/oslo/db/sqlalchemy/session.py", line 409, in create_engi
ne
2015-03-23 10:36:28.212 3497 TRACE glance     _test_connection(engine, max_retries, retry_interval)
2015-03-23 10:36:28.212 3497 TRACE glance   File "/usr/lib/python2.7/site-packages/oslo/db/sqlalchemy/session.py", line 549, in _test_conne
ction
2015-03-23 10:36:28.212 3497 TRACE glance     return exc_filters.handle_connect_error(engine)
2015-03-23 10:36:28.212 3497 TRACE glance   File "/usr/lib/python2.7/site-packages/oslo/db/sqlalchemy/exc_filters.py", line 351, in handle_
connect_error
2015-03-23 10:36:28.212 3497 TRACE glance     handler(ctx)
2015-03-23 10:36:28.212 3497 TRACE glance   File "/usr/lib/python2.7/site-packages/oslo/db/sqlalchemy/exc_filters.py", line 323, in handler
2015-03-23 10:36:28.212 3497 TRACE glance     context.is_disconnect)
2015-03-23 10:36:28.212 3497 TRACE glance   File "/usr/lib/python2.7/site-packages/oslo/db/sqlalchemy/exc_filters.py", line 254, in _raise_
operational_errors_directly_filter
2015-03-23 10:36:28.212 3497 TRACE glance     raise operational_error
2015-03-23 10:36:28.212 3497 TRACE glance OperationalError: (OperationalError) (1045, "Access denied for user 'glance'@'localhost' (using p
assword: YES)") None None
2015-03-23 10:36:28.212 3497 TRACE glance

This all looks like sql issues, so I started digging and found that sql_connection was changed to just connection so I made that change in glance-api.conf and glance-registry.conf so it now looks like:

connection=mysql://glance:be801f9b56ea40f4@10.71.0.218/glance<http://glance:be801f9b56ea40f4@10.71.0.218/glance>

If btw, I try connecting to mysql with that pass everything is fine:

[root at nathan glance(keystone)]# mysql -uglance -pbe801f9b56ea40f4 -h10.71.0.218
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 66
Server version: 5.5.40-MariaDB-wsrep MariaDB Server, wsrep_25.11.r4026

Copyright (c) 2000, 2014, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]>



><>
nathan stratton | vp technology | broadsoft, inc | +1-240-404-6580 | www.broadsoft.com<http://www.broadsoft.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-operators/attachments/20150323/9807d220/attachment.html>


More information about the OpenStack-operators mailing list