yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #33630
[Bug 1463447] Re: Incorrect column name in Endpoint class in keystone/catalog/backends/sql.py
In my devstack environment, table endpoint has 'region_id', not
'region'.
mysql> describe endpoint;
+--------------------+--------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+--------------------+--------------+------+-----+---------+-------+
| id | varchar(64) | NO | PRI | NULL | |
| legacy_endpoint_id | varchar(64) | YES | | NULL | |
| interface | varchar(8) | NO | | NULL | |
| service_id | varchar(64) | NO | MUL | NULL | |
| url | text | NO | | NULL | |
| extra | text | YES | | NULL | |
| enabled | tinyint(1) | NO | | 1 | |
| region_id | varchar(255) | YES | MUL | NULL | |
+--------------------+--------------+------+-----+---------+-------+
8 rows in set (0.00 sec)
It looks like you didn't upgrade your db schema before creating
endpoint. Please look at
keystone/common/sql/migrate_repo/versions/053_endpoint_to_region_association.py:
Migrated the endpoint 'region' column to 'region_id.
** Changed in: keystone
Assignee: (unassigned) => Zhenzan Zhou (zhenzan-zhou)
** Changed in: keystone
Status: New => Invalid
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Keystone.
https://bugs.launchpad.net/bugs/1463447
Title:
Incorrect column name in Endpoint class in
keystone/catalog/backends/sql.py
Status in OpenStack Identity (Keystone):
Invalid
Bug description:
I've faced this problem while trying to follow this tutorial:
http://docs.openstack.org/kilo/install-guide/install/apt/content/keystone-install.html
So, I've created db for keystone, and then try to make 'openstack endpoint create' to populate table 'endpoint' inside
'keystone' database. As I can see from mysql shell - there is column named 'region' inside table 'endpoint':
http://imgur.com/a/L4GuW
But:
As one can see in https://github.com/openstack/keystone/blob/master/keystone/catalog/backends/sql.py
attributes of Endpoint class are ['id', 'interface', 'region_id', 'service_id', 'url', 'legacy_endpoint_id', 'enabled']. So 'region_id' is among them. I think it's a bug, because, when i'm trying to make openstack endpoint create, i'm getting this error inside /var/log/apache2/keystone-error.log:
2015-06-09 09:29:06.354991 2015-06-09 09:29:06.353 1153 TRACE keystone.common.wsgi Traceback (most recent call last):
...
...
OperationalError: (OperationalError) (1054, "Unknown column 'region_id' in 'field list'") 'INSERT INTO endpoint (id, legacy_endpoint_id, interface, region_id, service_id, url, enabled, extra) VALUES (%s, %s, %s, %s, %s, %s, %s, %s)' ('7df45cff79a6419a80ba22902494c7d3', '903840e1b95e4649b9eef739f26ca249', 'admin', None, '6cde7e716f6945428b0ee91db0c76a77', 'http://controller:35357/v2.0', 1, '{}')
So, maybe 'region_id' inside sql.py should be just 'region'?
To manage notifications about this bug go to:
https://bugs.launchpad.net/keystone/+bug/1463447/+subscriptions