文章目录
前言
记录一下ceph 删除rbd锁的命令
shell
rbd lock rm poolname/uuid_disk "ID" Locker
操作步骤
云主机实例的uuid是:fec52819-3b00-48e1-9f3b-c68c717bd619
shell
# 获取rbd块的信息
rbd info nova/fec52819-3b00-48e1-9f3b-c68c717bd619_disk
# 输出
rbd image 'fec52819-3b00-48e1-9f3b-c68c717bd619_disk':
size 51200 MB in 6400 objects
order 23 (8192 kB objects)
block_name_prefix: rbd_data.b1dd9882f4a685
format: 2
features: layering, exclusive-lock, object-map, fast-diff, deep-flatten
flags:
parent: glance/f7962f75-1af1-4093-b567-c008976eb885@snap
overlap: 30720 MB
# 获取锁的信息
rbd lock ls nova/fec52819-3b00-48e1-9f3b-c68c717bd619_disk
# 输出
There is 1 exclusive lock on this image.
Locker ID Address
client.405884247 auto 94052991840640 172.16.112.52:0/4199261676
# 删除锁
# e.g. rbd lock rm poolname/uuid_disk "ID" Locker
rbd lock rm nova/fec52819-3b00-48e1-9f3b-c68c717bd619_disk "auto 94052991840640" client.405884247
# 再次使用获取锁信息的命令发现已经没有锁了