summaryrefslogtreecommitdiffstats
path: root/xlators
diff options
context:
space:
mode:
authorRavishankar N <ravishankar@redhat.com>2016-06-01 17:57:41 +0530
committerAtin Mukherjee <amukherj@redhat.com>2016-06-12 22:58:48 -0700
commit8c717491413295a7045ebf9a2b1df630b7cbac76 (patch)
tree69b425da826f181abab4af8678f1b6af1977b1cc /xlators
parent2775dc64101ed37c8d9809bf9852dbf0746ee2b6 (diff)
afr: Consider ENOSPC and EDQUOT as symmetric errors
Problem: Since commit 8eaa3506ead4f11b81b146a9e56575c79f3aad7b, in replica 3, if a brick is down and a create fails on the other 2 brick with EDQUOT, we consider it an unsymmetric error and hence do not do post-op. So the dirty xattr remains set on the parent dir, leading to conservative merges during heal when all bricks are up. i.e. a file deleted on the source might re-appear after heal. Fix: Consider ENOSPC and EDQUOT as symmetric errors since there is no possibility of partial inode or entry modification operations possible when quota is enabled. IOW, if quota reports EDQUOT, the no. of bytes written (or not written) will be the same on all bricks of the replica. Likewise, the entry operation (create, mkdir...) will either succeed or not succeed on all bricks. Change-Id: Iacb1108e9ef4a918e36242fb4a957455133744e9 BUG: 1341650 Signed-off-by: Ravishankar N <ravishankar@redhat.com> Reviewed-on: http://review.gluster.org/14604 Smoke: Gluster Build System <jenkins@build.gluster.com> NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org> CentOS-regression: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Atin Mukherjee <amukherj@redhat.com> Tested-by: Atin Mukherjee <amukherj@redhat.com>
Diffstat (limited to 'xlators')
-rw-r--r--xlators/cluster/afr/src/afr-transaction.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/xlators/cluster/afr/src/afr-transaction.c b/xlators/cluster/afr/src/afr-transaction.c
index 41f36f4b2d8..df4662258bb 100644
--- a/xlators/cluster/afr/src/afr-transaction.c
+++ b/xlators/cluster/afr/src/afr-transaction.c
@@ -646,14 +646,10 @@ afr_handle_symmetric_errors (call_frame_t *frame, xlator_t *this)
}
i_errno = local->replies[i].op_errno;
- if (i_errno == ENOTCONN || i_errno == EDQUOT ||
- i_errno == ENOSPC) {
+ if (i_errno == ENOTCONN) {
/* ENOTCONN is not a symmetric error. We do not
know if the operation was performed on the
backend or not.
- * Before reaching EDQUOT and ENOSPC, each brick would
- * have written some amount of data, hence this is not
- * symmetric error.
*/
matching_errors = _gf_false;
break;