mirror of
https://github.com/ceph/ceph
synced 2025-01-17 00:12:31 +00:00
librbd: blacklist journal error while attempting to acquire lock
The journal policy will return -EPERM if attempting to acquire the exclusive lock when the image is non-primary. Signed-off-by: Jason Dillaman <dillaman@redhat.com>
This commit is contained in:
parent
e1c61f59ae
commit
970a17368a
@ -373,7 +373,8 @@ void ExclusiveLock<I>::handle_acquire_lock(int r) {
|
||||
|
||||
Action action = get_active_action();
|
||||
assert(action == ACTION_TRY_LOCK || action == ACTION_REQUEST_LOCK);
|
||||
if (action == ACTION_REQUEST_LOCK && r < 0 && r != -EBLACKLISTED) {
|
||||
if (action == ACTION_REQUEST_LOCK && r < 0 && r != -EBLACKLISTED &&
|
||||
r != -EPERM) {
|
||||
m_state = STATE_WAITING_FOR_PEER;
|
||||
m_lock.Unlock();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user