yxsailing 发表于 2019-2-2 08:31:06

Ceph作为OpenStack后端存储

  Total PGs = (Total_number_of_OSD * 100) /max_replication_count)
  

  1、Create pool for OpenStack
pg=256
ceph osd pool create volumes $pg   #disk_pool
ceph osd pool create images $pg    #image_pool
ceph osd pool create vms $pg      #host_pool
ceph osd pool create backups $pg   #backup_pool  2、setup ceph client authentication
ceph auth get-or-create client.cinder mon'allow r' osd 'allow class-read object_prefix rbd_children, allow rwxpool=volumes, allow rwx pool=vms, allow rx pool=images'
ceph auth get-or-create client.glance mon'allow r' osd 'allow class-read object_prefix rbd_children, allow rwxpool=images'
ceph auth get-or-createclient.cinder-backup mon 'allow r' osd 'allow class-read object_prefixrbd_children, allow rwx pool=backups'  3、Add the keyringsfor client.cinder, client.glance, and client.cinder-backup to the appropriatenodes and change their ownership
ceph auth get-or-create client.glance | ssh{your-glance-api-server} sudo tee /etc/ceph/ceph.client.glance.keyring
ssh {your-glance-api-server} sudo chownglance:glance /etc/ceph/ceph.client.glance.keyring
ceph auth get-or-create client.cinder | ssh{your-volume-server} sudo tee /etc/ceph/ceph.client.cinder.keyring
ssh {your-cinder-volume-server} sudo chowncinder:cinder /etc/ceph/ceph.client.cinder.keyring  4、Nodes running nova-compute need the keyring file for thenova-compute process
ceph auth get-or-create client.cinder | ssh{your-nova-compute-server} sudo tee /etc/ceph/ceph.client.cinder.keyring  5、Create a temporary copy of the secret key on the nodes runningnova-compute:
ceph auth get-key client.cinder > client.cinder.key
ceph auth get-key client.cinder | ssh{your-compute-node} tee client.cinder.key
uuidgen
4f859b95-406e-49f6-9ff8-d6e04f7ba1ef
cat > secret.xml
页: [1]
查看完整版本: Ceph作为OpenStack后端存储