devstack cinder-volume服務狀態為down
阿新 • • 發佈:2019-05-16
鍵值對 driver help devstack vim all clear mod ubuntu
cinder-manage service list
查看到有一個 xxx狀態
Binary Host Zone Status State Updated At RPC Version Object Version Cluster cinder-scheduler ubsv nova enabled :-) 2019-05-16 09:19:30 3.11 1.37 cinder-volume [email protected] nova enabled XXX 2019-05-16 08:13:18 3.16 1.37 `systemctl restart [email protected]*` #重新啟動cinder cinder-volume 過一會就會down狀態,所有虛擬機都無法啟動. [email protected]:~# vgs VG #PV #LV #SN Attr VSize VFree stack-volumes-lvmdriver-1 1 5 0 wz--n- <24.00g <1.15g #沒有空間了 ubuntu-vg 2 4 0 wz--n- <1.83t <63.54g
那就增加個 vg吧.
修改
vim /etc/cinder/cinder.conf
#修改的 default_volume_type = lvmdriver-2 enabled_backends = lvmdriver-1,lvmdriver-2 #原有的 [lvmdriver-1] image_volume_cache_enabled = True volume_clear = zero lvm_type = auto target_helper = tgtadm volume_group = stack-volumes-lvmdriver-1 volume_driver = cinder.volume.drivers.lvm.LVMVolumeDriver volume_backend_name = lvmdriver-1 #新增 [lvmdriver-2] volume_group = ubuntu-vg volume_driver = cinder.volume.drivers.lvm.LVMVolumeDriver volume_backend_name = lvmdriver-2
重新啟動cinder服務
systemctl restart [email protected]*
重新查看下狀態,發現已經有了.
[email protected]:~# cinder-manage service list DEBUG oslo_db.sqlalchemy.engines [None req-606341f1-d96b-4b01-88bf-4fe7bca206e9 None None] MySQL server mode set to STRICT_TRANS_TABLES,STRICT_ALL_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,TRADITIONAL,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION {{(pid=6243) _check_effective_sql_mode /usr/local/lib/python2.7/dist-packages/oslo_db/sqlalchemy/engines.py:307}} Binary Host Zone Status State Updated At RPC Version Object Version Cluster cinder-scheduler ubsv nova enabled :-) 2019-05-16 09:47:18 3.11 1.37 cinder-volume [email protected] nova enabled :-) 2019-05-16 09:47:22 3.16 1.37 cinder-volume [email protected] nova enabled :-) 2019-05-16 09:47:18 3.16 1.37
在dashboard中 管理員登錄, 管理員-卷類型-創建卷類型
{隨便取個名字吧},然後找到新創建的卷類型點擊下三角箭頭->查看擴展規格
創建一個鍵值對 volume_backend_name lvmdriver-2
剛才我們創建的.
之後可以遷移卷到我們新的卷類型. 以後默認新建卷都存儲在我們新建的lvmdriver-2#lvmdriver-2
中,至此 目前解決了這個問題.
關聯錯誤提示: schedule allocate volume:Could not find any available weighted backend. cinder service 狀態為 down
devstack cinder-volume服務狀態為down