Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RDO tickets are now tracked in Jira https://issues.redhat.com/projects/RDO/issues/

Bug 929370

Summary: grizzly: problem in creating a working installation of openstack using openstack-demo-install script
Product: [Community] RDO Reporter: Gabriel Staicu <gabriel_staicu>
Component: openstack-utilsAssignee: Alan Pevec <apevec>
Status: CLOSED CURRENTRELEASE QA Contact: Ami Jeain <ajeain>
Severity: medium Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: apevec, apevec, ayoung, bfilippov, breu, d.busby, Jan.van.Eldik, jkt, jonathansteffan, jose.castro.leon, markmc, pbrady, p, rbryant, yeylon
Target Milestone: RC   
Target Release: Grizzly   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-09-17 15:45:11 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
proposed patch for openstack-demo-install p: review+

Description Gabriel Staicu 2013-03-30 00:54:12 UTC
Description of problem:
openstack-demo-install script fail to produce a working installation because of the content in the file /usr/share/openstack-keystone/sample_data.sh which is a part of the package openstack-keystone-2013.1-0.9.rc2.el6.src.rpm

Version-Release number of selected component (if applicable):
openstack-keystone-2013.1-0.9.rc2.el6.src.rpm 

How reproducible:
always

Steps to Reproduce:
1. add the repository for epel on running centos64
2. add the repository for grizzly packages which I found here http://repos.fedorapeople.org/repos/openstack/openstack-grizzly/epel-6/?C=M;O=D
3. yum install openstack-utils
4. openstack-demo-install
  
Actual results:
the install doesn't produce a working openstack 

Expected results:
working installation of openstack

Additional info:
I observed that there is a difference between the /usr/share/openstack-keystone/sample_data.sh for folsom and grizzly. I think that the file in the grizzly release is incomplete because if replace the file from grizzly with that from folsom the installation works.

Comment 2 Adam Young 2013-03-31 19:43:41 UTC
Please provide the differences that you think are responsible.  What is actually failing?

Comment 3 Alan Pevec 2013-03-31 22:07:11 UTC
> openstack-demo-install script fail to produce a working installation because
> of the content in the file /usr/share/openstack-keystone/sample_data.sh

This is a verbatim copy of upstream tools/sample_data.sh
which was modified in https://github.com/openstack/keystone/commit/d6f7cbc484868bdec3eeb9d4b0f45b10ce536e79

Comment 4 Gabriel Staicu 2013-04-01 00:05:07 UTC
the difference in behavior I observe is:

1) sample_data.sh corresponding to folsom after I source keystonerc with the following content generated automatically by the script openstack-demo-install:
export OS_USERNAME=admin
export OS_PASSWORD=verybadpass
export OS_TENANT_NAME=admin
export OS_AUTH_URL=http://127.0.0.1:5000/v2.0/

 
[root@centos64-grizzly ~]# nova list
ERROR: Invalid OpenStack Nova credentials.
[root@centos64-grizzly ~]# 

also

[root@centos64-grizzly ~]# keystone tenant-list
Unable to communicate with identity service: {"error": {"message": "The request you have made requires authentication.", "code": 401, "title": "Not Authorized"}}. (HTTP 401)
[root@centos64-grizzly ~]#

After I read the commentary of Alan Pevec and look to the change list I modified the keystonerc to the following:
export OS_USERNAME=admin
export OS_PASSWORD=secrete
export OS_TENANT_NAME=demo
export OS_AUTH_URL=http://127.0.0.1:5000/v2.0/

the result was:
[root@centos64-grizzly ~]# keystone tenant-list
+----------------------------------+---------+---------+
|                id                |   name  | enabled |
+----------------------------------+---------+---------+
| f0066e20f50645a7a3efd7f7044c3ebb |   demo  |   True  |
| b896ab02732b46be8c567260b03bd358 | service |   True  |
+----------------------------------+---------+---------+



2) sample_data.sh corresponding to folsom after I source keystonerc with the following content:
export OS_USERNAME=admin
export OS_PASSWORD=verybadpass
export OS_TENANT_NAME=admin
export OS_AUTH_URL=http://127.0.0.1:5000/v2.0/

[root@centos64-grizzly ~]# nova list

[root@centos64-grizzly ~]# 

also

[root@centos64-grizzly keystone]# keystone tenant-list
+----------------------------------+--------------------+---------+
|                id                |        name        | enabled |
+----------------------------------+--------------------+---------+
| 33e0df66abe0422ea6f491aefb82cda8 |       admin        |   True  |
| fa00aec720bc4b1f93c36f0a7a0148dd |        demo        |   True  |
| 19370be3bfd1431798786696cf5ae432 | invisible_to_admin |   True  |
| add41ea9fead4cd68f318fc0722de2d0 |      service       |   True  |
+----------------------------------+--------------------+---------+


Based on my observations till now I think the problem is either in sample_data.sh either in the generated content of the keystonerc.

Comment 5 Adam Young 2013-04-01 19:10:05 UTC
Not 100% clear if there is a real problem, or if you just didn't source keystonerc before executing the nova command.  However, either sample_data.sh should produce a workable system, just that the contents of the keystonerc file need to match what what used in the sample_data.sh file.  It sounds like the code for generating keystonerc is out of sync with the sample data, but it is the generation code that needs to be updated.  Reassigning back to Paidrig.

Comment 6 Gabriel Staicu 2013-04-01 19:42:59 UTC
I sourced the resulted keystonerc before running any keystone or nova commands

Comment 7 Alan Pevec 2013-04-01 22:37:06 UTC
(In reply to comment #5)
> It sounds like the code for generating keystonerc is out of sync with the
> sample data, but it is the generation code that needs to be updated. 

sample_data.sh kind of changed "contract" - it ignores ADMIN_PASSWORD and SERVICE_PASSWORD env vars which openstack-demo-install was relying on, all passwords are now hardcoded:
admin/secrete
nova/nova
glance/glance
swift/swiftpass
and admin's default tenant is 'demo'.

Comment 8 Alan Pevec 2013-04-01 22:55:02 UTC
Created attachment 730504 [details]
proposed patch for openstack-demo-install

Comment 9 Pádraig Brady 2013-04-02 02:05:46 UTC
Comment on attachment 730504 [details]
proposed patch for openstack-demo-install

Looks good, thanks!
https://github.com/redhat-openstack/openstack-utils/commit/17d6ea

Comment 10 Pádraig Brady 2013-09-17 15:45:11 UTC
The fix for this was released to RDO grizzly in 2013.1-3