Can't upload image when using Ceph Backend: HttpException: 500

asked 2020-07-26 07:31:34 -0500

Rubick Zen gravatar image

I know there is a lot question and answer when I searched about this error. But there is no answer for my issue. I got this spesific error:

# openstack image create "cirrOS" --file cirros-0.5.1-x86_64-disk.img --disk-format qcow2 --container-format bare --public
HttpException: 500 : Server Error for url: http://10.50.50.100:9292/v2/images/c7bcabd5-fdc0-45a8-a980-0476eb468bd7/file, Internal Server Error

I use ceph-ansible for ceph cluster and my own customise ansible to deploy Openstack HA. My glance configuration:

[DEFAULT]
bind_host = 10.50.50.11

[cinder]
[cors]

[database]
connection = mysql+pymysql://glance:glancepassword@10.50.50.100/glance

[glance_store]
stores = rbd,http
default_store = rbd
filesystem_store_datadir = /var/lib/glance/images/

[glance.store.rbd.store]
rbd_store_pool = images
rbd_store_user = glance
rbd_store_ceph_conf = /etc/ceph/ceph.conf
rbd_store_chunk_size = 8


[image_format]
disk_formats = ami,ari,aki,vhd,vhdx,vmdk,raw,qcow2,vdi,iso,ploop.root-tar

[keystone_authtoken]
www_authenticate_uri = http://10.50.50.100:5000
auth_url = http://10.50.50.100:5000
memcached_servers = 10.50.50.11:11211,10.50.50.12:11211,10.50.50.13:11211
auth_type = password
project_domain_name = Default
user_domain_name = Default
project_name = service
username = glance
password = glance!btech

[oslo_concurrency]
[oslo_messaging_amqp]
[oslo_messaging_kafka]
[oslo_messaging_notifications]
[oslo_messaging_rabbit]
[oslo_middleware]
[oslo_policy]

[paste_deploy]
flavor = keystone

[profiler]
[store_type_location_strategy]
[task]
[taskflow_executor]

My glance-api logs, there is no error:

2020-07-26 19:22:16.133 82692 INFO eventlet.wsgi.server [-] 10.50.50.12 - - [26/Jul/2020 19:22:16] "OPTIONS / HTTP/1.0" 200 94 0.000696
2020-07-26 19:22:18.136 82693 INFO eventlet.wsgi.server [-] 10.50.50.12 - - [26/Jul/2020 19:22:18] "OPTIONS / HTTP/1.0" 200 94 0.000798
2020-07-26 19:22:20.137 82693 INFO eventlet.wsgi.server [-] 10.50.50.12 - - [26/Jul/2020 19:22:20] "OPTIONS / HTTP/1.0" 200 94 0.000782
2020-07-26 19:22:22.140 82692 INFO eventlet.wsgi.server [-] 10.50.50.12 - - [26/Jul/2020 19:22:22] "OPTIONS / HTTP/1.0" 200 94 0.001069
2020-07-26 19:22:24.142 82691 INFO eventlet.wsgi.server [-] 10.50.50.12 - - [26/Jul/2020 19:22:24] "OPTIONS / HTTP/1.0" 200 94 0.000697
2020-07-26 19:22:26.145 82692 INFO eventlet.wsgi.server [-] 10.50.50.12 - - [26/Jul/2020 19:22:26] "OPTIONS / HTTP/1.0" 200 94 0.000879
2020-07-26 19:22:28.147 82692 INFO eventlet.wsgi.server [-] 10.50.50.12 - - [26/Jul/2020 19:22:28] "OPTIONS / HTTP/1.0" 200 94 0.001056
2020-07-26 19:22:30.150 82694 INFO eventlet.wsgi.server [-] 10.50.50.12 - - [26/Jul/2020 19:22:30] "OPTIONS / HTTP/1.0" 200 94 0.001890
2020-07-26 19:22:32.152 82693 INFO eventlet.wsgi.server [-] 10.50.50.12 - - [26/Jul/2020 19:22:32] "OPTIONS / HTTP/1.0" 200 94 0.000713
2020-07-26 19:22:34.155 82693 INFO eventlet.wsgi.server [-] 10.50.50.12 - - [26/Jul/2020 19:22:34] "OPTIONS / HTTP/1.0" 200 94 0.000724
2020-07-26 19:22:36.157 82691 INFO eventlet.wsgi.server [-] 10.50.50.12 - - [26/Jul/2020 ...
(more)
edit retag flag offensive close merge delete

Comments

Is glance up and running (openstack Image list)? Have you checked if the ceph credentials are working correctly by manually uploading an image to ceph with those credentials?

eblock gravatar imageeblock ( 2020-07-26 11:53:22 -0500 )edit

Thanks, It works now. Fix after updated my permission on ceph keyrings.

Rubick Zen gravatar imageRubick Zen ( 2020-08-14 10:06:38 -0500 )edit