summaryrefslogtreecommitdiffstats
path: root/xlators/cluster/afr/src
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/cluster/afr/src')
-rw-r--r--xlators/cluster/afr/src/afr-transaction.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/xlators/cluster/afr/src/afr-transaction.c b/xlators/cluster/afr/src/afr-transaction.c
index ec17c2a925a..7359b1e7a78 100644
--- a/xlators/cluster/afr/src/afr-transaction.c
+++ b/xlators/cluster/afr/src/afr-transaction.c
@@ -1894,7 +1894,8 @@ afr_set_transaction_flock (xlator_t *this, afr_local_t *local)
inodelk = afr_get_inodelk (int_lock, int_lock->domain);
priv = this->private;
- if (priv->arbiter_count) {
+ if (priv->arbiter_count &&
+ local->transaction.type == AFR_DATA_TRANSACTION) {
/*Lock entire file to avoid network split brains.*/
inodelk->flock.l_len = 0;
inodelk->flock.l_start = 0;