這篇文章主要為大家展示了“cinder如何配置多ceph儲(chǔ)存池”,內(nèi)容簡而易懂,條理清晰,希望能夠幫助大家解決疑惑,下面讓小編帶領(lǐng)大家一起研究并學(xué)習(xí)一下“cinder如何配置多ceph儲(chǔ)存池”這篇文章吧。
成都創(chuàng)新互聯(lián)是專業(yè)的蕉嶺網(wǎng)站建設(shè)公司,蕉嶺接單;提供成都網(wǎng)站建設(shè)、成都網(wǎng)站設(shè)計(jì),網(wǎng)頁設(shè)計(jì),網(wǎng)站設(shè)計(jì),建網(wǎng)站,PHP網(wǎng)站建設(shè)等專業(yè)做網(wǎng)站服務(wù);采用PHP框架,可快速的進(jìn)行蕉嶺網(wǎng)站開發(fā)網(wǎng)頁制作和功能擴(kuò)展;專業(yè)做搜索引擎喜愛的網(wǎng)站,專業(yè)的做網(wǎng)站團(tuán)隊(duì),希望更多企業(yè)前來合作!
要配置Ceph以使用不同的存儲(chǔ)設(shè)備,請參閱: Ceph 2 speed storage with CRUSH.
假設(shè)調(diào)用了兩個(gè)池:
rbd-sata 指向 SATA rack
rbd-ssd 指向 SSD rack
Cinder 配置文件:
#多后端選項(xiàng) #定義多個(gè)卷后端組的名稱 enabled_backends=rbd-sata,rbd-ssd #定義上面的組 [rbd-sata] volume_driver=cinder.volume.driver.RBDDriver rbd_pool=cinder-sata volume_backend_name=RBD_SATA # 如果啟用cephX需要配置下面內(nèi)容 #rbd_user=cinder #rbd_secret_uuid=[rbd-ssd] volume_driver=cinder.volume.driver.RBDDriver rbd_pool=cinder-ssd volume_backend_name=RBD_SSD #如果啟用cephX需要配置下面內(nèi)容 #rbd_user=cinder #rbd_secret_uuid=
最終創(chuàng)建兩個(gè)卷類型,分別指向各自的后端。
$ cinder type-create ssd +--------------------------------------+------+ | ID | Name | +--------------------------------------+------+ | b1522968-e4fa-4372-8ac4-3925b7c79ee1 | ssd | +--------------------------------------+------+ $ cinder type-create sata +--------------------------------------+------+ | ID | Name | +--------------------------------------+------+ | b50bf5a3-6044-4392-beeb-432302f6421c | sata | +--------------------------------------+------+
然后創(chuàng)建指針
$cinder type-key ssd set volume_backend_name=RBD_SSD $cinder type-key sata set volume_backend_name=RBD_SATA $cinder extra-specs-list +--------------------------------------+------+---------------------------------------+ | ID | Name | extra_specs | +--------------------------------------+------+---------------------------------------+ | b1522968-e4fa-4372-8ac4-3925b7c79ee1 | ssd | {u'volume_backend_name': u'RBD_SSD'} | | b50bf5a3-6044-4392-beeb-432302f6421c | sata | {u'volume_backend_name': u'RBD_SATA'} | +--------------------------------------+------+---------------------------------------+
然后重啟cinder服務(wù)
$ sudo restart cinder-api ; sudo restart cinder-scheduler ; sudo restart cinder-volume
$ cinder create --volume_type ssd --display_name vol-ssd 1 +---------------------+--------------------------------------+ | Property | Value | +---------------------+--------------------------------------+ | attachments | [] | | availability_zone | nova | | bootable | false | | created_at | 2013-04-22T14:54:53.917580 | | display_description | None | | display_name | vol-ssd | | id | 4c777d96-66e4-4f85-815c-92d4503c5c8c | | metadata | {} | | size | 1 | | snapshot_id | None | | source_volid | None | | status | creating | | volume_type | ssd | +---------------------+--------------------------------------+ $ cinder create --volume_type ssd --display_name vol-sata 1 +---------------------+--------------------------------------+ | Property | Value | +---------------------+--------------------------------------+ | attachments | [] | | availability_zone | nova | | bootable | false | | created_at | 2013-04-22T14:54:58.831327 | | display_description | None | | display_name | vol-sata | | id | 8e347bd1-2044-40a2-ae87-ee9a23cddd71 | | metadata | {} | | size | 1 | | snapshot_id | None | | source_volid | None | | status | creating | | volume_type | ssd | +---------------------+--------------------------------------+
驗(yàn)證是否配置生效
$ rbd -p cinder-ssd ls volume-8e347bd1-2044-40a2-ae87-ee9a23cddd71 $ rbd -p cinder-sata ls volume-4c777d96-66e4-4f85-815c-92d4503c5c8c
以上是“cinder如何配置多ceph儲(chǔ)存池”這篇文章的所有內(nèi)容,感謝各位的閱讀!相信大家都有了一定的了解,希望分享的內(nèi)容對大家有所幫助,如果還想學(xué)習(xí)更多知識(shí),歡迎關(guān)注創(chuàng)新互聯(lián)行業(yè)資訊頻道!