openstack 组件volume,image后端存储使用ceph
2013-05-09 16:31
585 查看
Ceph是一个 Linux PB 级分布式文件系统
ceph 部署安装请参考:
默认情况下,Ceph块设备使用rbd pool。你可以使用任何可用的pool。我们建议创建一个新的pool。确保你的Ceph集群正在运行,然后创建池。
1、openstack 运行 glance-api, nova-compute, and nova-volume orcinder-volume的服务器需要 ceph.conf配置文件:
2、安装ceph客户端
3、设置Ceph客户端身份验证
(1)对于Ceph版本0.53或更低,执行以下:
(3)为客户端client.volumes 和 client.images添加key
三、配置openstack 使用ceph
1、配置glance 修改 /etc/glance/glance-api.conf 文件配置以下内容:
修改 /etc/cinder/cinder.conf 文件配置以下内容:
3、重启openstack相关服务
四、测试 1、创建volume存储
2、上传镜像
五、查看pool
这个环境中glance没有使用ceph
ceph 部署安装请参考:
Ubuntu 12.04 Ceph分布式文件系统之概述
Ubuntu 12.04 Ceph分布式文件系统之部署
一、在ceph中创建一个pool默认情况下,Ceph块设备使用rbd pool。你可以使用任何可用的pool。我们建议创建一个新的pool。确保你的Ceph集群正在运行,然后创建池。
ceph osd pool create volumes 128 ceph osd pool create images 128二、配置 OpenStack Ceph 客户端
1、openstack 运行 glance-api, nova-compute, and nova-volume orcinder-volume的服务器需要 ceph.conf配置文件:
ssh {your-openstack-server} sudo tee /etc/ceph/ceph.conf </etc/ceph/ceph.conf
2、安装ceph客户端
sudo apt-get install python-ceph sudo apt-get install ceph-common
3、设置Ceph客户端身份验证
(1)对于Ceph版本0.53或更低,执行以下:
ceph auth get-or-create client.volumes mon 'allow r' osd 'allow x, allow rwx pool=volumes, allow rx pool=images' ceph auth get-or-create client.images mon 'allow r' osd 'allow x, allow rwx pool=images'(2)在Ceph 0.54或更高版本,添加了更多的具体权限,执行以下:
ceph auth get-or-create client.volumes mon 'allow r' osd 'allow class-read object_prefix rbd_children, allow rwx pool=volumes, allow rx pool=images' ceph auth get-or-create client.images mon 'allow r' osd 'allow class-read object_prefix rbd_children, allow rwx pool=images'
(3)为客户端client.volumes 和 client.images添加key
ceph auth get-or-create client.images | ssh {your-glance-api-server} sudo tee /etc/ceph/ceph.client.images.keyring ssh {your-glance-api-server} sudo chown glance:glance /etc/ceph/ceph.client.images.keyring ceph auth get-or-create client.volumes | ssh {your-volume-server} sudo tee /etc/ceph/ceph.client.volumes.keyring ssh {your-volume-server} sudo chown cinder:cinder /etc/ceph/ceph.client.volumes.keyring
三、配置openstack 使用ceph
1、配置glance 修改 /etc/glance/glance-api.conf 文件配置以下内容:
default_store=rbd rbd_store_user=images rbd_store_pool=images show_image_direct_url=True2、配置Cinder/nova-volume
修改 /etc/cinder/cinder.conf 文件配置以下内容:
volume_driver=cinder.volume.driver.RBDDriver rbd_pool=volumes
3、重启openstack相关服务
sudo service glance-api restart sudo service nova-compute restart sudo service cinder-volume restart
四、测试 1、创建volume存储
cinder create --image-id {id of image} --display-name {name of volume} {size of volume}
2、上传镜像
glance --os_username={TENANT_NAME} --os_password={TENANT_PASS} --os_tenant={TENANT} --os_auth_url={OS_AUTH_URL} add name="{glance_name}" disk_format=aki container_format=aki < {IMAGE_FILE}
五、查看pool
这个环境中glance没有使用ceph
rados df pool name category KB objects clones degraded unfound rd rd KB wr wr KB volumes - 9618834 2586 0 0 0 20 3 71686 37911743 data - 0 0 0 0 0 0 0 0 0 metadata - 9 21 0 0 0 11 0 52 26 rbd - 0 0 0 0 0 0 0 0 0 total used 23486608 2607 total avail 176679288 total space 200165896
相关文章推荐
- 使用Ceph作为OpenStack的后端存储
- 使用Ceph作为OpenStack的后端存储
- openstack的glance、nova、cinder使用ceph做后端存储
- Openstack存储总结之:使用Ceph集群作为后端统一存储
- 使用Ceph作为OpenStack的后端存储
- 配置Ceph集群为OpenStack后端存储
- Openstack存储总结之:详解如何使用NFS作为Cinder的后端存储
- openstack-kilo,glance使用swift 作为后端存储
- openstack-pike安装cinder使用cinder做后端存储
- openstack kilo 卷备份使用nfs作为后端存储
- 【转载】ceph作为OpenStack的后端存储解决方案
- OpenStack入门修炼之Cinder服务-->使用NFS作为后端存储(19)
- openstack nova后端使用ceph rbd(增加在线迁移live_migrate和快照snapshot功能)
- kubernetes的ceph RBD volume(1):使用Ceph RBD作为后端Volume
- kolla 部署 openstack 使用 ceph作后端
- Ceph作为OpenStack后端存储
- Openstack 之使用外部ceph存储
- 使用 ceph 作为 openstack 的后端
- ceph与openstack结合提供存储后端
- React Native之Image组件使用时Android和iOS兼容性