当前位置: 首页 > 工具软件 > Watched! > 使用案例 >

ceph volume删除失败,报错this volume is currently watched, operation not allowed

仇飞鹏
2023-12-01

主要原因是watche认为卷正在使用中,可能与客户端断开异常有关。所以需要做的就是将异常的client链接删除

1.查看watcher信息,然后将对应的客户端加入黑名单
2.rbd lock ls pool_name/volume_name
rbd lock rm pool_name/volume_name
3.rbd info v_name -p pool_name
把卷features中的exclusive-lock禁止disable,然后再将排他锁加上

以上三种方法都可以去除异常残留,随后就可以进行其他挂载或者删除操作啦~~~
顺便记录下,对象锁:rados -p rbd lock info

[root@node229 ~]# rbd ls -p 49be4b0e-9360-44d8-9cb1-d0237e6ef731
volume-9e76abb8-6c80-4a4e-a19a-a04f75a041c0
[root@node229 ~]# rbd status 49be4b0e-9360-44d8-9cb1-d0237e6ef731/volume-9e76abb8-6c80-4a4e-a19a-a04f75a041c0
Watchers:
watcher=10.1.22.231:0/2769682955 client.192968 cookie=48894336
[root@node229 ~]# ceph osd blacklist add 10.1.22.231:0/2769682955
blacklisting 10.1.22.231:0/2769682955 until 2022-01-11 17:48:49.492653 (3600 sec)
[root@node229 ~]# rbd rm volume-9e76abb8-6c80-4a4e-a19a-a04f75a041c0 -p 49be4b0e-9360-44d8-9cb1-d0237e6ef731
Removing image: 100% complete…done.

 类似资料: