|
|
a3470f |
From cba83bafc87af2b635c24d1be2d7224a01901c73 Mon Sep 17 00:00:00 2001
|
|
|
a3470f |
From: N Balachandran <nbalacha@redhat.com>
|
|
|
a3470f |
Date: Tue, 20 Feb 2018 20:08:11 +0530
|
|
|
a3470f |
Subject: [PATCH 165/180] cluster/dht: Ignore ENODATA from getxattr for posix
|
|
|
a3470f |
acls
|
|
|
a3470f |
|
|
|
a3470f |
dht_migrate_file no longer prints an error if getxattr for
|
|
|
a3470f |
posix acls fails with ENODATA/ENOATTR.
|
|
|
a3470f |
|
|
|
a3470f |
upstream: https://review.gluster.org/#/c/19603/
|
|
|
a3470f |
|
|
|
a3470f |
> Change-Id: Id9ecf6852cb5294c1c154b28d609889ea3420e1c
|
|
|
a3470f |
> BUG: 1546954
|
|
|
a3470f |
> Signed-off-by: N Balachandran <nbalacha@redhat.com>
|
|
|
a3470f |
|
|
|
a3470f |
Change-Id: Id9ecf6852cb5294c1c154b28d609889ea3420e1c
|
|
|
a3470f |
BUG: 1546945
|
|
|
a3470f |
Signed-off-by: N Balachandran <nbalacha@redhat.com>
|
|
|
a3470f |
Reviewed-on: https://code.engineering.redhat.com/gerrit/130975
|
|
|
a3470f |
Tested-by: RHGS Build Bot <nigelb@redhat.com>
|
|
|
a3470f |
Reviewed-by: Amar Tumballi <amarts@redhat.com>
|
|
|
a3470f |
---
|
|
|
a3470f |
xlators/cluster/dht/src/dht-rebalance.c | 15 ++++++++-------
|
|
|
a3470f |
1 file changed, 8 insertions(+), 7 deletions(-)
|
|
|
a3470f |
|
|
|
a3470f |
diff --git a/xlators/cluster/dht/src/dht-rebalance.c b/xlators/cluster/dht/src/dht-rebalance.c
|
|
|
a3470f |
index e620005..9770359 100644
|
|
|
a3470f |
--- a/xlators/cluster/dht/src/dht-rebalance.c
|
|
|
a3470f |
+++ b/xlators/cluster/dht/src/dht-rebalance.c
|
|
|
a3470f |
@@ -2029,13 +2029,14 @@ dht_migrate_file (xlator_t *this, loc_t *loc, xlator_t *from, xlator_t *to,
|
|
|
a3470f |
ret = syncop_getxattr (from, loc, &xattr, POSIX_ACL_ACCESS_XATTR,
|
|
|
a3470f |
NULL, NULL);
|
|
|
a3470f |
if (ret < 0) {
|
|
|
a3470f |
- gf_msg (this->name, GF_LOG_WARNING, -ret,
|
|
|
a3470f |
- DHT_MSG_MIGRATE_FILE_FAILED,
|
|
|
a3470f |
- "Migrate file failed:"
|
|
|
a3470f |
- "%s: failed to get xattr from %s",
|
|
|
a3470f |
- loc->path, from->name);
|
|
|
a3470f |
- *fop_errno = -ret;
|
|
|
a3470f |
- ret = -1;
|
|
|
a3470f |
+ if ((-ret != ENODATA) && (-ret != ENOATTR)) {
|
|
|
a3470f |
+ gf_msg (this->name, GF_LOG_WARNING, -ret,
|
|
|
a3470f |
+ DHT_MSG_MIGRATE_FILE_FAILED,
|
|
|
a3470f |
+ "Migrate file failed:"
|
|
|
a3470f |
+ "%s: failed to get xattr from %s",
|
|
|
a3470f |
+ loc->path, from->name);
|
|
|
a3470f |
+ *fop_errno = -ret;
|
|
|
a3470f |
+ }
|
|
|
a3470f |
} else {
|
|
|
a3470f |
ret = syncop_setxattr (to, loc, xattr, 0, NULL, NULL);
|
|
|
a3470f |
if (ret < 0) {
|
|
|
a3470f |
--
|
|
|
a3470f |
1.8.3.1
|
|
|
a3470f |
|