openstack 的glance组件使用cinder作为后端存储?求配置案例

openstack镜像文件默认是保存在本地,现在想实现将镜像文件保存在cinder中,如何实现?显示全部

openstack镜像文件默认是保存在本地,现在想实现将镜像文件保存在cinder中,如何实现?

收起
参与5

查看其它 1 个回答haichuan0227的回答

haichuan0227haichuan0227项目经理新浪云计算

cinder和glance的角色一样,都是存储服务,前者focuse volume,后者focuse image。

但两者都不负责具体的数据存储。

glance / cinder 都支持多种后端存储方案,比如ceph。

所以,我理解你的问题应该是“求glance使用ceph等分布式存储方案作为后端存储的配置案例”。

/etc/glance/glance-api.conf配置案例如下,供参考:

[code class=\"lang-Command\" lang=\"Command\"][DEFAULT]
debug = False
show_image_direct_url = True
image_cache_dir = /***/openstack/glance/image-cache
log_dir = /var/log/glance
bind_host = ***.com
bind_port = 9292
registry_host = ***.com
registry_port = 9191
workers = 24
rpc_backend = rabbit
show_multiple_locations = True
[cors]
[cors.subdomain]
[database]
connection = mysql+pymysql://***:***@mysqlserver:3306/glance
max_pool_size = 50
max_overflow = 100
[glance_store]  # 注意:在这里指定使用ceph作为glance后端存储方案
stores = rbd,file
default_store = rbd
rbd_store_user = glance
rbd_store_pool = images
rbd_store_chunk_size = 8
rbd_store_ceph_conf = /etc/ceph/ceph.conf
[image_format]
[keystone_authtoken]
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = glance
password = ***
auth_uri = http://***.com:5000/v3
auth_url = http://***.com:35357/v3
[matchmaker_redis]
[oslo_concurrency]
[oslo_messaging_amqp]
[oslo_messaging_notifications]
driver = messagingv2
[oslo_messaging_rabbit]
rabbit_hosts = rabbitmq-a:5672, rabbitmq-b:5672
rabbit_userid = rabbitmq
rabbit_password = ***
rabbit_ha_queues = True
[oslo_policy]
[paste_deploy]
flavor = keystone
[/code]
互联网服务 · 2017-04-01
浏览9953

回答者

haichuan0227
项目经理新浪云计算
擅长领域: 云计算一体化运维私有云

haichuan0227 最近回答过的问题

回答状态

  • 发布时间:2017-04-01
  • 关注会员:3 人
  • 回答浏览:9953
  • X社区推广