Reviewed: https://review.openstack.org/300131 Committed: https://git.openstack.org/cgit/openstack/keystone/commit/?id=32203d4951f951c6423a9de6dd04a47bcffe40b5 Submitter: Jenkins Branch: master
commit 32203d4951f951c6423a9de6dd04a47bcffe40b5 Author: Colleen Murphy <[email protected]> Date: Thu Mar 31 10:47:02 2016 -0700 Add logging to cli if keystone.conf is not found If keystone.conf is not found at one of ./etc/keystone.conf, ~/.keystone/keystone.conf, ~/keystone.conf, /etc/keystone/keystone.conf, or /etc/keystone.conf, the keystone-manage command will use defaults configured in keystone.common.config[1] (or elsewhere, e.g. keystone.common.sql.core[2]). If it does not find a default value for a parameter it needs to use, it will error at that point (for example, the samp_idp_metadata command errors when idp_entity_id is not set). However, if all of the parameters it is using have default values, which is the case for commands like db_sync and ssl_setup, keystone-manage will silently proceed with those defaults. This is not obvious to the user, who may have misplaced the keystone.conf or is lacking permissions to read keystone.conf. This patch adds a warning that will notify the user if it can't find the config file, but otherwise proceeds as normal. Why not fix this in oslo.config? The behavior of silently continuing if config files aren't found is longstanding, so changing that behavior would probably not be backwards-compatible. Moreover, other projects might want to handle this differently or not handle it at all. [1] http://git.openstack.org/cgit/openstack/keystone/tree/keystone/common/config.py [2] http://git.openstack.org/cgit/openstack/keystone/tree/keystone/common/sql/core.py#n73 Closes-bug: #1273273 Change-Id: I276c671a0da78e3d1d2aa7336e55f65be41d8cca ** Changed in: keystone Status: In Progress => Fix Released -- You received this bug notification because you are a member of Yahoo! Engineering Team, which is subscribed to OpenStack Identity (keystone). https://bugs.launchpad.net/bugs/1273273 Title: keystone-manage should produce a friendlier error when it cannot read the config files Status in OpenStack Identity (keystone): Fix Released Bug description: below is the detail: i have setup keystone database in mysql and grant all privilege to the keystone user when i execute 'keystone-manage db_sync' peter@openstack:~$ keystone-manage db_sync peter@openstack:~$ but actually , in mysql no tables will be create in keystone database [there should be a error to indicate user that no tables created due to not enough privilege] only when : peter@openstack:~$ sudo keystone-manage db_sync peter@openstack:~$ all tables will created in keystone database correctly. summary: if a prompt displayed, that will be very usefully for user to proceed installing keystone successfully To manage notifications about this bug go to: https://bugs.launchpad.net/keystone/+bug/1273273/+subscriptions -- Mailing list: https://launchpad.net/~yahoo-eng-team Post to : [email protected] Unsubscribe : https://launchpad.net/~yahoo-eng-team More help : https://help.launchpad.net/ListHelp

