mirror of
https://github.com/ceph/ceph
synced 2024-12-26 13:33:57 +00:00
rbd-mirror: snap protect of non-layered image results in split-brain
Fixes: http://tracker.ceph.com/issues/16962 Signed-off-by: Mykola Golub <mgolub@mirantis.com>
This commit is contained in:
parent
3d83dc8454
commit
8e1cc88e06
@ -1020,6 +1020,11 @@ int Operations<I>::snap_protect(const char *snap_name) {
|
||||
return -EROFS;
|
||||
}
|
||||
|
||||
if (!m_image_ctx.test_features(RBD_FEATURE_LAYERING)) {
|
||||
lderr(cct) << "image must support layering" << dendl;
|
||||
return -ENOSYS;
|
||||
}
|
||||
|
||||
int r = m_image_ctx.state->refresh_if_required();
|
||||
if (r < 0) {
|
||||
return r;
|
||||
|
Loading…
Reference in New Issue
Block a user