Unable to upload the image to the Image Service (Juno)

asked 2015-07-07 03:19:29 -0500

Kevin Bratek gravatar image

updated 2015-07-07 03:22:07 -0500

Hello, i'm new to Openstack and trying to build my own Openstack-environment. After following the "OpenStack Installation Guide for Red Hat Enterprise Linux 7, CentOS 7, and Fedora 20" (on Fedora 21), I faced a problem at uploading cirrOS to the Image-Service.

My Openstack-version, refering to this command: "[root@localhost ~]# keystone-manage --version" should be 2014.2.2

After I try to upload the image I get this output:

ADMIN-OPENRC.SH:

export OS_TENANT_NAME=admin
export OS_USERNAME=admin
export OS_PASSWORD=MYPASS
export OS_AUTH_URL=http://controller:35357/v2.0

[root@localhost ~]# source admin-openrc.sh [root@localhost ~]# glance --debug image-create --name "cirros-0.3.3-x86_64" --file /tmp/images/cirros-0.3.3-x86_64-disk.img --disk-format qcow2 --container-format bare --is-public True --progress curl -i -X POST -H 'Accept-Encoding: gzip, deflate' -H 'x-image-meta-container_format: bare' -H 'Accept: /' -H 'X-Auth-Token: {SHA1}726116102202fa50ff0c064ca3cadb86b65fe997' -H 'x-image-meta-size: 13200896' -H 'Connection: keep-alive' -H 'x-image-meta-is_public: True' -H 'User-Agent: python-glanceclient' -H 'Content-Type: application/octet-stream' -H 'x-image-meta-disk_format: qcow2' -H 'x-image-meta-name: cirros-0.3.3-x86_64' http://controller:9292/v1/images [=============================>] 100% Request returned failure status 401. Invalid OpenStack Identity credentials.

I have to mention that i can get a token from keystone without problems:

[root@localhost ~]# keystone token-get
+-----------+----------------------------------+
| Property | Value |
+-----------+----------------------------------+
| expires | 2015-07-03T10:26:38Z |
| id | 96299e7c355d43a9b8e5b7f47a4d4cdd |
| tenant_id | 425de1784b644473b6f1cffe874992c5 |
| user_id | 0a85326e1c744d449327894b6a276b5d |
+-----------+----------------------------------+

Here are my config files:

GLANCE-API.CONF & GLANCE-REGISTRY.CONF
connection=mysql://glance:MYPASS@controller/glance
[keystone_authtoken]
auth_uri = http://controller:5000/v2.0
identity_uri = http://controller:35357
admin_tenant_name = service
admin_user = glance
admin_password = MYPASS

KEYSTONE.CONF
connection=mysql://keystone:MYPASS@controller/keystone </b>


Here is my api.log:
/var/log/glance/api.log
2015-07-03 11:15:00.763 3447 WARNING keystonemiddleware.auth_token [-] Retrying on HTTP connection exception: Unable to establish connection to http://controller:35357/
2015-07-03 11:15:01.266 3447 WARNING keystonemiddleware.auth_token [-] Retrying on HTTP connection exception: Unable to establish connection to http://controller:35357/
2015-07-03 11:15:02.269 3447 WARNING keystonemiddleware.auth_token [-] Retrying on HTTP connection exception: Unable to establish connection to http://controller:35357/
2015-07-03 11:15:04.273 3447 ERROR keystonemiddleware.auth_token [-] HTTP connection exception: Unable to establish connection to http://controller:35357/
2015-07-03 11:15:04.274 3447 WARNING keystonemiddleware.auth_token [-] Authorization failed for token
2015-07-03 11:15:04.274 3447 INFO keystonemiddleware.auth_token [-] Invalid user token - deferring reject downstream
2015-07-03 11:15:04.327 3447 INFO glance.wsgi.server [-] 192.168.13.92 - - [03/Jul/2015 11:15:04] "POST /v1/images HTTP/1.1" 401 571 3.579172
2015-07-03 11:30:29.083 3446 WARNING keystonemiddleware.auth_token [-] Retrying on HTTP connection exception: Unable to establish connection to http://controller:35357/
2015-07-03 11:30:29.587 3446 WARNING keystonemiddleware.auth_token [-] Retrying on HTTP connection exception: Unable to establish connection to http://controller:35357/
2015-07-03 11:30:30.591 3446 WARNING keystonemiddleware.auth_token [-] Retrying on HTTP connection exception: Unable to establish connection to http://controller:35357/
2015-07-03 11:30:32.595 3446 ERROR keystonemiddleware.auth_token [-] HTTP connection exception: Unable to establish connection to http://controller:35357/
2015-07-03 11:30:32.595 3446 WARNING keystonemiddleware.auth_token [-] Authorization failed for token
2015-07-03 11:30:32.595 ...
(more)
edit retag flag offensive close merge delete