2023年国赛题ceph集群部署,对接openstack
1.2.8 Glance 对接 Ceph 存储[1 分]
修改
OpenStack
平台中
Glance
服务的配置文件,将
Glance
后端存储改为
Ceph
存储。
在自己搭建的
OpenStack
平台中修改
glance
服务的相关配置文件,将
glance
后端存储改为
ceph
存储。也就是所以的镜像会上传至
ceph
的
images pool
中。通过命令使用
cirros-0.3.4-x86_64-disk.img
镜像文件上传至云平台中,镜像
命名为
cirros
。
1.检查 glance 服务存储配置正确计 1 分
#ceph集群搭建略...
集群节点信息
ceph-node-1 192.168.100.30
ceph-node-2 192.168.100.31
ceph-node-3 192.168.100.32
ceph主节点操作
首先创建题目所需的存储池images、volumes、vms,并初始化
[root@ceph-node1 ~]# ceph osd pool create vms 32
[root@ceph-node1 ~]# ceph osd pool create images 32
[root@ceph-node1 ~]# ceph osd pool create volumes 32
[root@ceph-node1 ~]# rbd pool init vms
[root@ceph-node1 ~]# rbd pool init images
[root@ceph-node1 ~]# rbd pool init volumes
完成后创建cinder、glance用户,权限可以给满(更方便省事),一步到位将用户发到openstack节点
[root@ceph-node1 ~]# ceph auth get-or-create client.glance mon 'allow *' osd 'allow *' mgr 'allow *'|ssh 192.168.100.10 tee /etc/ceph/ceph.client.glance.keyring
[root@ceph-node1 ~]# ceph auth get-or-create client.cinder mon 'allow *' osd 'allow *' mgr 'allow *'|ssh 192.168.100.10 tee /etc/ceph/ceph.client.cinder.keyring
[root@ceph-node1 ~]# ceph auth get-or-create client.cind