From 66d73904d1f1b665c1aac28b3c97ede6369ba7d2 Mon Sep 17 00:00:00 2001 From: Milind Changire Date: Sun, 7 Apr 2019 23:04:00 -0400 Subject: [PATCH] autobuild v6.0-1 Resolves: bz#1493284 bz#1578703 bz#1600918 bz#1670415 bz#1691620 Resolves: bz#1693935 bz#1695057 Signed-off-by: Milind Changire --- .gitignore | 1 + 0001-Update-rfc.sh-to-rhgs-3.5.0.patch | 26 + ...versions-for-RHS-backwards-compatabi.patch | 2512 +++++++++-------- ...-set-bind-insecure-to-off-by-default.patch | 51 + 0004-glusterd-spec-fixing-autogen-issue.patch | 47 + ...erfs-glusterd-Fix-compilation-errors.patch | 36 + ...build-remove-ghost-directory-entries.patch | 58 + 0007-build-add-RHGS-specific-changes.patch | 620 ++++ ...-setuid-bit-for-fusermount-glusterfs.patch | 35 + ...-security-hardening-flags-in-gluster.patch | 57 + ...-transaction-scripts-for-geo-rep-and.patch | 100 + ...vel-for-client-builds-should-not-dep.patch | 138 + 0012-build-add-pretrans-check.patch | 73 + ...o-file-checksum-mismatch-during-upgr.patch | 50 + ...-build-spec-file-conflict-resolution.patch | 72 + ...temp-file-names-in-pretrans-scriptle.patch | 198 ++ ...l-readdir-Change-the-op-version-of-p.patch | 42 + ...op-version-for-cluster.max-brick-per.patch | 37 + ...for-user-before-modifying-brick-mult.patch | 56 + ...sterd-upgrade-after-all-new-bits-are.patch | 99 + ...-files-found-for-RHEL-7-client-build.patch | 38 + ...sterfsd-remove-copyright-information.patch | 66 + 0022-cli-Remove-upstream-doc-reference.patch | 40 + 0023-hooks-remove-selinux-hooks.patch | 148 + ...caltime-logging-option-invisible-in-.patch | 50 + ...ke-RHGS-version-available-for-server.patch | 45 + ...ce-daemon-log-level-cluster-wide-opt.patch | 68 + ...ge-op-version-of-fips-mode-rchecksum.patch | 50 + ...p-version-for-features.shard-deletio.patch | 52 + ...p-version-for-features.shard-lru-lim.patch | 39 + ...-add-features.selinux-to-glusterd-vo.patch | 42 + ...rn-off-selinux-feature-in-downstream.patch | 34 + ...usterd-update-gd-op-version-to-3_7_0.patch | 29 + ...issing-explicit-package-dependencies.patch | 83 + ...duce-a-new-op-version-for-rhgs-3.4.3.patch | 59 + ...alance-mgmt_v3-command-to-op-version.patch | 41 + ...ional-dependency-on-server-for-devel.patch | 47 + 0037-cli-change-the-warning-message.patch | 35 + ...-creation-of-temp-file-in-lua-script.patch | 230 ++ ...y-to-user-during-brick-mux-selection.patch | 61 + ...upported-test-cases-failing-consiste.patch | 136 + ...ild-failed-in-Jenkins-for-test-bug-1.patch | 43 + ...-server-Builds-are-failing-on-rhel-6.patch | 123 + ...de-don-t-dump-the-whole-table-to-CLI.patch | 137 + ...-enqueue-an-entry-if-it-is-already-h.patch | 360 +++ 0045-glusterd-fix-txn-id-mem-leak.patch | 126 + ...Do-not-fallback-to-anon-fd-if-fd-is-.patch | 98 + ...x-the-payload-being-sent-on-the-wire.patch | 1652 +++++++++++ ...k-epoll-thread-for-upcall-processing.patch | 115 + ...socket-log-shutdown-msg-occasionally.patch | 49 + ...x-syncing-multiple-rename-of-symlink.patch | 142 + 0051-spec-update-rpm-install-condition.patch | 67 + 0052-geo-rep-IPv6-support.patch | 299 ++ glusterfs.spec | 1752 +++--------- sources | 2 +- 55 files changed, 8207 insertions(+), 2459 deletions(-) create mode 100644 0001-Update-rfc.sh-to-rhgs-3.5.0.patch create mode 100644 0003-rpc-set-bind-insecure-to-off-by-default.patch create mode 100644 0004-glusterd-spec-fixing-autogen-issue.patch create mode 100644 0005-libglusterfs-glusterd-Fix-compilation-errors.patch create mode 100644 0006-build-remove-ghost-directory-entries.patch create mode 100644 0007-build-add-RHGS-specific-changes.patch create mode 100644 0008-secalert-remove-setuid-bit-for-fusermount-glusterfs.patch create mode 100644 0009-build-introduce-security-hardening-flags-in-gluster.patch create mode 100644 0010-spec-fix-add-pre-transaction-scripts-for-geo-rep-and.patch create mode 100644 0011-rpm-glusterfs-devel-for-client-builds-should-not-dep.patch create mode 100644 0012-build-add-pretrans-check.patch create mode 100644 0013-glusterd-fix-info-file-checksum-mismatch-during-upgr.patch create mode 100644 0014-build-spec-file-conflict-resolution.patch create mode 100644 0015-build-randomize-temp-file-names-in-pretrans-scriptle.patch create mode 100644 0016-glusterd-parallel-readdir-Change-the-op-version-of-p.patch create mode 100644 0017-glusterd-Revert-op-version-for-cluster.max-brick-per.patch create mode 100644 0018-cli-Add-message-for-user-before-modifying-brick-mult.patch create mode 100644 0019-build-launch-glusterd-upgrade-after-all-new-bits-are.patch create mode 100644 0020-spec-unpackaged-files-found-for-RHEL-7-client-build.patch create mode 100644 0021-cli-glusterfsd-remove-copyright-information.patch create mode 100644 0022-cli-Remove-upstream-doc-reference.patch create mode 100644 0023-hooks-remove-selinux-hooks.patch create mode 100644 0024-glusterd-Make-localtime-logging-option-invisible-in-.patch create mode 100644 0025-build-make-RHGS-version-available-for-server.patch create mode 100644 0026-glusterd-Introduce-daemon-log-level-cluster-wide-opt.patch create mode 100644 0027-glusterd-change-op-version-of-fips-mode-rchecksum.patch create mode 100644 0028-glusterd-Reset-op-version-for-features.shard-deletio.patch create mode 100644 0029-glusterd-Reset-op-version-for-features.shard-lru-lim.patch create mode 100644 0030-selinux-glusterd-add-features.selinux-to-glusterd-vo.patch create mode 100644 0031-glusterd-turn-off-selinux-feature-in-downstream.patch create mode 100644 0032-glusterd-update-gd-op-version-to-3_7_0.patch create mode 100644 0033-build-add-missing-explicit-package-dependencies.patch create mode 100644 0034-glusterd-introduce-a-new-op-version-for-rhgs-3.4.3.patch create mode 100644 0035-glusterd-tag-rebalance-mgmt_v3-command-to-op-version.patch create mode 100644 0036-build-add-conditional-dependency-on-server-for-devel.patch create mode 100644 0037-cli-change-the-warning-message.patch create mode 100644 0038-spec-avoid-creation-of-temp-file-in-lua-script.patch create mode 100644 0039-cli-fix-query-to-user-during-brick-mux-selection.patch create mode 100644 0040-build-Remove-unsupported-test-cases-failing-consiste.patch create mode 100644 0041-tests-geo-rep-Build-failed-in-Jenkins-for-test-bug-1.patch create mode 100644 0042-spec-client-server-Builds-are-failing-on-rhel-6.patch create mode 100644 0043-inode-don-t-dump-the-whole-table-to-CLI.patch create mode 100644 0044-cluster-ec-Don-t-enqueue-an-entry-if-it-is-already-h.patch create mode 100644 0045-glusterd-fix-txn-id-mem-leak.patch create mode 100644 0046-protocol-client-Do-not-fallback-to-anon-fd-if-fd-is-.patch create mode 100644 0047-client-rpc-Fix-the-payload-being-sent-on-the-wire.patch create mode 100644 0048-gfapi-Unblock-epoll-thread-for-upcall-processing.patch create mode 100644 0049-transport-socket-log-shutdown-msg-occasionally.patch create mode 100644 0050-geo-rep-Fix-syncing-multiple-rename-of-symlink.patch create mode 100644 0051-spec-update-rpm-install-condition.patch create mode 100644 0052-geo-rep-IPv6-support.patch diff --git a/.gitignore b/.gitignore index 3223984..3845686 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ /glusterfs-3.12.2.tar.gz +/glusterfs-6.0.tar.gz diff --git a/0001-Update-rfc.sh-to-rhgs-3.5.0.patch b/0001-Update-rfc.sh-to-rhgs-3.5.0.patch new file mode 100644 index 0000000..040f652 --- /dev/null +++ b/0001-Update-rfc.sh-to-rhgs-3.5.0.patch @@ -0,0 +1,26 @@ +From d6ae2eb7fa7431db2108173c08b9e4455dd06005 Mon Sep 17 00:00:00 2001 +From: Milind Changire +Date: Thu, 21 Mar 2019 12:22:43 +0530 +Subject: [PATCH 01/52] Update rfc.sh to rhgs-3.5.0 + +Signed-off-by: Milind Changire +--- + rfc.sh | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/rfc.sh b/rfc.sh +index 764205c..94c92ef 100755 +--- a/rfc.sh ++++ b/rfc.sh +@@ -18,7 +18,7 @@ done + shift $((OPTIND-1)) + + +-branch="release-6"; ++branch="rhgs-3.5.0"; + + set_hooks_commit_msg() + { +-- +1.8.3.1 + diff --git a/0002-glusterd-fix-op-versions-for-RHS-backwards-compatabi.patch b/0002-glusterd-fix-op-versions-for-RHS-backwards-compatabi.patch index 6be9ef0..9ca880d 100644 --- a/0002-glusterd-fix-op-versions-for-RHS-backwards-compatabi.patch +++ b/0002-glusterd-fix-op-versions-for-RHS-backwards-compatabi.patch @@ -1,7 +1,7 @@ -From 804ac051cc8be7ff0bf0791c0b53db04edce0926 Mon Sep 17 00:00:00 2001 +From 78060c16f88594b3424e512a9ef0e4a8f56e88c3 Mon Sep 17 00:00:00 2001 From: Kaushal M -Date: Thu, 11 Jun 2015 18:21:17 +0530 -Subject: [PATCH 02/74] glusterd: fix op-versions for RHS backwards +Date: Thu, 6 Dec 2018 15:04:16 +0530 +Subject: [PATCH 02/52] glusterd: fix op-versions for RHS backwards compatability Backport of https://code.engineering.redhat.com/gerrit/#/c/60485/ @@ -15,7 +15,11 @@ Change-Id: Icb282444da179b12fbd6ed9f491514602f1a38c2 Signed-off-by: Atin Mukherjee Reviewed-on: https://code.engineering.redhat.com/gerrit/70348 --- - libglusterfs/src/globals.h | 45 +++-- + libglusterfs/src/glusterfs/globals.h | 45 +++-- + rpc/rpc-transport/socket/src/socket.c | 4 +- + xlators/cluster/dht/src/dht-shared.c | 6 +- + xlators/debug/io-stats/src/io-stats.c | 16 +- + xlators/features/barrier/src/barrier.c | 4 +- xlators/mgmt/glusterd/src/glusterd-brick-ops.c | 8 +- xlators/mgmt/glusterd/src/glusterd-handler.c | 14 +- xlators/mgmt/glusterd/src/glusterd-op-sm.c | 16 +- @@ -28,19 +32,22 @@ Reviewed-on: https://code.engineering.redhat.com/gerrit/70348 xlators/mgmt/glusterd/src/glusterd-snapshot.c | 4 +- xlators/mgmt/glusterd/src/glusterd-store.c | 27 +-- xlators/mgmt/glusterd/src/glusterd-syncop.c | 2 +- - xlators/mgmt/glusterd/src/glusterd-tier.c | 2 +- + xlators/mgmt/glusterd/src/glusterd-tier.c | 3 +- xlators/mgmt/glusterd/src/glusterd-utils.c | 8 +- xlators/mgmt/glusterd/src/glusterd-volume-ops.c | 12 +- - xlators/mgmt/glusterd/src/glusterd-volume-set.c | 198 +++++++++++---------- - 17 files changed, 193 insertions(+), 179 deletions(-) + xlators/mgmt/glusterd/src/glusterd-volume-set.c | 192 +++++++++++---------- + xlators/protocol/client/src/client.c | 4 +- + xlators/protocol/server/src/server.c | 6 +- + xlators/storage/posix/src/posix-common.c | 4 +- + 24 files changed, 214 insertions(+), 197 deletions(-) -diff --git a/libglusterfs/src/globals.h b/libglusterfs/src/globals.h -index 365183d..bd7cffe 100644 ---- a/libglusterfs/src/globals.h -+++ b/libglusterfs/src/globals.h -@@ -18,23 +18,28 @@ - #define GD_MIN_OP_VERSION_KEY "minimum-operating-version" - #define GD_MAX_OP_VERSION_KEY "maximum-operating-version" +diff --git a/libglusterfs/src/glusterfs/globals.h b/libglusterfs/src/glusterfs/globals.h +index 8d898c3..b9da872 100644 +--- a/libglusterfs/src/glusterfs/globals.h ++++ b/libglusterfs/src/glusterfs/globals.h +@@ -23,23 +23,28 @@ + #define GF_AVOID_OVERWRITE "glusterfs.avoid.overwrite" + #define GF_CLEAN_WRITE_PROTECTION "glusterfs.clean.writexattr" -/* Gluster versions - OP-VERSION mapping +/* RHS versions - OP-VERSION mapping @@ -80,13 +87,13 @@ index 365183d..bd7cffe 100644 + * GlusterFS op-versions. This is to allow proper access to upstream clients of + * version 3.7.x or greater, proper access to the RHGS volumes. */ - #define GD_OP_VERSION_MIN 1 /* MIN is the fresh start op-version, mostly - should not change */ -@@ -44,7 +49,13 @@ - introduction of newer - versions */ + #define GD_OP_VERSION_MIN \ + 1 /* MIN is the fresh start op-version, mostly \ +@@ -51,7 +56,13 @@ + introduction of newer \ + versions */ --#define GD_OP_VERSION_3_6_0 30600 /* Op-Version for GlusterFS 3.6.0 */ +-#define GD_OP_VERSION_3_6_0 30600 /* Op-Version for GlusterFS 3.6.0 */ +#define GD_OP_VERSION_RHS_3_0 30000 /* Op-Version of RHS 3.0 */ + +#define GD_OP_VER_PERSISTENT_AFR_XATTRS GD_OP_VERSION_RHS_3_0 @@ -95,194 +102,347 @@ index 365183d..bd7cffe 100644 + +#define GD_OP_VERSION_RHS_3_0_4 30004 /* Op-Version of RHS 3.0.4 */ - #define GD_OP_VERSION_3_7_0 30700 /* Op-version for GlusterFS 3.7.0 */ + #define GD_OP_VERSION_3_7_0 30700 /* Op-version for GlusterFS 3.7.0 */ -@@ -90,8 +101,6 @@ +@@ -115,8 +126,6 @@ - #define GD_OP_VERSION_3_12_2 31202 /* Op-version for GlusterFS 3.12.2 */ + #define GD_OP_VERSION_6_0 60000 /* Op-version for GlusterFS 6.0 */ -#define GD_OP_VER_PERSISTENT_AFR_XATTRS GD_OP_VERSION_3_6_0 - - #include "xlator.h" + #include "glusterfs/xlator.h" + #include "glusterfs/options.h" - /* THIS */ +diff --git a/rpc/rpc-transport/socket/src/socket.c b/rpc/rpc-transport/socket/src/socket.c +index fa0e0f2..121d46b 100644 +--- a/rpc/rpc-transport/socket/src/socket.c ++++ b/rpc/rpc-transport/socket/src/socket.c +@@ -4704,7 +4704,7 @@ struct volume_options options[] = { + .description = "SSL CA list. Ignored if SSL is not enabled."}, + {.key = {"ssl-cert-depth"}, + .type = GF_OPTION_TYPE_INT, +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE, + .description = "Maximum certificate-chain depth. If zero, the " + "peer's certificate itself must be in the local " +@@ -4713,7 +4713,7 @@ struct volume_options options[] = { + "local list. Ignored if SSL is not enabled."}, + {.key = {"ssl-cipher-list"}, + .type = GF_OPTION_TYPE_STR, +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE, + .description = "Allowed SSL ciphers. Ignored if SSL is not enabled."}, + {.key = {"ssl-dh-param"}, +diff --git a/xlators/cluster/dht/src/dht-shared.c b/xlators/cluster/dht/src/dht-shared.c +index c7ef2f1..ea4b7c6 100644 +--- a/xlators/cluster/dht/src/dht-shared.c ++++ b/xlators/cluster/dht/src/dht-shared.c +@@ -1064,7 +1064,7 @@ struct volume_options dht_options[] = { + "When enabled, files will be allocated to bricks " + "with a probability proportional to their size. Otherwise, all " + "bricks will have the same probability (legacy behavior).", +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .level = OPT_STATUS_BASIC, + .flags = OPT_FLAG_CLIENT_OPT | OPT_FLAG_SETTABLE | OPT_FLAG_DOC}, + +@@ -1161,7 +1161,7 @@ struct volume_options dht_options[] = { + "from which hash ranges are allocated starting with 0. " + "Note that we still use a directory/file's name to determine the " + "subvolume to which it hashes", +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + }, + + {.key = {"rebal-throttle"}, +@@ -1174,7 +1174,7 @@ struct volume_options dht_options[] = { + "migrated at a time. Lazy will allow only one file to " + "be migrated at a time and aggressive will allow " + "max of [($(processing units) - 4) / 2), 4]", +- .op_version = {GD_OP_VERSION_3_7_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .level = OPT_STATUS_BASIC, + .flags = OPT_FLAG_CLIENT_OPT | OPT_FLAG_SETTABLE | OPT_FLAG_DOC + +diff --git a/xlators/debug/io-stats/src/io-stats.c b/xlators/debug/io-stats/src/io-stats.c +index f12191f..41b57c5 100644 +--- a/xlators/debug/io-stats/src/io-stats.c ++++ b/xlators/debug/io-stats/src/io-stats.c +@@ -4333,7 +4333,7 @@ struct volume_options options[] = { + .value = {GF_LOGGER_GLUSTER_LOG, GF_LOGGER_SYSLOG}}, + {.key = {"client-logger"}, + .type = GF_OPTION_TYPE_STR, +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE | OPT_FLAG_CLIENT_OPT | OPT_FLAG_DOC, + .tags = {"io-stats"}, + .default_value = GF_LOGGER_GLUSTER_LOG, +@@ -4342,7 +4342,7 @@ struct volume_options options[] = { + .value = {GF_LOGGER_GLUSTER_LOG, GF_LOGGER_SYSLOG}}, + {.key = {"brick-logger"}, + .type = GF_OPTION_TYPE_STR, +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE | OPT_FLAG_DOC, + .tags = {"io-stats"}, + .default_value = GF_LOGGER_GLUSTER_LOG, +@@ -4354,7 +4354,7 @@ struct volume_options options[] = { + .value = {GF_LOG_FORMAT_NO_MSG_ID, GF_LOG_FORMAT_WITH_MSG_ID}}, + {.key = {"client-log-format"}, + .type = GF_OPTION_TYPE_STR, +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE | OPT_FLAG_CLIENT_OPT | OPT_FLAG_DOC, + .tags = {"io-stats"}, + .default_value = GF_LOG_FORMAT_WITH_MSG_ID, +@@ -4362,7 +4362,7 @@ struct volume_options options[] = { + .value = {GF_LOG_FORMAT_NO_MSG_ID, GF_LOG_FORMAT_WITH_MSG_ID}}, + {.key = {"brick-log-format"}, + .type = GF_OPTION_TYPE_STR, +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE | OPT_FLAG_DOC, + .tags = {"io-stats"}, + .default_value = GF_LOG_FORMAT_WITH_MSG_ID, +@@ -4377,7 +4377,7 @@ struct volume_options options[] = { + }, + {.key = {"client-log-buf-size"}, + .type = GF_OPTION_TYPE_INT, +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE | OPT_FLAG_CLIENT_OPT | OPT_FLAG_DOC, + .tags = {"io-stats"}, + .min = GF_LOG_LRU_BUFSIZE_MIN, +@@ -4388,7 +4388,7 @@ struct volume_options options[] = { + " the value of the option client-log-flush-timeout."}, + {.key = {"brick-log-buf-size"}, + .type = GF_OPTION_TYPE_INT, +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE | OPT_FLAG_DOC, + .tags = {"io-stats"}, + .min = GF_LOG_LRU_BUFSIZE_MIN, +@@ -4406,7 +4406,7 @@ struct volume_options options[] = { + }, + {.key = {"client-log-flush-timeout"}, + .type = GF_OPTION_TYPE_TIME, +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE | OPT_FLAG_CLIENT_OPT | OPT_FLAG_DOC, + .tags = {"io-stats"}, + .min = GF_LOG_FLUSH_TIMEOUT_MIN, +@@ -4417,7 +4417,7 @@ struct volume_options options[] = { + " the value of the option client-log-flush-timeout."}, + {.key = {"brick-log-flush-timeout"}, + .type = GF_OPTION_TYPE_TIME, +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE | OPT_FLAG_DOC, + .tags = {"io-stats"}, + .min = GF_LOG_FLUSH_TIMEOUT_MIN, +diff --git a/xlators/features/barrier/src/barrier.c b/xlators/features/barrier/src/barrier.c +index a601c7f..0923992 100644 +--- a/xlators/features/barrier/src/barrier.c ++++ b/xlators/features/barrier/src/barrier.c +@@ -774,7 +774,7 @@ struct volume_options options[] = { + {.key = {"barrier"}, + .type = GF_OPTION_TYPE_BOOL, + .default_value = "disable", +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE, + .description = "When \"enabled\", blocks acknowledgements to application " + "for file operations such as rmdir, rename, unlink, " +@@ -784,7 +784,7 @@ struct volume_options options[] = { + {.key = {"barrier-timeout"}, + .type = GF_OPTION_TYPE_TIME, + .default_value = BARRIER_TIMEOUT, +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE, + .description = "After 'timeout' seconds since the time 'barrier' " + "option was set to \"on\", acknowledgements to file " diff --git a/xlators/mgmt/glusterd/src/glusterd-brick-ops.c b/xlators/mgmt/glusterd/src/glusterd-brick-ops.c -index 6d17ff4..e88fa3f 100644 +index 38483a1..ad9a572 100644 --- a/xlators/mgmt/glusterd/src/glusterd-brick-ops.c +++ b/xlators/mgmt/glusterd/src/glusterd-brick-ops.c -@@ -1379,7 +1379,7 @@ glusterd_op_perform_add_bricks (glusterd_volinfo_t *volinfo, int32_t count, - /* A bricks mount dir is required only by snapshots which were - * introduced in gluster-3.6.0 - */ -- if (conf->op_version >= GD_OP_VERSION_3_6_0) { -+ if (conf->op_version >= GD_OP_VERSION_RHS_3_0) { - brick_mount_dir = NULL; +@@ -1195,7 +1195,7 @@ glusterd_op_perform_add_bricks(glusterd_volinfo_t *volinfo, int32_t count, + /* A bricks mount dir is required only by snapshots which were + * introduced in gluster-3.6.0 + */ +- if (conf->op_version >= GD_OP_VERSION_3_6_0) { ++ if (conf->op_version >= GD_OP_VERSION_RHS_3_0) { + brick_mount_dir = NULL; - snprintf (key, sizeof(key), "brick%d.mount_dir", i); -@@ -1926,7 +1926,7 @@ glusterd_op_stage_add_brick (dict_t *dict, char **op_errstr, dict_t *rsp_dict) - /* A bricks mount dir is required only by snapshots which were - * introduced in gluster-3.6.0 - */ -- if (conf->op_version >= GD_OP_VERSION_3_6_0) { -+ if (conf->op_version >= GD_OP_VERSION_RHS_3_0) { - ret = glusterd_get_brick_mount_dir - (brickinfo->path, brickinfo->hostname, - brickinfo->mount_dir); -@@ -2266,12 +2266,12 @@ glusterd_op_stage_remove_brick (dict_t *dict, char **op_errstr) - } - - /* Check if the connected clients are all of version -- * glusterfs-3.6 and higher. This is needed to prevent some data -+ * RHS-2.1u5 and higher. This is needed to prevent some data - * loss issues that could occur when older clients are connected - * when rebalance is run. - */ - ret = glusterd_check_client_op_version_support -- (volname, GD_OP_VERSION_3_6_0, NULL); -+ (volname, GD_OP_VERSION_RHS_2_1_5, NULL); + snprintf(key, sizeof(key), "brick%d.mount_dir", i); +@@ -1729,7 +1729,7 @@ glusterd_op_stage_add_brick(dict_t *dict, char **op_errstr, dict_t *rsp_dict) + /* A bricks mount dir is required only by snapshots which were + * introduced in gluster-3.6.0 + */ +- if (conf->op_version >= GD_OP_VERSION_3_6_0) { ++ if (conf->op_version >= GD_OP_VERSION_RHS_3_0) { + ret = glusterd_get_brick_mount_dir( + brickinfo->path, brickinfo->hostname, brickinfo->mount_dir); if (ret) { - ret = gf_asprintf (op_errstr, "Volume %s has one or " - "more connected clients of a version" +@@ -2085,12 +2085,12 @@ glusterd_op_stage_remove_brick(dict_t *dict, char **op_errstr) + } + + /* Check if the connected clients are all of version +- * glusterfs-3.6 and higher. This is needed to prevent some data ++ * RHS-2.1u5 and higher. This is needed to prevent some data + * loss issues that could occur when older clients are connected + * when rebalance is run. + */ + ret = glusterd_check_client_op_version_support( +- volname, GD_OP_VERSION_3_6_0, NULL); ++ volname, GD_OP_VERSION_RHS_2_1_5, NULL); + if (ret) { + ret = gf_asprintf(op_errstr, + "Volume %s has one or " diff --git a/xlators/mgmt/glusterd/src/glusterd-handler.c b/xlators/mgmt/glusterd/src/glusterd-handler.c -index 185186a..af9a796 100644 +index f754b52..387643d 100644 --- a/xlators/mgmt/glusterd/src/glusterd-handler.c +++ b/xlators/mgmt/glusterd/src/glusterd-handler.c -@@ -754,7 +754,7 @@ glusterd_op_txn_begin (rpcsvc_request_t *req, glusterd_op_t op, void *ctx, - } +@@ -763,7 +763,7 @@ glusterd_op_txn_begin(rpcsvc_request_t *req, glusterd_op_t op, void *ctx, + } + + /* Based on the op_version, acquire a cluster or mgmt_v3 lock */ +- if (priv->op_version < GD_OP_VERSION_3_6_0) { ++ if (priv->op_version < GD_OP_VERSION_RHS_3_0) { + ret = glusterd_lock(MY_UUID); + if (ret) { + gf_msg(this->name, GF_LOG_ERROR, 0, GD_MSG_GLUSTERD_LOCK_FAIL, +@@ -818,7 +818,7 @@ glusterd_op_txn_begin(rpcsvc_request_t *req, glusterd_op_t op, void *ctx, + local_locking_done: + /* If no volname is given as a part of the command, locks will + * not be held, hence sending stage event. */ +- if (volname || (priv->op_version < GD_OP_VERSION_3_6_0)) ++ if (volname || (priv->op_version < GD_OP_VERSION_RHS_3_0)) + event_type = GD_OP_EVENT_START_LOCK; + else { + txn_op_info.state.state = GD_OP_STATE_LOCK_SENT; +@@ -849,7 +849,7 @@ out: + if (locked && ret) { + /* Based on the op-version, we release the + * cluster or mgmt_v3 lock */ +- if (priv->op_version < GD_OP_VERSION_3_6_0) ++ if (priv->op_version < GD_OP_VERSION_RHS_3_0) + glusterd_unlock(MY_UUID); + else { + ret = glusterd_mgmt_v3_unlock(volname, MY_UUID, "vol"); +@@ -4432,12 +4432,12 @@ __glusterd_handle_status_volume(rpcsvc_request_t *req) + } + + if ((cmd & GF_CLI_STATUS_SNAPD) && +- (conf->op_version < GD_OP_VERSION_3_6_0)) { ++ (conf->op_version < GD_OP_VERSION_RHS_3_0)) { + snprintf(err_str, sizeof(err_str), + "The cluster is operating " + "at a lesser version than %d. Getting the status of " + "snapd is not allowed in this state", +- GD_OP_VERSION_3_6_0); ++ GD_OP_VERSION_RHS_3_0); + ret = -1; + goto out; + } +@@ -4459,7 +4459,7 @@ __glusterd_handle_status_volume(rpcsvc_request_t *req) + "The cluster is operating " + "at a lesser version than %d. Getting the status of " + "tierd is not allowed in this state", +- GD_OP_VERSION_3_6_0); ++ GD_OP_VERSION_RHS_3_0); + ret = -1; + goto out; + } +@@ -6430,7 +6430,7 @@ __glusterd_peer_rpc_notify(struct rpc_clnt *rpc, void *mydata, + glusterd_friend_sm_state_name_get(peerinfo->state.state)); + + if (peerinfo->connected) { +- if (conf->op_version < GD_OP_VERSION_3_6_0) { ++ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { + glusterd_get_lock_owner(&uuid); + if (!gf_uuid_is_null(uuid) && + !gf_uuid_compare(peerinfo->uuid, uuid)) +diff --git a/xlators/mgmt/glusterd/src/glusterd-op-sm.c b/xlators/mgmt/glusterd/src/glusterd-op-sm.c +index 6495a9d..dd3f9eb 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-op-sm.c ++++ b/xlators/mgmt/glusterd/src/glusterd-op-sm.c +@@ -194,7 +194,7 @@ glusterd_generate_txn_id(dict_t *dict, uuid_t **txn_id) + if (!*txn_id) + goto out; + +- if (priv->op_version < GD_OP_VERSION_3_6_0) ++ if (priv->op_version < GD_OP_VERSION_RHS_3_0) + gf_uuid_copy(**txn_id, priv->global_txn_id); + else + gf_uuid_generate(**txn_id); +@@ -1864,12 +1864,12 @@ glusterd_op_stage_status_volume(dict_t *dict, char **op_errstr) + } + + if ((cmd & GF_CLI_STATUS_SNAPD) && +- (priv->op_version < GD_OP_VERSION_3_6_0)) { ++ (priv->op_version < GD_OP_VERSION_RHS_3_0)) { + snprintf(msg, sizeof(msg), + "The cluster is operating at " + "version less than %d. Getting the " + "status of snapd is not allowed in this state.", +- GD_OP_VERSION_3_6_0); ++ GD_OP_VERSION_RHS_3_0); + ret = -1; + goto out; + } +@@ -3877,7 +3877,7 @@ glusterd_op_ac_send_lock(glusterd_op_sm_event_t *event, void *ctx) + continue; /* Based on the op_version, acquire a cluster or mgmt_v3 lock */ - if (priv->op_version < GD_OP_VERSION_3_6_0) { + if (priv->op_version < GD_OP_VERSION_RHS_3_0) { - ret = glusterd_lock (MY_UUID); - if (ret) { - gf_msg (this->name, GF_LOG_ERROR, 0, -@@ -804,7 +804,7 @@ glusterd_op_txn_begin (rpcsvc_request_t *req, glusterd_op_t op, void *ctx, - local_locking_done: - /* If no volname is given as a part of the command, locks will - * not be held, hence sending stage event. */ -- if (volname || (priv->op_version < GD_OP_VERSION_3_6_0)) -+ if (volname || (priv->op_version < GD_OP_VERSION_RHS_3_0)) - event_type = GD_OP_EVENT_START_LOCK; - else { - txn_op_info.state.state = GD_OP_STATE_LOCK_SENT; -@@ -836,7 +836,7 @@ out: - if (locked && ret) { - /* Based on the op-version, we release the - * cluster or mgmt_v3 lock */ -- if (priv->op_version < GD_OP_VERSION_3_6_0) -+ if (priv->op_version < GD_OP_VERSION_RHS_3_0) - glusterd_unlock (MY_UUID); - else { - ret = glusterd_mgmt_v3_unlock (volname, MY_UUID, -@@ -4313,11 +4313,11 @@ __glusterd_handle_status_volume (rpcsvc_request_t *req) - } - - if ((cmd & GF_CLI_STATUS_SNAPD) && -- (conf->op_version < GD_OP_VERSION_3_6_0)) { -+ (conf->op_version < GD_OP_VERSION_RHS_3_0)) { - snprintf (err_str, sizeof (err_str), "The cluster is operating " - "at a lesser version than %d. Getting the status of " - "snapd is not allowed in this state", -- GD_OP_VERSION_3_6_0); -+ GD_OP_VERSION_RHS_3_0); - ret = -1; - goto out; - } -@@ -4337,7 +4337,7 @@ __glusterd_handle_status_volume (rpcsvc_request_t *req) - snprintf (err_str, sizeof (err_str), "The cluster is operating " - "at a lesser version than %d. Getting the status of " - "tierd is not allowed in this state", -- GD_OP_VERSION_3_6_0); -+ GD_OP_VERSION_RHS_3_0); - ret = -1; - goto out; - } -@@ -6287,7 +6287,7 @@ __glusterd_peer_rpc_notify (struct rpc_clnt *rpc, void *mydata, - glusterd_friend_sm_state_name_get (peerinfo->state.state)); - - if (peerinfo->connected) { -- if (conf->op_version < GD_OP_VERSION_3_6_0) { -+ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { - glusterd_get_lock_owner (&uuid); - if (!gf_uuid_is_null (uuid) && - !gf_uuid_compare (peerinfo->uuid, uuid)) -diff --git a/xlators/mgmt/glusterd/src/glusterd-op-sm.c b/xlators/mgmt/glusterd/src/glusterd-op-sm.c -index 7bb3d53..6d5b8cf 100644 ---- a/xlators/mgmt/glusterd/src/glusterd-op-sm.c -+++ b/xlators/mgmt/glusterd/src/glusterd-op-sm.c -@@ -191,7 +191,7 @@ glusterd_generate_txn_id (dict_t *dict, uuid_t **txn_id) - if (!*txn_id) - goto out; - -- if (priv->op_version < GD_OP_VERSION_3_6_0) -+ if (priv->op_version < GD_OP_VERSION_RHS_3_0) - gf_uuid_copy (**txn_id, priv->global_txn_id); - else - gf_uuid_generate (**txn_id); -@@ -1824,11 +1824,11 @@ glusterd_op_stage_status_volume (dict_t *dict, char **op_errstr) - } - - if ((cmd & GF_CLI_STATUS_SNAPD) && -- (priv->op_version < GD_OP_VERSION_3_6_0)) { -+ (priv->op_version < GD_OP_VERSION_RHS_3_0)) { - snprintf (msg, sizeof (msg), "The cluster is operating at " - "version less than %d. Getting the " - "status of snapd is not allowed in this state.", -- GD_OP_VERSION_3_6_0); -+ GD_OP_VERSION_RHS_3_0); - ret = -1; - goto out; - } -@@ -3872,7 +3872,7 @@ glusterd_op_ac_send_lock (glusterd_op_sm_event_t *event, void *ctx) - continue; - - /* Based on the op_version, acquire a cluster or mgmt_v3 lock */ -- if (priv->op_version < GD_OP_VERSION_3_6_0) { -+ if (priv->op_version < GD_OP_VERSION_RHS_3_0) { - proc = &peerinfo->mgmt->proctable - [GLUSTERD_MGMT_CLUSTER_LOCK]; - if (proc->fn) { -@@ -3983,7 +3983,7 @@ glusterd_op_ac_send_unlock (glusterd_op_sm_event_t *event, void *ctx) - continue; - /* Based on the op_version, - * release the cluster or mgmt_v3 lock */ -- if (priv->op_version < GD_OP_VERSION_3_6_0) { -+ if (priv->op_version < GD_OP_VERSION_RHS_3_0) { - proc = &peerinfo->mgmt->proctable - [GLUSTERD_MGMT_CLUSTER_UNLOCK]; - if (proc->fn) { -@@ -5010,7 +5010,7 @@ glusterd_op_modify_op_ctx (glusterd_op_t op, void *ctx) - count = brick_index_max + other_count + 1; - - /* -- * a glusterd lesser than version 3.7 will be sending the -+ * a glusterd lesser than version RHS-3.0.4 will be sending the - * rdma port in older key. Changing that value from here - * to support backward compatibility - */ -@@ -5029,7 +5029,7 @@ glusterd_op_modify_op_ctx (glusterd_op_t op, void *ctx) - } - } - glusterd_volinfo_find (volname, &volinfo); -- if (conf->op_version < GD_OP_VERSION_3_7_0 && -+ if (conf->op_version < GD_OP_VERSION_RHS_3_0_4 && - volinfo->transport_type == GF_TRANSPORT_RDMA) { - ret = glusterd_op_modify_port_key (op_ctx, - brick_index_max); -@@ -5670,7 +5670,7 @@ glusterd_op_txn_complete (uuid_t *txn_id) - glusterd_op_clear_errstr (); - - /* Based on the op-version, we release the cluster or mgmt_v3 lock */ + proc = &peerinfo->mgmt->proctable[GLUSTERD_MGMT_CLUSTER_LOCK]; + if (proc->fn) { + ret = proc->fn(NULL, this, peerinfo); +@@ -3980,7 +3980,7 @@ glusterd_op_ac_send_unlock(glusterd_op_sm_event_t *event, void *ctx) + continue; + /* Based on the op_version, + * release the cluster or mgmt_v3 lock */ - if (priv->op_version < GD_OP_VERSION_3_6_0) { + if (priv->op_version < GD_OP_VERSION_RHS_3_0) { - ret = glusterd_unlock (MY_UUID); - /* unlock cant/shouldnt fail here!! */ + proc = &peerinfo->mgmt->proctable[GLUSTERD_MGMT_CLUSTER_UNLOCK]; + if (proc->fn) { + ret = proc->fn(NULL, this, peerinfo); +@@ -4957,7 +4957,7 @@ glusterd_op_modify_op_ctx(glusterd_op_t op, void *ctx) + count = brick_index_max + other_count + 1; + + /* +- * a glusterd lesser than version 3.7 will be sending the ++ * a glusterd lesser than version RHS-3.0.4 will be sending the + * rdma port in older key. Changing that value from here + * to support backward compatibility + */ +@@ -4977,7 +4977,7 @@ glusterd_op_modify_op_ctx(glusterd_op_t op, void *ctx) + ret = glusterd_volinfo_find(volname, &volinfo); + if (ret) + goto out; +- if (conf->op_version < GD_OP_VERSION_3_7_0 && ++ if (conf->op_version < GD_OP_VERSION_RHS_3_0_4 && + volinfo->transport_type == GF_TRANSPORT_RDMA) { + ret = glusterd_op_modify_port_key(op_ctx, brick_index_max); if (ret) +@@ -5576,7 +5576,7 @@ glusterd_op_txn_complete(uuid_t *txn_id) + glusterd_op_clear_errstr(); + + /* Based on the op-version, we release the cluster or mgmt_v3 lock */ +- if (priv->op_version < GD_OP_VERSION_3_6_0) { ++ if (priv->op_version < GD_OP_VERSION_RHS_3_0) { + ret = glusterd_unlock(MY_UUID); + /* unlock can't/shouldn't fail here!! */ + if (ret) diff --git a/xlators/mgmt/glusterd/src/glusterd-peer-utils.c b/xlators/mgmt/glusterd/src/glusterd-peer-utils.c -index 31f9e87..592aa16 100644 +index 5b5959e..f24c86e 100644 --- a/xlators/mgmt/glusterd/src/glusterd-peer-utils.c +++ b/xlators/mgmt/glusterd/src/glusterd-peer-utils.c -@@ -554,7 +554,7 @@ out: +@@ -547,7 +547,7 @@ out: * @prefix. All the parameters are compulsory. * * The complete address list is added to the dict only if the cluster op-version @@ -290,148 +450,148 @@ index 31f9e87..592aa16 100644 + * is >= GD_OP_VERSION_3_7_0 */ int - gd_add_friend_to_dict (glusterd_peerinfo_t *friend, dict_t *dict, -@@ -609,7 +609,7 @@ gd_add_friend_to_dict (glusterd_peerinfo_t *friend, dict_t *dict, - goto out; - } + gd_add_friend_to_dict(glusterd_peerinfo_t *friend, dict_t *dict, +@@ -593,7 +593,7 @@ gd_add_friend_to_dict(glusterd_peerinfo_t *friend, dict_t *dict, + goto out; + } -- if (conf->op_version < GD_OP_VERSION_3_6_0) { -+ if (conf->op_version < GD_OP_VERSION_3_7_0) { - ret = 0; - goto out; - } -@@ -799,7 +799,7 @@ gd_update_peerinfo_from_dict (glusterd_peerinfo_t *peerinfo, dict_t *dict, - GF_FREE (peerinfo->hostname); - peerinfo->hostname = gf_strdup (hostname); +- if (conf->op_version < GD_OP_VERSION_3_6_0) { ++ if (conf->op_version < GD_OP_VERSION_3_7_0) { + ret = 0; + goto out; + } +@@ -778,7 +778,7 @@ gd_update_peerinfo_from_dict(glusterd_peerinfo_t *peerinfo, dict_t *dict, + GF_FREE(peerinfo->hostname); + peerinfo->hostname = gf_strdup(hostname); -- if (conf->op_version < GD_OP_VERSION_3_6_0) { -+ if (conf->op_version < GD_OP_VERSION_3_7_0) { - ret = 0; - goto out; - } -@@ -913,7 +913,7 @@ gd_add_peer_hostnames_to_dict (glusterd_peerinfo_t *peerinfo, dict_t *dict, - conf = this->private; - GF_VALIDATE_OR_GOTO (this->name, (conf != NULL), out); +- if (conf->op_version < GD_OP_VERSION_3_6_0) { ++ if (conf->op_version < GD_OP_VERSION_3_7_0) { + ret = 0; + goto out; + } +@@ -894,7 +894,7 @@ gd_add_peer_hostnames_to_dict(glusterd_peerinfo_t *peerinfo, dict_t *dict, + conf = this->private; + GF_VALIDATE_OR_GOTO(this->name, (conf != NULL), out); -- if (conf->op_version < GD_OP_VERSION_3_6_0) { -+ if (conf->op_version < GD_OP_VERSION_3_7_0) { - ret = 0; - goto out; - } +- if (conf->op_version < GD_OP_VERSION_3_6_0) { ++ if (conf->op_version < GD_OP_VERSION_3_7_0) { + ret = 0; + goto out; + } diff --git a/xlators/mgmt/glusterd/src/glusterd-rebalance.c b/xlators/mgmt/glusterd/src/glusterd-rebalance.c -index fcafb5b..76191c4 100644 +index 34b0294..6365b6e 100644 --- a/xlators/mgmt/glusterd/src/glusterd-rebalance.c +++ b/xlators/mgmt/glusterd/src/glusterd-rebalance.c -@@ -678,13 +678,13 @@ glusterd_op_stage_rebalance (dict_t *dict, char **op_errstr) +@@ -792,13 +792,13 @@ glusterd_mgmt_v3_op_stage_rebalance(dict_t *dict, char **op_errstr) case GF_DEFRAG_CMD_START: case GF_DEFRAG_CMD_START_LAYOUT_FIX: - /* Check if the connected clients are all of version -- * glusterfs-3.6 and higher. This is needed to prevent some data -+ * RHS-2.1u5 and higher. This is needed to prevent some data - * loss issues that could occur when older clients are connected - * when rebalance is run. This check can be bypassed by using - * 'force' - */ - ret = glusterd_check_client_op_version_support -- (volname, GD_OP_VERSION_3_6_0, NULL); -+ (volname, GD_OP_VERSION_RHS_2_1_5, NULL); - if (ret) { - ret = gf_asprintf (op_errstr, "Volume %s has one or " - "more connected clients of a version" + /* Check if the connected clients are all of version +- * glusterfs-3.6 and higher. This is needed to prevent some data ++ * RHS-2.1u5 and higher. This is needed to prevent some data + * loss issues that could occur when older clients are connected + * when rebalance is run. This check can be bypassed by using + * 'force' + */ + ret = glusterd_check_client_op_version_support( +- volname, GD_OP_VERSION_3_6_0, NULL); ++ volname, GD_OP_VERSION_RHS_2_1_5, NULL); + if (ret) { + ret = gf_asprintf(op_errstr, + "Volume %s has one or " diff --git a/xlators/mgmt/glusterd/src/glusterd-replace-brick.c b/xlators/mgmt/glusterd/src/glusterd-replace-brick.c -index 08a6df0..18fc741 100644 +index ca1de1a..0615081 100644 --- a/xlators/mgmt/glusterd/src/glusterd-replace-brick.c +++ b/xlators/mgmt/glusterd/src/glusterd-replace-brick.c -@@ -305,7 +305,7 @@ glusterd_op_stage_replace_brick (dict_t *dict, char **op_errstr, - if (ret) - goto out; +@@ -297,7 +297,7 @@ glusterd_op_stage_replace_brick(dict_t *dict, char **op_errstr, + if (ret) + goto out; -- } else if (priv->op_version >= GD_OP_VERSION_3_6_0) { -+ } else if (priv->op_version >= GD_OP_VERSION_RHS_3_0) { - /* A bricks mount dir is required only by snapshots which were - * introduced in gluster-3.6.0 - */ -@@ -389,7 +389,7 @@ glusterd_op_perform_replace_brick (glusterd_volinfo_t *volinfo, +- } else if (priv->op_version >= GD_OP_VERSION_3_6_0) { ++ } else if (priv->op_version >= GD_OP_VERSION_RHS_3_0) { /* A bricks mount dir is required only by snapshots which were * introduced in gluster-3.6.0 */ -- if (conf->op_version >= GD_OP_VERSION_3_6_0) { -+ if (conf->op_version >= GD_OP_VERSION_RHS_3_0) { - ret = dict_get_str (dict, "brick1.mount_dir", &brick_mount_dir); - if (ret) { - gf_msg (this->name, GF_LOG_ERROR, errno, +@@ -396,7 +396,7 @@ glusterd_op_perform_replace_brick(glusterd_volinfo_t *volinfo, char *old_brick, + /* A bricks mount dir is required only by snapshots which were + * introduced in gluster-3.6.0 + */ +- if (conf->op_version >= GD_OP_VERSION_3_6_0) { ++ if (conf->op_version >= GD_OP_VERSION_RHS_3_0) { + ret = dict_get_strn(dict, "brick1.mount_dir", SLEN("brick1.mount_dir"), + &brick_mount_dir); + if (ret) { diff --git a/xlators/mgmt/glusterd/src/glusterd-rpc-ops.c b/xlators/mgmt/glusterd/src/glusterd-rpc-ops.c -index ab52e8d..86e1256 100644 +index 728781d..4ec9700 100644 --- a/xlators/mgmt/glusterd/src/glusterd-rpc-ops.c +++ b/xlators/mgmt/glusterd/src/glusterd-rpc-ops.c -@@ -302,11 +302,11 @@ __glusterd_probe_cbk (struct rpc_req *req, struct iovec *iov, - * we need to add the new hostname to the peer. - * - * This addition should only be done for cluster op-version >= -- * GD_OP_VERSION_3_6_0 as address lists are only supported from then on. -+ * GD_OP_VERSION_3_7_0 as address lists are only supported from then on. - * Also, this update should only be done when an explicit CLI probe - * command was used to begin the probe process. - */ -- if ((conf->op_version >= GD_OP_VERSION_3_6_0) && -+ if ((conf->op_version >= GD_OP_VERSION_3_7_0) && - (gf_uuid_compare (rsp.uuid, peerinfo->uuid) == 0)) { - ctx = ((call_frame_t *)myframe)->local; - /* Presence of ctx->req implies this probe was started by a cli -@@ -1591,7 +1591,7 @@ glusterd_rpc_friend_add (call_frame_t *frame, xlator_t *this, - goto out; - } +@@ -288,11 +288,11 @@ __glusterd_probe_cbk(struct rpc_req *req, struct iovec *iov, int count, + * we need to add the new hostname to the peer. + * + * This addition should only be done for cluster op-version >= +- * GD_OP_VERSION_3_6_0 as address lists are only supported from then on. ++ * GD_OP_VERSION_3_7_0 as address lists are only supported from then on. + * Also, this update should only be done when an explicit CLI probe + * command was used to begin the probe process. + */ +- if ((conf->op_version >= GD_OP_VERSION_3_6_0) && ++ if ((conf->op_version >= GD_OP_VERSION_3_7_0) && + (gf_uuid_compare(rsp.uuid, peerinfo->uuid) == 0)) { + ctx = ((call_frame_t *)myframe)->local; + /* Presence of ctx->req implies this probe was started by a cli +@@ -1544,7 +1544,7 @@ glusterd_rpc_friend_add(call_frame_t *frame, xlator_t *this, void *data) + goto out; + } -- if (priv->op_version >= GD_OP_VERSION_3_6_0) { -+ if (priv->op_version >= GD_OP_VERSION_RHS_3_0) { - ret = glusterd_add_missed_snaps_to_export_dict (peer_data); - if (ret) { - gf_msg (this->name, GF_LOG_ERROR, 0, +- if (priv->op_version >= GD_OP_VERSION_3_6_0) { ++ if (priv->op_version >= GD_OP_VERSION_RHS_3_0) { + ret = glusterd_add_missed_snaps_to_export_dict(peer_data); + if (ret) { + gf_msg(this->name, GF_LOG_ERROR, 0, diff --git a/xlators/mgmt/glusterd/src/glusterd-sm.c b/xlators/mgmt/glusterd/src/glusterd-sm.c -index f83e851..6c56837 100644 +index 73a11a3..54a7bd1 100644 --- a/xlators/mgmt/glusterd/src/glusterd-sm.c +++ b/xlators/mgmt/glusterd/src/glusterd-sm.c -@@ -942,7 +942,7 @@ glusterd_ac_handle_friend_add_req (glusterd_friend_sm_event_t *event, void *ctx) +@@ -955,7 +955,7 @@ glusterd_ac_handle_friend_add_req(glusterd_friend_sm_event_t *event, void *ctx) + /* Compare missed_snapshot list with the peer * * if volume comparison is successful */ - if ((op_ret == 0) && -- (conf->op_version >= GD_OP_VERSION_3_6_0)) { -+ (conf->op_version >= GD_OP_VERSION_RHS_3_0)) { - ret = glusterd_import_friend_missed_snap_list (ev_ctx->vols); - if (ret) { - gf_msg (this->name, GF_LOG_ERROR, 0, +- if ((op_ret == 0) && (conf->op_version >= GD_OP_VERSION_3_6_0)) { ++ if ((op_ret == 0) && (conf->op_version >= GD_OP_VERSION_RHS_3_0)) { + ret = glusterd_import_friend_missed_snap_list(ev_ctx->vols); + if (ret) { + gf_msg(this->name, GF_LOG_ERROR, 0, diff --git a/xlators/mgmt/glusterd/src/glusterd-snapshot-utils.c b/xlators/mgmt/glusterd/src/glusterd-snapshot-utils.c -index 9e2a75f..6fb49c3 100644 +index 1ece374..2958443 100644 --- a/xlators/mgmt/glusterd/src/glusterd-snapshot-utils.c +++ b/xlators/mgmt/glusterd/src/glusterd-snapshot-utils.c -@@ -468,7 +468,7 @@ gd_add_brick_snap_details_to_dict (dict_t *dict, char *prefix, - GF_VALIDATE_OR_GOTO (this->name, (prefix != NULL), out); - GF_VALIDATE_OR_GOTO (this->name, (brickinfo != NULL), out); +@@ -470,7 +470,7 @@ gd_add_brick_snap_details_to_dict(dict_t *dict, char *prefix, + GF_VALIDATE_OR_GOTO(this->name, (prefix != NULL), out); + GF_VALIDATE_OR_GOTO(this->name, (brickinfo != NULL), out); -- if (conf->op_version < GD_OP_VERSION_3_6_0) { -+ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { - ret = 0; - goto out; - } -@@ -550,7 +550,7 @@ gd_add_vol_snap_details_to_dict (dict_t *dict, char *prefix, - GF_VALIDATE_OR_GOTO (this->name, (volinfo != NULL), out); - GF_VALIDATE_OR_GOTO (this->name, (prefix != NULL), out); +- if (conf->op_version < GD_OP_VERSION_3_6_0) { ++ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { + ret = 0; + goto out; + } +@@ -547,7 +547,7 @@ gd_add_vol_snap_details_to_dict(dict_t *dict, char *prefix, + GF_VALIDATE_OR_GOTO(this->name, (volinfo != NULL), out); + GF_VALIDATE_OR_GOTO(this->name, (prefix != NULL), out); -- if (conf->op_version < GD_OP_VERSION_3_6_0) { -+ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { - ret = 0; - goto out; - } -@@ -878,7 +878,7 @@ gd_import_new_brick_snap_details (dict_t *dict, char *prefix, - GF_VALIDATE_OR_GOTO (this->name, (prefix != NULL), out); - GF_VALIDATE_OR_GOTO (this->name, (brickinfo != NULL), out); +- if (conf->op_version < GD_OP_VERSION_3_6_0) { ++ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { + ret = 0; + goto out; + } +@@ -846,7 +846,7 @@ gd_import_new_brick_snap_details(dict_t *dict, char *prefix, + GF_VALIDATE_OR_GOTO(this->name, (prefix != NULL), out); + GF_VALIDATE_OR_GOTO(this->name, (brickinfo != NULL), out); -- if (conf->op_version < GD_OP_VERSION_3_6_0) { -+ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { - ret = 0; - goto out; - } -@@ -939,8 +939,8 @@ out: +- if (conf->op_version < GD_OP_VERSION_3_6_0) { ++ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { + ret = 0; + goto out; + } +@@ -903,8 +903,8 @@ out: * Imports the snapshot details of a volume if required and available * * Snapshot details will be imported only if cluster.op_version is greater than @@ -441,905 +601,957 @@ index 9e2a75f..6fb49c3 100644 + * is supported. */ int - gd_import_volume_snap_details (dict_t *dict, glusterd_volinfo_t *volinfo, -@@ -962,7 +962,7 @@ gd_import_volume_snap_details (dict_t *dict, glusterd_volinfo_t *volinfo, - GF_VALIDATE_OR_GOTO (this->name, (prefix != NULL), out); - GF_VALIDATE_OR_GOTO (this->name, (volname != NULL), out); + gd_import_volume_snap_details(dict_t *dict, glusterd_volinfo_t *volinfo, +@@ -928,7 +928,7 @@ gd_import_volume_snap_details(dict_t *dict, glusterd_volinfo_t *volinfo, + GF_VALIDATE_OR_GOTO(this->name, (prefix != NULL), out); + GF_VALIDATE_OR_GOTO(this->name, (volname != NULL), out); -- if (conf->op_version < GD_OP_VERSION_3_6_0) { -+ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { - ret = 0; - goto out; - } +- if (conf->op_version < GD_OP_VERSION_3_6_0) { ++ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { + ret = 0; + goto out; + } diff --git a/xlators/mgmt/glusterd/src/glusterd-snapshot.c b/xlators/mgmt/glusterd/src/glusterd-snapshot.c -index 31f4d95..6306d29 100644 +index 8f5cd6d..c56be91 100644 --- a/xlators/mgmt/glusterd/src/glusterd-snapshot.c +++ b/xlators/mgmt/glusterd/src/glusterd-snapshot.c -@@ -9341,7 +9341,7 @@ glusterd_handle_snapshot_fn (rpcsvc_request_t *req) - goto out; - } +@@ -9345,14 +9345,14 @@ glusterd_handle_snapshot_fn(rpcsvc_request_t *req) + goto out; + } -- if (conf->op_version < GD_OP_VERSION_3_6_0) { -+ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { - snprintf (err_str, sizeof (err_str), "Cluster operating version" - " is lesser than the supported version " - "for a snapshot"); -@@ -9349,7 +9349,7 @@ glusterd_handle_snapshot_fn (rpcsvc_request_t *req) - gf_msg (this->name, GF_LOG_ERROR, 0, - GD_MSG_UNSUPPORTED_VERSION, - "%s (%d < %d)", err_str, -- conf->op_version, GD_OP_VERSION_3_6_0); -+ conf->op_version, GD_OP_VERSION_RHS_3_0); - ret = -1; - goto out; - } +- if (conf->op_version < GD_OP_VERSION_3_6_0) { ++ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { + snprintf(err_str, sizeof(err_str), + "Cluster operating version" + " is lesser than the supported version " + "for a snapshot"); + op_errno = EG_OPNOTSUP; + gf_msg(this->name, GF_LOG_ERROR, 0, GD_MSG_UNSUPPORTED_VERSION, +- "%s (%d < %d)", err_str, conf->op_version, GD_OP_VERSION_3_6_0); ++ "%s (%d < %d)", err_str, conf->op_version, GD_OP_VERSION_RHS_3_0); + ret = -1; + goto out; + } diff --git a/xlators/mgmt/glusterd/src/glusterd-store.c b/xlators/mgmt/glusterd/src/glusterd-store.c -index 4d22b63..229391a 100644 +index 7acea05..64447e7 100644 --- a/xlators/mgmt/glusterd/src/glusterd-store.c +++ b/xlators/mgmt/glusterd/src/glusterd-store.c -@@ -302,7 +302,7 @@ gd_store_brick_snap_details_write (int fd, glusterd_brickinfo_t *brickinfo) - GF_VALIDATE_OR_GOTO (this->name, (fd > 0), out); - GF_VALIDATE_OR_GOTO (this->name, (brickinfo != NULL), out); +@@ -313,7 +313,7 @@ gd_store_brick_snap_details_write(int fd, glusterd_brickinfo_t *brickinfo) + GF_VALIDATE_OR_GOTO(this->name, (fd > 0), out); + GF_VALIDATE_OR_GOTO(this->name, (brickinfo != NULL), out); -- if (conf->op_version < GD_OP_VERSION_3_6_0) { -+ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { - ret = 0; - goto out; - } -@@ -799,7 +799,7 @@ glusterd_volume_write_snap_details (int fd, glusterd_volinfo_t *volinfo) - GF_VALIDATE_OR_GOTO (this->name, (fd > 0), out); - GF_VALIDATE_OR_GOTO (this->name, (volinfo != NULL), out); +- if (conf->op_version < GD_OP_VERSION_3_6_0) { ++ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { + ret = 0; + goto out; + } +@@ -813,7 +813,7 @@ glusterd_volume_write_snap_details(int fd, glusterd_volinfo_t *volinfo) + GF_VALIDATE_OR_GOTO(this->name, (fd > 0), out); + GF_VALIDATE_OR_GOTO(this->name, (volinfo != NULL), out); -- if (conf->op_version < GD_OP_VERSION_3_6_0) { -+ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { - ret = 0; - goto out; - } -@@ -968,7 +968,7 @@ glusterd_volume_exclude_options_write (int fd, glusterd_volinfo_t *volinfo) - goto out; - } +- if (conf->op_version < GD_OP_VERSION_3_6_0) { ++ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { + ret = 0; + goto out; + } +@@ -967,7 +967,7 @@ glusterd_volume_exclude_options_write(int fd, glusterd_volinfo_t *volinfo) + goto out; + } -- if (conf->op_version >= GD_OP_VERSION_3_6_0) { -+ if (conf->op_version >= GD_OP_VERSION_RHS_3_0) { - snprintf (buf, sizeof (buf), "%d", volinfo->disperse_count); - ret = gf_store_save_value (fd, - GLUSTERD_STORE_KEY_VOL_DISPERSE_CNT, -@@ -2339,7 +2339,7 @@ glusterd_store_retrieve_snapd (glusterd_volinfo_t *volinfo) - conf = THIS->private; - GF_ASSERT (volinfo); +- if (conf->op_version >= GD_OP_VERSION_3_6_0) { ++ if (conf->op_version >= GD_OP_VERSION_RHS_3_0) { + snprintf(buf, sizeof(buf), "%d", volinfo->disperse_count); + ret = gf_store_save_value(fd, GLUSTERD_STORE_KEY_VOL_DISPERSE_CNT, buf); + if (ret) +@@ -2502,7 +2502,7 @@ glusterd_store_retrieve_snapd(glusterd_volinfo_t *volinfo) + conf = THIS->private; + GF_ASSERT(volinfo); -- if (conf->op_version < GD_OP_VERSION_3_6_0) { -+ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { - ret = 0; - goto out; - } -@@ -2347,15 +2347,16 @@ glusterd_store_retrieve_snapd (glusterd_volinfo_t *volinfo) - /* - * This is needed for upgrade situations. Say a volume is created with - * older version of glusterfs and upgraded to a glusterfs version equal -- * to or greater than GD_OP_VERSION_3_6_0. The older glusterd would not -- * have created the snapd.info file related to snapshot daemon for user -- * serviceable snapshots. So as part of upgrade when the new glusterd -- * starts, as part of restore (restoring the volume to be precise), it -- * tries to snapd related info from snapd.info file. But since there was -- * no such file till now, the restore operation fails. Thus, to prevent -- * it from happening check whether user serviceable snapshots features -- * is enabled before restoring snapd. If its disbaled, then simply -- * exit by returning success (without even checking for the snapd.info). -+ * to or greater than GD_OP_VERSION_RHS_3_0. The older glusterd would -+ * not have created the snapd.info file related to snapshot daemon for -+ * user serviceable snapshots. So as part of upgrade when the new -+ * glusterd starts, as part of restore (restoring the volume to be -+ * precise), it tries to snapd related info from snapd.info file. But -+ * since there was no such file till now, the restore operation fails. -+ * Thus, to prevent it from happening check whether user serviceable -+ * snapshots features is enabled before restoring snapd. If its -+ * disbaled, then simply exit by returning success (without even -+ * checking for the snapd.info). - */ +- if (conf->op_version < GD_OP_VERSION_3_6_0) { ++ if (conf->op_version < GD_OP_VERSION_RHS_3_0) { + ret = 0; + goto out; + } +@@ -2510,15 +2510,16 @@ glusterd_store_retrieve_snapd(glusterd_volinfo_t *volinfo) + /* + * This is needed for upgrade situations. Say a volume is created with + * older version of glusterfs and upgraded to a glusterfs version equal +- * to or greater than GD_OP_VERSION_3_6_0. The older glusterd would not +- * have created the snapd.info file related to snapshot daemon for user +- * serviceable snapshots. So as part of upgrade when the new glusterd +- * starts, as part of restore (restoring the volume to be precise), it +- * tries to snapd related info from snapd.info file. But since there was +- * no such file till now, the restore operation fails. Thus, to prevent +- * it from happening check whether user serviceable snapshots features +- * is enabled before restoring snapd. If its disabled, then simply +- * exit by returning success (without even checking for the snapd.info). ++ * to or greater than GD_OP_VERSION_RHS_3_0. The older glusterd would ++ * not have created the snapd.info file related to snapshot daemon for ++ * user serviceable snapshots. So as part of upgrade when the new ++ * glusterd starts, as part of restore (restoring the volume to be ++ * precise), it tries to snapd related info from snapd.info file. But ++ * since there was no such file till now, the restore operation fails. ++ * Thus, to prevent it from happening check whether user serviceable ++ * snapshots features is enabled before restoring snapd. If its ++ * disbaled, then simply exit by returning success (without even ++ * checking for the snapd.info). + */ - if (!dict_get_str_boolean (volinfo->dict, "features.uss", _gf_false)) { + if (!dict_get_str_boolean(volinfo->dict, "features.uss", _gf_false)) { diff --git a/xlators/mgmt/glusterd/src/glusterd-syncop.c b/xlators/mgmt/glusterd/src/glusterd-syncop.c -index 4be3d97..066c7f9 100644 +index 45b221c..1741cf8 100644 --- a/xlators/mgmt/glusterd/src/glusterd-syncop.c +++ b/xlators/mgmt/glusterd/src/glusterd-syncop.c -@@ -1863,7 +1863,7 @@ gd_sync_task_begin (dict_t *op_ctx, rpcsvc_request_t * req) - goto out; - } +@@ -1827,7 +1827,7 @@ gd_sync_task_begin(dict_t *op_ctx, rpcsvc_request_t *req) + goto out; + } -- if (conf->op_version < GD_OP_VERSION_3_6_0) -+ if (conf->op_version < GD_OP_VERSION_RHS_3_0) - cluster_lock = _gf_true; +- if (conf->op_version < GD_OP_VERSION_3_6_0) ++ if (conf->op_version < GD_OP_VERSION_RHS_3_0) + cluster_lock = _gf_true; - /* Based on the op_version, acquire a cluster or mgmt_v3 lock */ + /* Based on the op_version, acquire a cluster or mgmt_v3 lock */ diff --git a/xlators/mgmt/glusterd/src/glusterd-tier.c b/xlators/mgmt/glusterd/src/glusterd-tier.c -index 45f6ac3..28f02e75 100644 +index dd86cf5..4dc0d44 100644 --- a/xlators/mgmt/glusterd/src/glusterd-tier.c +++ b/xlators/mgmt/glusterd/src/glusterd-tier.c -@@ -921,7 +921,7 @@ glusterd_op_stage_tier (dict_t *dict, char **op_errstr, dict_t *rsp_dict) - * 'force' - */ - ret = glusterd_check_client_op_version_support -- (volname, GD_OP_VERSION_3_6_0, NULL); -+ (volname, GD_OP_VERSION_RHS_3_0, NULL); - if (ret) { - ret = gf_asprintf (op_errstr, "Volume %s has one or " - "more connected clients of a version" +@@ -867,7 +867,8 @@ glusterd_op_stage_tier(dict_t *dict, char **op_errstr, dict_t *rsp_dict) + * when rebalance is run. This check can be bypassed by using + * 'force' + */ +- ret = glusterd_check_client_op_version_support(volname, GD_OP_VERSION_3_6_0, ++ ret = glusterd_check_client_op_version_support(volname, ++ GD_OP_VERSION_RHS_3_0, + NULL); + if (ret) { + ret = gf_asprintf(op_errstr, diff --git a/xlators/mgmt/glusterd/src/glusterd-utils.c b/xlators/mgmt/glusterd/src/glusterd-utils.c -index e38f963..f34e218 100644 +index 8bbd795..52b83ec 100644 --- a/xlators/mgmt/glusterd/src/glusterd-utils.c +++ b/xlators/mgmt/glusterd/src/glusterd-utils.c -@@ -11758,10 +11758,10 @@ gd_update_volume_op_versions (glusterd_volinfo_t *volinfo) - } +@@ -12226,10 +12226,10 @@ gd_update_volume_op_versions(glusterd_volinfo_t *volinfo) + } - if (volinfo->type == GF_CLUSTER_TYPE_DISPERSE) { -- if (volinfo->op_version < GD_OP_VERSION_3_6_0) -- volinfo->op_version = GD_OP_VERSION_3_6_0; -- if (volinfo->client_op_version < GD_OP_VERSION_3_6_0) -- volinfo->client_op_version = GD_OP_VERSION_3_6_0; -+ if (volinfo->op_version < GD_OP_VERSION_3_7_0) -+ volinfo->op_version = GD_OP_VERSION_3_7_0; -+ if (volinfo->client_op_version < GD_OP_VERSION_3_7_0) -+ volinfo->client_op_version = GD_OP_VERSION_3_7_0; - } + if (volinfo->type == GF_CLUSTER_TYPE_DISPERSE) { +- if (volinfo->op_version < GD_OP_VERSION_3_6_0) +- volinfo->op_version = GD_OP_VERSION_3_6_0; +- if (volinfo->client_op_version < GD_OP_VERSION_3_6_0) +- volinfo->client_op_version = GD_OP_VERSION_3_6_0; ++ if (volinfo->op_version < GD_OP_VERSION_3_7_0) ++ volinfo->op_version = GD_OP_VERSION_3_7_0; ++ if (volinfo->client_op_version < GD_OP_VERSION_3_7_0) ++ volinfo->client_op_version = GD_OP_VERSION_3_7_0; + } - return; + return; diff --git a/xlators/mgmt/glusterd/src/glusterd-volume-ops.c b/xlators/mgmt/glusterd/src/glusterd-volume-ops.c -index 9d34073..834acab 100644 +index 7cfba3d..86ef470 100644 --- a/xlators/mgmt/glusterd/src/glusterd-volume-ops.c +++ b/xlators/mgmt/glusterd/src/glusterd-volume-ops.c -@@ -1325,7 +1325,7 @@ glusterd_op_stage_create_volume (dict_t *dict, char **op_errstr, - /* A bricks mount dir is required only by snapshots which were - * introduced in gluster-3.6.0 - */ -- if (priv->op_version >= GD_OP_VERSION_3_6_0) { -+ if (priv->op_version >= GD_OP_VERSION_RHS_3_0) { - ret = glusterd_get_brick_mount_dir - (brick_info->path, brick_info->hostname, - brick_info->mount_dir); -@@ -1611,7 +1611,7 @@ glusterd_op_stage_start_volume (dict_t *dict, char **op_errstr, - /* A bricks mount dir is required only by snapshots which were - * introduced in gluster-3.6.0 - */ -- if (priv->op_version >= GD_OP_VERSION_3_6_0) { -+ if (priv->op_version >= GD_OP_VERSION_RHS_3_0) { - if (strlen(brickinfo->mount_dir) < 1) { - ret = glusterd_get_brick_mount_dir - (brickinfo->path, brickinfo->hostname, -@@ -2320,10 +2320,10 @@ glusterd_op_create_volume (dict_t *dict, char **op_errstr) - "redundancy count for volume %s", volname); - goto out; - } -- if (priv->op_version < GD_OP_VERSION_3_6_0) { -+ if (priv->op_version < GD_OP_VERSION_3_7_0) { - gf_msg (this->name, GF_LOG_ERROR, 0, - GD_MSG_UNSUPPORTED_VERSION, "Disperse volume " -- "needs op-version 3.6.0 or higher"); -+ "needs op-version 30700 or higher"); - ret = -1; - goto out; - } -@@ -2428,7 +2428,7 @@ glusterd_op_create_volume (dict_t *dict, char **op_errstr) - /* A bricks mount dir is required only by snapshots which were - * introduced in gluster-3.6.0 - */ -- if (priv->op_version >= GD_OP_VERSION_3_6_0) { -+ if (priv->op_version >= GD_OP_VERSION_RHS_3_0) { - brick_mount_dir = NULL; - snprintf (key, sizeof(key), "brick%d.mount_dir", i); - ret = dict_get_str (dict, key, &brick_mount_dir); -@@ -2623,7 +2623,7 @@ glusterd_op_start_volume (dict_t *dict, char **op_errstr) +@@ -1389,7 +1389,7 @@ glusterd_op_stage_create_volume(dict_t *dict, char **op_errstr, + /* A bricks mount dir is required only by snapshots which were + * introduced in gluster-3.6.0 + */ +- if (priv->op_version >= GD_OP_VERSION_3_6_0) { ++ if (priv->op_version >= GD_OP_VERSION_RHS_3_0) { + ret = glusterd_get_brick_mount_dir(brick_info->path, + brick_info->hostname, + brick_info->mount_dir); +@@ -1698,7 +1698,7 @@ glusterd_op_stage_start_volume(dict_t *dict, char **op_errstr, dict_t *rsp_dict) /* A bricks mount dir is required only by snapshots which were * introduced in gluster-3.6.0 */ -- if (conf->op_version >= GD_OP_VERSION_3_6_0) { -+ if (conf->op_version >= GD_OP_VERSION_RHS_3_0) { - cds_list_for_each_entry (brickinfo, &volinfo->bricks, - brick_list) { - brick_count++; +- if (priv->op_version >= GD_OP_VERSION_3_6_0) { ++ if (priv->op_version >= GD_OP_VERSION_RHS_3_0) { + if (strlen(brickinfo->mount_dir) < 1) { + ret = glusterd_get_brick_mount_dir( + brickinfo->path, brickinfo->hostname, brickinfo->mount_dir); +@@ -2395,10 +2395,10 @@ glusterd_op_create_volume(dict_t *dict, char **op_errstr) + volname); + goto out; + } +- if (priv->op_version < GD_OP_VERSION_3_6_0) { ++ if (priv->op_version < GD_OP_VERSION_3_7_0) { + gf_msg(this->name, GF_LOG_ERROR, 0, GD_MSG_UNSUPPORTED_VERSION, + "Disperse volume " +- "needs op-version 3.6.0 or higher"); ++ "needs op-version 30700 or higher"); + ret = -1; + goto out; + } +@@ -2494,7 +2494,7 @@ glusterd_op_create_volume(dict_t *dict, char **op_errstr) + /* A bricks mount dir is required only by snapshots which were + * introduced in gluster-3.6.0 + */ +- if (priv->op_version >= GD_OP_VERSION_3_6_0) { ++ if (priv->op_version >= GD_OP_VERSION_RHS_3_0) { + brick_mount_dir = NULL; + ret = snprintf(key, sizeof(key), "brick%d.mount_dir", i); + ret = dict_get_strn(dict, key, ret, &brick_mount_dir); +@@ -2703,7 +2703,7 @@ glusterd_op_start_volume(dict_t *dict, char **op_errstr) + /* A bricks mount dir is required only by snapshots which were + * introduced in gluster-3.6.0 + */ +- if (conf->op_version >= GD_OP_VERSION_3_6_0) { ++ if (conf->op_version >= GD_OP_VERSION_RHS_3_0) { + cds_list_for_each_entry(brickinfo, &volinfo->bricks, brick_list) + { + brick_count++; diff --git a/xlators/mgmt/glusterd/src/glusterd-volume-set.c b/xlators/mgmt/glusterd/src/glusterd-volume-set.c -index 14b9e21..982275e 100644 +index dc58e11..d07fc10 100644 --- a/xlators/mgmt/glusterd/src/glusterd-volume-set.c +++ b/xlators/mgmt/glusterd/src/glusterd-volume-set.c -@@ -1263,7 +1263,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { - { .key = "cluster.subvols-per-directory", - .voltype = "cluster/distribute", - .option = "directory-layout-spread", -- .op_version = 2, -+ .op_version = 1, - .validate_fn = validate_subvols_per_directory, - .flags = OPT_FLAG_CLIENT_OPT - }, -@@ -1275,27 +1275,27 @@ struct volopt_map_entry glusterd_volopt_map[] = { - { .key = "cluster.rsync-hash-regex", - .voltype = "cluster/distribute", - .type = NO_DOC, -- .op_version = 3, -+ .op_version = 2, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "cluster.extra-hash-regex", - .voltype = "cluster/distribute", - .type = NO_DOC, -- .op_version = 3, -+ .op_version = 2, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "cluster.dht-xattr-name", - .voltype = "cluster/distribute", - .option = "xattr-name", - .type = NO_DOC, -- .op_version = 3, -+ .op_version = 2, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "cluster.randomize-hash-range-by-gfid", - .voltype = "cluster/distribute", - .option = "randomize-hash-range-by-gfid", - .type = NO_DOC, -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_3_7_0, - .flags = OPT_FLAG_CLIENT_OPT, - }, - { .key = "cluster.rebal-throttle", -@@ -1327,12 +1327,12 @@ struct volopt_map_entry glusterd_volopt_map[] = { - .voltype = "cluster/nufa", - .option = "local-volume-name", - .type = NO_DOC, -- .op_version = 3, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "cluster.weighted-rebalance", - .voltype = "cluster/distribute", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_3_7_0, - }, +@@ -807,7 +807,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { + {.key = "cluster.subvols-per-directory", + .voltype = "cluster/distribute", + .option = "directory-layout-spread", +- .op_version = 2, ++ .op_version = 1, + .validate_fn = validate_subvols_per_directory, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "cluster.readdir-optimize", +@@ -817,25 +817,25 @@ struct volopt_map_entry glusterd_volopt_map[] = { + {.key = "cluster.rsync-hash-regex", + .voltype = "cluster/distribute", + .type = NO_DOC, +- .op_version = 3, ++ .op_version = 2, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "cluster.extra-hash-regex", + .voltype = "cluster/distribute", + .type = NO_DOC, +- .op_version = 3, ++ .op_version = 2, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "cluster.dht-xattr-name", + .voltype = "cluster/distribute", + .option = "xattr-name", + .type = NO_DOC, +- .op_version = 3, ++ .op_version = 2, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + { + .key = "cluster.randomize-hash-range-by-gfid", + .voltype = "cluster/distribute", + .option = "randomize-hash-range-by-gfid", + .type = NO_DOC, +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_3_7_0, + .flags = VOLOPT_FLAG_CLIENT_OPT, + }, + { +@@ -877,12 +877,12 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .voltype = "cluster/nufa", + .option = "local-volume-name", + .type = NO_DOC, +- .op_version = 3, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + { + .key = "cluster.weighted-rebalance", + .voltype = "cluster/distribute", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_3_7_0, + }, - /* Switch xlator options (Distribute special case) */ -@@ -1340,14 +1340,14 @@ struct volopt_map_entry glusterd_volopt_map[] = { - .voltype = "cluster/distribute", - .option = "!switch", - .type = NO_DOC, -- .op_version = 3, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "cluster.switch-pattern", - .voltype = "cluster/switch", - .option = "pattern.switch.case", - .type = NO_DOC, -- .op_version = 3, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .flags = OPT_FLAG_CLIENT_OPT - }, + /* Switch xlator options (Distribute special case) */ +@@ -890,13 +890,13 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .voltype = "cluster/distribute", + .option = "!switch", + .type = NO_DOC, +- .op_version = 3, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "cluster.switch-pattern", + .voltype = "cluster/switch", + .option = "pattern.switch.case", + .type = NO_DOC, +- .op_version = 3, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .flags = VOLOPT_FLAG_CLIENT_OPT}, -@@ -1475,18 +1475,18 @@ struct volopt_map_entry glusterd_volopt_map[] = { - }, - { .key = "cluster.readdir-failover", - .voltype = "cluster/replicate", -- .op_version = 2, -+ .op_version = 1, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "cluster.ensure-durability", - .voltype = "cluster/replicate", -- .op_version = 3, -+ .op_version = 2, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "cluster.consistent-metadata", - .voltype = "cluster/replicate", - .type = DOC, -- .op_version = GD_OP_VERSION_3_7_0, -+ .op_version = GD_OP_VERSION_RHS_3_0_4, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "cluster.heal-wait-queue-length", -@@ -1562,45 +1562,45 @@ struct volopt_map_entry glusterd_volopt_map[] = { - { .key = "diagnostics.brick-logger", - .voltype = "debug/io-stats", - .option = "!logger", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - }, - { .key = "diagnostics.client-logger", - .voltype = "debug/io-stats", - .option = "!logger", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "diagnostics.brick-log-format", - .voltype = "debug/io-stats", - .option = "!log-format", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - }, - { .key = "diagnostics.client-log-format", - .voltype = "debug/io-stats", - .option = "!log-format", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "diagnostics.brick-log-buf-size", - .voltype = "debug/io-stats", - .option = "!log-buf-size", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - }, - { .key = "diagnostics.client-log-buf-size", - .voltype = "debug/io-stats", - .option = "!log-buf-size", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "diagnostics.brick-log-flush-timeout", - .voltype = "debug/io-stats", - .option = "!log-flush-timeout", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - }, - { .key = "diagnostics.client-log-flush-timeout", - .voltype = "debug/io-stats", - .option = "!log-flush-timeout", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "diagnostics.stats-dump-interval", -@@ -1688,6 +1688,10 @@ struct volopt_map_entry glusterd_volopt_map[] = { - .voltype = "performance/io-threads", - .op_version = 1 - }, -+ { .key = "performance.least-rate-limit", -+ .voltype = "performance/io-threads", -+ .op_version = 1 -+ }, + /* AFR xlator options */ +@@ -1014,16 +1014,16 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "cluster.readdir-failover", + .voltype = "cluster/replicate", +- .op_version = 2, ++ .op_version = 1, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "cluster.ensure-durability", + .voltype = "cluster/replicate", +- .op_version = 3, ++ .op_version = 2, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "cluster.consistent-metadata", + .voltype = "cluster/replicate", + .type = DOC, +- .op_version = GD_OP_VERSION_3_7_0, ++ .op_version = GD_OP_VERSION_RHS_3_0_4, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "cluster.heal-wait-queue-length", + .voltype = "cluster/replicate", +@@ -1080,45 +1080,45 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .key = "diagnostics.brick-logger", + .voltype = "debug/io-stats", + .option = "!logger", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + }, + {.key = "diagnostics.client-logger", + .voltype = "debug/io-stats", + .option = "!logger", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + { + .key = "diagnostics.brick-log-format", + .voltype = "debug/io-stats", + .option = "!log-format", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + }, + {.key = "diagnostics.client-log-format", + .voltype = "debug/io-stats", + .option = "!log-format", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + { + .key = "diagnostics.brick-log-buf-size", + .voltype = "debug/io-stats", + .option = "!log-buf-size", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + }, + {.key = "diagnostics.client-log-buf-size", + .voltype = "debug/io-stats", + .option = "!log-buf-size", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + { + .key = "diagnostics.brick-log-flush-timeout", + .voltype = "debug/io-stats", + .option = "!log-flush-timeout", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + }, + {.key = "diagnostics.client-log-flush-timeout", + .voltype = "debug/io-stats", + .option = "!log-flush-timeout", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "diagnostics.stats-dump-interval", + .voltype = "debug/io-stats", +@@ -1203,6 +1203,10 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .voltype = "performance/io-threads", + .option = "pass-through", + .op_version = GD_OP_VERSION_4_1_0}, ++ {.key = "performance.least-rate-limit", ++ .voltype = "performance/io-threads", ++ .op_version = 1 ++ }, - /* Other perf xlators' options */ - { .key = "performance.cache-size", -@@ -1705,7 +1709,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { - { .key = "performance.nfs.flush-behind", - .voltype = "performance/write-behind", - .option = "flush-behind", -- .op_version = 1, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "performance.write-behind-window-size", -@@ -1731,43 +1735,43 @@ struct volopt_map_entry glusterd_volopt_map[] = { - { .key = "performance.nfs.write-behind-window-size", - .voltype = "performance/write-behind", - .option = "cache-size", -- .op_version = 1, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "performance.strict-o-direct", - .voltype = "performance/write-behind", - .option = "strict-O_DIRECT", -- .op_version = 2, -+ .op_version = 1, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "performance.nfs.strict-o-direct", - .voltype = "performance/write-behind", - .option = "strict-O_DIRECT", -- .op_version = 2, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "performance.strict-write-ordering", - .voltype = "performance/write-behind", - .option = "strict-write-ordering", -- .op_version = 2, -+ .op_version = 1, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "performance.nfs.strict-write-ordering", - .voltype = "performance/write-behind", - .option = "strict-write-ordering", -- .op_version = 2, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "performance.lazy-open", - .voltype = "performance/open-behind", - .option = "lazy-open", -- .op_version = 3, -+ .op_version = 2, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "performance.read-after-open", - .voltype = "performance/open-behind", - .option = "read-after-open", -- .op_version = 3, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "performance.read-ahead-page-count", -@@ -1815,29 +1819,29 @@ struct volopt_map_entry glusterd_volopt_map[] = { + /* Other perf xlators' options */ + {.key = "performance.io-cache-pass-through", +@@ -1237,12 +1241,12 @@ struct volopt_map_entry glusterd_volopt_map[] = { + {.key = "performance.nfs.flush-behind", + .voltype = "performance/write-behind", + .option = "flush-behind", +- .op_version = 1, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "performance.write-behind-window-size", + .voltype = "performance/write-behind", + .option = "cache-size", +- .op_version = 1, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + { + .key = "performance.resync-failed-syncs-after-fsync", +@@ -1262,27 +1266,27 @@ struct volopt_map_entry glusterd_volopt_map[] = { + {.key = "performance.nfs.write-behind-window-size", + .voltype = "performance/write-behind", + .option = "cache-size", +- .op_version = 1, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "performance.strict-o-direct", + .voltype = "performance/write-behind", + .option = "strict-O_DIRECT", +- .op_version = 2, ++ .op_version = 1, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "performance.nfs.strict-o-direct", + .voltype = "performance/write-behind", + .option = "strict-O_DIRECT", +- .op_version = 2, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "performance.strict-write-ordering", + .voltype = "performance/write-behind", + .option = "strict-write-ordering", +- .op_version = 2, ++ .op_version = 1, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "performance.nfs.strict-write-ordering", + .voltype = "performance/write-behind", + .option = "strict-write-ordering", +- .op_version = 2, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "performance.write-behind-trickling-writes", + .voltype = "performance/write-behind", +@@ -1302,12 +1306,12 @@ struct volopt_map_entry glusterd_volopt_map[] = { + {.key = "performance.lazy-open", + .voltype = "performance/open-behind", + .option = "lazy-open", +- .op_version = 3, ++ .op_version = 2, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "performance.read-after-open", + .voltype = "performance/open-behind", + .option = "read-after-open", +- .op_version = 3, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + { + .key = "performance.open-behind-pass-through", +@@ -1389,22 +1393,22 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .voltype = "encryption/crypt", + .option = "!feat", + .value = "off", +- .op_version = 3, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .description = "enable/disable client-side encryption for " + "the volume.", + .flags = VOLOPT_FLAG_CLIENT_OPT | VOLOPT_FLAG_XLATOR_OPT}, - /* Crypt xlator options */ + {.key = "encryption.master-key", + .voltype = "encryption/crypt", +- .op_version = 3, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "encryption.data-key-size", + .voltype = "encryption/crypt", +- .op_version = 3, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + {.key = "encryption.block-size", + .voltype = "encryption/crypt", +- .op_version = 3, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .flags = VOLOPT_FLAG_CLIENT_OPT}, -- { .key = "features.encryption", -- .voltype = "encryption/crypt", -- .option = "!feat", -- .value = "off", -- .op_version = 3, -- .description = "enable/disable client-side encryption for " -+ { .key = "features.encryption", -+ .voltype = "encryption/crypt", -+ .option = "!feat", -+ .value = "off", -+ .op_version = GD_OP_VERSION_RHS_3_0, -+ .description = "enable/disable client-side encryption for " - "the volume.", - .flags = OPT_FLAG_CLIENT_OPT | OPT_FLAG_XLATOR_OPT - }, + /* Client xlator options */ +@@ -1431,7 +1435,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { + {.key = "network.remote-dio", + .voltype = "protocol/client", + .option = "filter-O_DIRECT", +- .op_version = 2, ++ .op_version = 1, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + { + .key = "client.own-thread", +@@ -1443,7 +1447,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { + { + .key = "client.event-threads", + .voltype = "protocol/client", +- .op_version = GD_OP_VERSION_3_7_0, ++ .op_version = GD_OP_VERSION_RHS_3_0_4, + }, + {.key = "client.tcp-user-timeout", + .voltype = "protocol/client", +@@ -1501,7 +1505,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { + {.key = "server.root-squash", + .voltype = "protocol/server", + .option = "root-squash", +- .op_version = 2}, ++ .op_version = 1}, + {.key = "server.all-squash", + .voltype = "protocol/server", + .option = "all-squash", +@@ -1509,11 +1513,11 @@ struct volopt_map_entry glusterd_volopt_map[] = { + {.key = "server.anonuid", + .voltype = "protocol/server", + .option = "anonuid", +- .op_version = 3}, ++ .op_version = GD_OP_VERSION_RHS_3_0}, + {.key = "server.anongid", + .voltype = "protocol/server", + .option = "anongid", +- .op_version = 3}, ++ .op_version = GD_OP_VERSION_RHS_3_0}, + {.key = "server.statedump-path", + .voltype = "protocol/server", + .option = "statedump-path", +@@ -1522,7 +1526,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .voltype = "protocol/server", + .option = "rpc.outstanding-rpc-limit", + .type = GLOBAL_DOC, +- .op_version = 3}, ++ .op_version = 2}, + {.key = "server.ssl", + .voltype = "protocol/server", + .value = "off", +@@ -1540,12 +1544,12 @@ struct volopt_map_entry glusterd_volopt_map[] = { + "the clients that are allowed to access the server." + "By default, all TLS authenticated clients are " + "allowed to access the server.", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_3_7_0, + }, + { + .key = "server.manage-gids", + .voltype = "protocol/server", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + }, + { + .key = "server.dynamic-auth", +@@ -1556,12 +1560,12 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .key = "client.send-gids", + .voltype = "protocol/client", + .type = NO_DOC, +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + }, + { + .key = "server.gid-timeout", + .voltype = "protocol/server", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + }, + { + .key = "server.own-thread", +@@ -1573,7 +1577,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { + { + .key = "server.event-threads", + .voltype = "protocol/server", +- .op_version = GD_OP_VERSION_3_7_0, ++ .op_version = GD_OP_VERSION_RHS_3_0_4, + }, + { + .key = "server.tcp-user-timeout", +@@ -1643,13 +1647,13 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .key = SSL_CERT_DEPTH_OPT, + .voltype = "rpc-transport/socket", + .option = "!ssl-cert-depth", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_3_7_0, + }, + { + .key = SSL_CIPHER_LIST_OPT, + .voltype = "rpc-transport/socket", + .option = "!ssl-cipher-list", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_3_7_0, + }, + { + .key = SSL_DH_PARAM_OPT, +@@ -1690,8 +1694,8 @@ struct volopt_map_entry glusterd_volopt_map[] = { + {.key = "performance.readdir-ahead", + .voltype = "performance/readdir-ahead", + .option = "!perf", +- .value = "on", +- .op_version = 3, ++ .value = "off", ++ .op_version = GD_OP_VERSION_RHS_3_0, + .description = "enable/disable readdir-ahead translator in the volume.", + .flags = VOLOPT_FLAG_CLIENT_OPT | VOLOPT_FLAG_XLATOR_OPT}, + {.key = "performance.io-cache", +@@ -1804,7 +1808,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { + /* Feature translators */ + {.key = "features.uss", + .voltype = "features/snapview-server", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .value = "off", + .flags = VOLOPT_FLAG_CLIENT_OPT | VOLOPT_FLAG_XLATOR_OPT, + .validate_fn = validate_uss, +@@ -1813,7 +1817,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { - { .key = "encryption.master-key", - .voltype = "encryption/crypt", -- .op_version = 3, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "encryption.data-key-size", - .voltype = "encryption/crypt", -- .op_version = 3, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "encryption.block-size", - .voltype = "encryption/crypt", -- .op_version = 3, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .flags = OPT_FLAG_CLIENT_OPT - }, + {.key = "features.snapshot-directory", + .voltype = "features/snapview-client", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .value = ".snaps", + .flags = VOLOPT_FLAG_CLIENT_OPT | VOLOPT_FLAG_XLATOR_OPT, + .validate_fn = validate_uss_dir, +@@ -1823,7 +1827,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { -@@ -1881,7 +1885,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { - { .key = "network.remote-dio", - .voltype = "protocol/client", - .option = "filter-O_DIRECT", -- .op_version = 2, -+ .op_version = 1, - .flags = OPT_FLAG_CLIENT_OPT - }, - { .key = "client.own-thread", -@@ -1892,7 +1896,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { - }, - { .key = "client.event-threads", - .voltype = "protocol/client", -- .op_version = GD_OP_VERSION_3_7_0, -+ .op_version = GD_OP_VERSION_RHS_3_0_4, - }, - { .key = "client.tcp-user-timeout", - .voltype = "protocol/client", -@@ -1960,17 +1964,17 @@ struct volopt_map_entry glusterd_volopt_map[] = { - { .key = "server.root-squash", - .voltype = "protocol/server", - .option = "root-squash", -- .op_version = 2 -+ .op_version = 1 - }, - { .key = "server.anonuid", - .voltype = "protocol/server", - .option = "anonuid", -- .op_version = 3 -+ .op_version = GD_OP_VERSION_RHS_3_0 - }, - { .key = "server.anongid", - .voltype = "protocol/server", - .option = "anongid", -- .op_version = 3 -+ .op_version = GD_OP_VERSION_RHS_3_0 - }, - { .key = "server.statedump-path", - .voltype = "protocol/server", -@@ -1981,7 +1985,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { - .voltype = "protocol/server", - .option = "rpc.outstanding-rpc-limit", - .type = GLOBAL_DOC, -- .op_version = 3 -+ .op_version = 2 - }, - { .key = "features.lock-heal", - .voltype = "protocol/server", -@@ -2007,11 +2011,11 @@ struct volopt_map_entry glusterd_volopt_map[] = { - .option = "!ssl-allow", - .value = "*", - .type = NO_DOC, -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_3_7_0, - }, - { .key = "server.manage-gids", - .voltype = "protocol/server", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - }, - { .key = "server.dynamic-auth", - .voltype = "protocol/server", -@@ -2020,11 +2024,11 @@ struct volopt_map_entry glusterd_volopt_map[] = { - { .key = "client.send-gids", - .voltype = "protocol/client", - .type = NO_DOC, -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - }, - { .key = "server.gid-timeout", - .voltype = "protocol/server", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - }, - { .key = "server.own-thread", - .voltype = "protocol/server", -@@ -2034,7 +2038,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { - }, - { .key = "server.event-threads", - .voltype = "protocol/server", -- .op_version = GD_OP_VERSION_3_7_0, -+ .op_version = GD_OP_VERSION_RHS_3_0_4, - }, - { .key = "server.tcp-user-timeout", - .voltype = "protocol/server", -@@ -2095,12 +2099,12 @@ struct volopt_map_entry glusterd_volopt_map[] = { - { .key = SSL_CERT_DEPTH_OPT, - .voltype = "rpc-transport/socket", - .option = "!ssl-cert-depth", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_3_7_0, - }, - { .key = SSL_CIPHER_LIST_OPT, - .voltype = "rpc-transport/socket", - .option = "!ssl-cipher-list", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_3_7_0, - }, - { .key = SSL_DH_PARAM_OPT, - .voltype = "rpc-transport/socket", -@@ -2140,8 +2144,8 @@ struct volopt_map_entry glusterd_volopt_map[] = { - { .key = "performance.readdir-ahead", - .voltype = "performance/readdir-ahead", - .option = "!perf", -- .value = "on", -- .op_version = 3, -+ .value = "off", -+ .op_version = GD_OP_VERSION_RHS_3_0, - .description = "enable/disable readdir-ahead translator in the volume.", - .flags = OPT_FLAG_CLIENT_OPT | OPT_FLAG_XLATOR_OPT - }, -@@ -2263,7 +2267,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { - /* Feature translators */ - { .key = "features.uss", - .voltype = "features/snapview-server", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .value = "off", - .flags = OPT_FLAG_CLIENT_OPT | OPT_FLAG_XLATOR_OPT, - .validate_fn = validate_uss, -@@ -2273,7 +2277,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { - - { .key = "features.snapshot-directory", - .voltype = "features/snapview-client", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .value = ".snaps", - .flags = OPT_FLAG_CLIENT_OPT | OPT_FLAG_XLATOR_OPT, - .validate_fn = validate_uss_dir, -@@ -2284,7 +2288,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { - - { .key = "features.show-snapshot-directory", - .voltype = "features/snapview-client", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .value = "off", - .flags = OPT_FLAG_CLIENT_OPT | OPT_FLAG_XLATOR_OPT, - .description = "show entry point in readdir output of " -@@ -2299,35 +2303,35 @@ struct volopt_map_entry glusterd_volopt_map[] = { - .voltype = "features/cdc", - .option = "!feat", - .value = "off", -- .op_version = 3, -+ .op_version = GD_OP_VERSION_RHS_3_0, - .description = "enable/disable network compression translator", - .flags = OPT_FLAG_XLATOR_OPT - }, - { .key = "network.compression.window-size", - .voltype = "features/cdc", - .option = "window-size", -- .op_version = 3 -+ .op_version = GD_OP_VERSION_RHS_3_0 - }, - { .key = "network.compression.mem-level", - .voltype = "features/cdc", - .option = "mem-level", -- .op_version = 3 -+ .op_version = GD_OP_VERSION_RHS_3_0 - }, - { .key = "network.compression.min-size", - .voltype = "features/cdc", - .option = "min-size", -- .op_version = 3 -+ .op_version = GD_OP_VERSION_RHS_3_0 - }, - { .key = "network.compression.compression-level", - .voltype = "features/cdc", - .option = "compression-level", -- .op_version = 3 -+ .op_version = GD_OP_VERSION_RHS_3_0 - }, - { .key = "network.compression.debug", - .voltype = "features/cdc", - .option = "debug", - .type = NO_DOC, -- .op_version = 3 -+ .op_version = GD_OP_VERSION_RHS_3_0 - }, + {.key = "features.show-snapshot-directory", + .voltype = "features/snapview-client", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .value = "off", + .flags = VOLOPT_FLAG_CLIENT_OPT | VOLOPT_FLAG_XLATOR_OPT, + .description = "show entry point in readdir output of " +@@ -1847,30 +1851,30 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .voltype = "features/cdc", + .option = "!feat", + .value = "off", +- .op_version = 3, ++ .op_version = GD_OP_VERSION_RHS_3_0, + .description = "enable/disable network compression translator", + .flags = VOLOPT_FLAG_XLATOR_OPT}, + {.key = "network.compression.window-size", + .voltype = "features/cdc", + .option = "window-size", +- .op_version = 3}, ++ .op_version = GD_OP_VERSION_RHS_3_0}, + {.key = "network.compression.mem-level", + .voltype = "features/cdc", + .option = "mem-level", +- .op_version = 3}, ++ .op_version = GD_OP_VERSION_RHS_3_0}, + {.key = "network.compression.min-size", + .voltype = "features/cdc", + .option = "min-size", +- .op_version = 3}, ++ .op_version = GD_OP_VERSION_RHS_3_0}, + {.key = "network.compression.compression-level", + .voltype = "features/cdc", + .option = "compression-level", +- .op_version = 3}, ++ .op_version = GD_OP_VERSION_RHS_3_0}, + {.key = "network.compression.debug", + .voltype = "features/cdc", + .option = "debug", + .type = NO_DOC, +- .op_version = 3}, ++ .op_version = GD_OP_VERSION_RHS_3_0}, #endif -@@ -2342,25 +2346,25 @@ struct volopt_map_entry glusterd_volopt_map[] = { - .voltype = "features/quota", - .option = "default-soft-limit", - .type = NO_DOC, -- .op_version = 3, -+ .op_version = 2, - }, - { .key = "features.soft-timeout", - .voltype = "features/quota", - .option = "soft-timeout", - .type = NO_DOC, -- .op_version = 3, -+ .op_version = 2, - }, - { .key = "features.hard-timeout", - .voltype = "features/quota", - .option = "hard-timeout", - .type = NO_DOC, -- .op_version = 3, -+ .op_version = 2, - }, - { .key = "features.alert-time", - .voltype = "features/quota", - .option = "alert-time", - .type = NO_DOC, -- .op_version = 3, -+ .op_version = 2, - }, - { .key = "features.quota-deem-statfs", - .voltype = "features/quota", -@@ -2474,25 +2478,25 @@ struct volopt_map_entry glusterd_volopt_map[] = { - .voltype = "debug/error-gen", - .option = "failure", - .type = NO_DOC, -- .op_version = 3 -+ .op_version = 2 - }, - { .key = "debug.error-number", - .voltype = "debug/error-gen", - .option = "error-no", - .type = NO_DOC, -- .op_version = 3 -+ .op_version = 2 - }, - { .key = "debug.random-failure", - .voltype = "debug/error-gen", - .option = "random-failure", - .type = NO_DOC, -- .op_version = 3 -+ .op_version = 2 - }, - { .key = "debug.error-fops", - .voltype = "debug/error-gen", - .option = "enable", - .type = NO_DOC, -- .op_version = 3 -+ .op_version = 2 - }, + /* Quota xlator options */ +@@ -1886,28 +1890,28 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .voltype = "features/quota", + .option = "default-soft-limit", + .type = NO_DOC, +- .op_version = 3, ++ .op_version = 2, + }, + { + .key = "features.soft-timeout", + .voltype = "features/quota", + .option = "soft-timeout", + .type = NO_DOC, +- .op_version = 3, ++ .op_version = 2, + }, + { + .key = "features.hard-timeout", + .voltype = "features/quota", + .option = "hard-timeout", + .type = NO_DOC, +- .op_version = 3, ++ .op_version = 2, + }, + { + .key = "features.alert-time", + .voltype = "features/quota", + .option = "alert-time", + .type = NO_DOC, +- .op_version = 3, ++ .op_version = 2, + }, + { + .key = "features.quota-deem-statfs", +@@ -2009,22 +2013,22 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .voltype = "debug/error-gen", + .option = "failure", + .type = NO_DOC, +- .op_version = 3}, ++ .op_version = 2}, + {.key = "debug.error-number", + .voltype = "debug/error-gen", + .option = "error-no", + .type = NO_DOC, +- .op_version = 3}, ++ .op_version = 2}, + {.key = "debug.random-failure", + .voltype = "debug/error-gen", + .option = "random-failure", + .type = NO_DOC, +- .op_version = 3}, ++ .op_version = 2}, + {.key = "debug.error-fops", + .voltype = "debug/error-gen", + .option = "enable", + .type = NO_DOC, +- .op_version = 3}, ++ .op_version = 2}, - -@@ -2543,7 +2547,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { - .voltype = "nfs/server", - .option = "rpc.outstanding-rpc-limit", - .type = GLOBAL_DOC, -- .op_version = 3 -+ .op_version = 2 - }, - { .key = "nfs.port", - .voltype = "nfs/server", -@@ -2619,7 +2623,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { - .voltype = "nfs/server", - .option = "nfs.acl", - .type = GLOBAL_DOC, -- .op_version = 3 -+ .op_version = 2 - }, - { .key = "nfs.mount-udp", - .voltype = "nfs/server", -@@ -2637,13 +2641,13 @@ struct volopt_map_entry glusterd_volopt_map[] = { - .voltype = "nfs/server", - .option = "nfs.rpc-statd", - .type = NO_DOC, -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - }, - { .key = "nfs.log-level", - .voltype = "nfs/server", - .option = "nfs.log-level", - .type = NO_DOC, -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - }, - { .key = "nfs.server-aux-gids", - .voltype = "nfs/server", -@@ -2655,31 +2659,31 @@ struct volopt_map_entry glusterd_volopt_map[] = { - .voltype = "nfs/server", - .option = "nfs.drc", - .type = GLOBAL_DOC, -- .op_version = 3 -+ .op_version = 1 - }, - { .key = "nfs.drc-size", - .voltype = "nfs/server", - .option = "nfs.drc-size", - .type = GLOBAL_DOC, -- .op_version = 3 -+ .op_version = 1 - }, - { .key = "nfs.read-size", - .voltype = "nfs/server", - .option = "nfs3.read-size", - .type = GLOBAL_DOC, -- .op_version = 3 -+ .op_version = 2 - }, - { .key = "nfs.write-size", - .voltype = "nfs/server", - .option = "nfs3.write-size", - .type = GLOBAL_DOC, -- .op_version = 3 -+ .op_version = 2 - }, - { .key = "nfs.readdir-size", - .voltype = "nfs/server", - .option = "nfs3.readdir-size", - .type = GLOBAL_DOC, -- .op_version = 3 -+ .op_version = 2 - }, - { .key = "nfs.rdirplus", - .voltype = "nfs/server", -@@ -2714,7 +2718,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { - { .key = "features.read-only", - .voltype = "features/read-only", - .option = "read-only", -- .op_version = 1, -+ .op_version = 2, - .flags = OPT_FLAG_CLIENT_OPT | OPT_FLAG_XLATOR_OPT - }, - { .key = "features.worm", -@@ -2757,15 +2761,15 @@ struct volopt_map_entry glusterd_volopt_map[] = { - }, - { .key = "storage.batch-fsync-mode", - .voltype = "storage/posix", -- .op_version = 3 -+ .op_version = 2 - }, - { .key = "storage.batch-fsync-delay-usec", - .voltype = "storage/posix", -- .op_version = 3 -+ .op_version = 2 - }, - { .key = "storage.xattr-user-namespace-mode", - .voltype = "storage/posix", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - }, - { .key = "storage.owner-uid", - .voltype = "storage/posix", -@@ -2779,16 +2783,16 @@ struct volopt_map_entry glusterd_volopt_map[] = { - }, - { .key = "storage.node-uuid-pathinfo", - .voltype = "storage/posix", -- .op_version = 3 -+ .op_version = 2 - }, - { .key = "storage.health-check-interval", - .voltype = "storage/posix", -- .op_version = 3 -+ .op_version = 2 - }, - { .option = "update-link-count-parent", - .key = "storage.build-pgfid", - .voltype = "storage/posix", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - }, - { .option = "gfid2path", - .key = "storage.gfid2path", -@@ -2803,7 +2807,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { - }, - { .key = "storage.bd-aio", - .voltype = "storage/bd", -- .op_version = 3 -+ .op_version = GD_OP_VERSION_RHS_3_0 - }, - { .key = "config.memory-accounting", - .voltype = "mgmt/glusterd", -@@ -2819,43 +2823,43 @@ struct volopt_map_entry glusterd_volopt_map[] = { - { .key = GLUSTERD_QUORUM_TYPE_KEY, - .voltype = "mgmt/glusterd", - .value = "off", -- .op_version = 2 -+ .op_version = 1 - }, - { .key = GLUSTERD_QUORUM_RATIO_KEY, - .voltype = "mgmt/glusterd", - .value = "0", -- .op_version = 2 -+ .op_version = 1 - }, - /* changelog translator - global tunables */ - { .key = "changelog.changelog", - .voltype = "features/changelog", - .type = NO_DOC, -- .op_version = 3 -+ .op_version = 2 - }, - { .key = "changelog.changelog-dir", - .voltype = "features/changelog", - .type = NO_DOC, -- .op_version = 3 -+ .op_version = 2 - }, - { .key = "changelog.encoding", - .voltype = "features/changelog", - .type = NO_DOC, -- .op_version = 3 -+ .op_version = 2 - }, - { .key = "changelog.rollover-time", - .voltype = "features/changelog", - .type = NO_DOC, -- .op_version = 3 -+ .op_version = 2 - }, - { .key = "changelog.fsync-interval", - .voltype = "features/changelog", - .type = NO_DOC, -- .op_version = 3 -+ .op_version = 2 - }, - { .key = "changelog.changelog-barrier-timeout", - .voltype = "features/changelog", - .value = BARRIER_TIMEOUT, -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - }, - { .key = "changelog.capture-del-path", - .voltype = "features/changelog", -@@ -2866,16 +2870,16 @@ struct volopt_map_entry glusterd_volopt_map[] = { - .voltype = "features/barrier", - .value = "disable", - .type = NO_DOC, -- .op_version = GD_OP_VERSION_3_7_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - }, - { .key = "features.barrier-timeout", - .voltype = "features/barrier", - .value = BARRIER_TIMEOUT, -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - }, - { .key = GLUSTERD_GLOBAL_OP_VERSION_KEY, - .voltype = "mgmt/glusterd", -- .op_version = GD_OP_VERSION_3_6_0, -+ .op_version = GD_OP_VERSION_RHS_3_0, - }, - { - .key = GLUSTERD_MAX_OP_VERSION_KEY, + /* NFS xlator options */ + {.key = "nfs.enable-ino32", +@@ -2066,7 +2070,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .voltype = "nfs/server", + .option = "rpc.outstanding-rpc-limit", + .type = GLOBAL_DOC, +- .op_version = 3}, ++ .op_version = 2}, + {.key = "nfs.port", + .voltype = "nfs/server", + .option = "nfs.port", +@@ -2128,7 +2132,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .voltype = "nfs/server", + .option = "nfs.acl", + .type = GLOBAL_DOC, +- .op_version = 3}, ++ .op_version = 2}, + {.key = "nfs.mount-udp", + .voltype = "nfs/server", + .option = "nfs.mount-udp", +@@ -2144,14 +2148,14 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .voltype = "nfs/server", + .option = "nfs.rpc-statd", + .type = NO_DOC, +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + }, + { + .key = "nfs.log-level", + .voltype = "nfs/server", + .option = "nfs.log-level", + .type = NO_DOC, +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + }, + {.key = "nfs.server-aux-gids", + .voltype = "nfs/server", +@@ -2162,27 +2166,27 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .voltype = "nfs/server", + .option = "nfs.drc", + .type = GLOBAL_DOC, +- .op_version = 3}, ++ .op_version = 1}, + {.key = "nfs.drc-size", + .voltype = "nfs/server", + .option = "nfs.drc-size", + .type = GLOBAL_DOC, +- .op_version = 3}, ++ .op_version = 1}, + {.key = "nfs.read-size", + .voltype = "nfs/server", + .option = "nfs3.read-size", + .type = GLOBAL_DOC, +- .op_version = 3}, ++ .op_version = 2}, + {.key = "nfs.write-size", + .voltype = "nfs/server", + .option = "nfs3.write-size", + .type = GLOBAL_DOC, +- .op_version = 3}, ++ .op_version = 2}, + {.key = "nfs.readdir-size", + .voltype = "nfs/server", + .option = "nfs3.readdir-size", + .type = GLOBAL_DOC, +- .op_version = 3}, ++ .op_version = 2}, + {.key = "nfs.rdirplus", + .voltype = "nfs/server", + .option = "nfs.rdirplus", +@@ -2219,7 +2223,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { + {.key = "features.read-only", + .voltype = "features/read-only", + .option = "read-only", +- .op_version = 1, ++ .op_version = 2, + .flags = VOLOPT_FLAG_CLIENT_OPT | VOLOPT_FLAG_XLATOR_OPT}, + {.key = "features.worm", + .voltype = "features/worm", +@@ -2266,14 +2270,14 @@ struct volopt_map_entry glusterd_volopt_map[] = { + {.key = "storage.linux-aio", .voltype = "storage/posix", .op_version = 1}, + {.key = "storage.batch-fsync-mode", + .voltype = "storage/posix", +- .op_version = 3}, ++ .op_version = 2}, + {.key = "storage.batch-fsync-delay-usec", + .voltype = "storage/posix", +- .op_version = 3}, ++ .op_version = 2}, + { + .key = "storage.xattr-user-namespace-mode", + .voltype = "storage/posix", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + }, + {.key = "storage.owner-uid", + .voltype = "storage/posix", +@@ -2285,15 +2289,15 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .op_version = 1}, + {.key = "storage.node-uuid-pathinfo", + .voltype = "storage/posix", +- .op_version = 3}, ++ .op_version = 2}, + {.key = "storage.health-check-interval", + .voltype = "storage/posix", +- .op_version = 3}, ++ .op_version = 2}, + { + .option = "update-link-count-parent", + .key = "storage.build-pgfid", + .voltype = "storage/posix", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + }, + { + .option = "gfid2path", +@@ -2363,7 +2367,9 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .voltype = "storage/posix", + .op_version = GD_OP_VERSION_4_1_0, + }, +- {.key = "storage.bd-aio", .voltype = "storage/bd", .op_version = 3}, ++ {.key = "storage.bd-aio", ++ .voltype = "storage/bd", ++ .op_version = GD_OP_VERSION_RHS_3_0}, + {.key = "config.memory-accounting", + .voltype = "mgmt/glusterd", + .option = "!config", +@@ -2385,37 +2391,37 @@ struct volopt_map_entry glusterd_volopt_map[] = { + {.key = GLUSTERD_QUORUM_TYPE_KEY, + .voltype = "mgmt/glusterd", + .value = "off", +- .op_version = 2}, ++ .op_version = 1}, + {.key = GLUSTERD_QUORUM_RATIO_KEY, + .voltype = "mgmt/glusterd", + .value = "0", +- .op_version = 2}, ++ .op_version = 1}, + /* changelog translator - global tunables */ + {.key = "changelog.changelog", + .voltype = "features/changelog", + .type = NO_DOC, +- .op_version = 3}, ++ .op_version = 2}, + {.key = "changelog.changelog-dir", + .voltype = "features/changelog", + .type = NO_DOC, +- .op_version = 3}, ++ .op_version = 2}, + {.key = "changelog.encoding", + .voltype = "features/changelog", + .type = NO_DOC, +- .op_version = 3}, ++ .op_version = 2}, + {.key = "changelog.rollover-time", + .voltype = "features/changelog", + .type = NO_DOC, +- .op_version = 3}, ++ .op_version = 2}, + {.key = "changelog.fsync-interval", + .voltype = "features/changelog", + .type = NO_DOC, +- .op_version = 3}, ++ .op_version = 2}, + { + .key = "changelog.changelog-barrier-timeout", + .voltype = "features/changelog", + .value = BARRIER_TIMEOUT, +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + }, + {.key = "changelog.capture-del-path", + .voltype = "features/changelog", +@@ -2426,18 +2432,18 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .voltype = "features/barrier", + .value = "disable", + .type = NO_DOC, +- .op_version = GD_OP_VERSION_3_7_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + }, + { + .key = "features.barrier-timeout", + .voltype = "features/barrier", + .value = BARRIER_TIMEOUT, +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + }, + { + .key = GLUSTERD_GLOBAL_OP_VERSION_KEY, + .voltype = "mgmt/glusterd", +- .op_version = GD_OP_VERSION_3_6_0, ++ .op_version = GD_OP_VERSION_RHS_3_0, + }, + { + .key = GLUSTERD_MAX_OP_VERSION_KEY, +diff --git a/xlators/protocol/client/src/client.c b/xlators/protocol/client/src/client.c +index c8e84f6..dea6c28 100644 +--- a/xlators/protocol/client/src/client.c ++++ b/xlators/protocol/client/src/client.c +@@ -3002,7 +3002,7 @@ struct volume_options options[] = { + {.key = {"send-gids"}, + .type = GF_OPTION_TYPE_BOOL, + .default_value = "on", +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE}, + {.key = {"event-threads"}, + .type = GF_OPTION_TYPE_INT, +@@ -3013,7 +3013,7 @@ struct volume_options options[] = { + "in parallel. Larger values would help process" + " responses faster, depending on available processing" + " power. Range 1-32 threads.", +- .op_version = {GD_OP_VERSION_3_7_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE | OPT_FLAG_DOC}, + {.key = {NULL}}, + }; +diff --git a/xlators/protocol/server/src/server.c b/xlators/protocol/server/src/server.c +index b4b447b..6ae63ba 100644 +--- a/xlators/protocol/server/src/server.c ++++ b/xlators/protocol/server/src/server.c +@@ -1854,13 +1854,13 @@ struct volume_options server_options[] = { + .type = GF_OPTION_TYPE_BOOL, + .default_value = "off", + .description = "Resolve groups on the server-side.", +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE | OPT_FLAG_DOC}, + {.key = {"gid-timeout"}, + .type = GF_OPTION_TYPE_INT, + .default_value = "300", + .description = "Timeout in seconds for the cached groups to expire.", +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE | OPT_FLAG_DOC}, + {.key = {"event-threads"}, + .type = GF_OPTION_TYPE_INT, +@@ -1871,7 +1871,7 @@ struct volume_options server_options[] = { + "in parallel. Larger values would help process" + " responses faster, depending on available processing" + " power.", +- .op_version = {GD_OP_VERSION_3_7_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE | OPT_FLAG_DOC}, + {.key = {"dynamic-auth"}, + .type = GF_OPTION_TYPE_BOOL, +diff --git a/xlators/storage/posix/src/posix-common.c b/xlators/storage/posix/src/posix-common.c +index f0d8e3f..ed82e35 100644 +--- a/xlators/storage/posix/src/posix-common.c ++++ b/xlators/storage/posix/src/posix-common.c +@@ -1243,7 +1243,7 @@ struct volume_options posix_options[] = { + .type = GF_OPTION_TYPE_BOOL, + .default_value = "off", + .description = "Enable placeholders for gfid to path conversion", +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE | OPT_FLAG_DOC}, + {.key = {"gfid2path"}, + .type = GF_OPTION_TYPE_BOOL, +@@ -1279,7 +1279,7 @@ struct volume_options posix_options[] = { + " The raw filesystem will not be compatible with OS X Finder.\n" + "\t- Strip: Will strip the user namespace before setting. The raw " + "filesystem will work in OS X.\n", +- .op_version = {GD_OP_VERSION_3_6_0}, ++ .op_version = {GD_OP_VERSION_RHS_3_0}, + .flags = OPT_FLAG_SETTABLE | OPT_FLAG_DOC}, + #endif + { -- 1.8.3.1 diff --git a/0003-rpc-set-bind-insecure-to-off-by-default.patch b/0003-rpc-set-bind-insecure-to-off-by-default.patch new file mode 100644 index 0000000..639b62f --- /dev/null +++ b/0003-rpc-set-bind-insecure-to-off-by-default.patch @@ -0,0 +1,51 @@ +From 9b58731c83bc1ee9c5f2a3cd58a8f845cf09ee82 Mon Sep 17 00:00:00 2001 +From: Prasanna Kumar Kalever +Date: Mon, 21 Mar 2016 13:54:19 +0530 +Subject: [PATCH 03/52] rpc: set bind-insecure to off by default + +commit 243a5b429f225acb8e7132264fe0a0835ff013d5 turn's 'ON' +allow-insecure and bind-insecure by default. + +Problem: +Now with newer versions we have bind-insecure 'ON' by default. +So, while upgrading subset of nodes from a trusted storage pool, +nodes which have older versions of glusterfs will expect +connection from secure ports only (since they still have +bind-insecure off) thus they reject connection from upgraded +nodes which now have insecure ports. + +Hence we will run into connection issues between peers. + +Solution: +This patch will turn bind-insecure 'OFF' by default to avoid +problem explained above. + +Label: DOWNSTREAM ONLY + +Change-Id: Id7a19b4872399d3b019243b0857c9c7af75472f7 +Signed-off-by: Prasanna Kumar Kalever +Reviewed-on: https://code.engineering.redhat.com/gerrit/70313 +Reviewed-by: Atin Mukherjee +Tested-by: Atin Mukherjee +--- + rpc/rpc-lib/src/rpc-transport.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/rpc/rpc-lib/src/rpc-transport.c b/rpc/rpc-lib/src/rpc-transport.c +index f9cbdf1..4beaaf9 100644 +--- a/rpc/rpc-lib/src/rpc-transport.c ++++ b/rpc/rpc-lib/src/rpc-transport.c +@@ -269,8 +269,8 @@ rpc_transport_load(glusterfs_ctx_t *ctx, dict_t *options, char *trans_name) + else + trans->bind_insecure = 0; + } else { +- /* By default allow bind insecure */ +- trans->bind_insecure = 1; ++ /* Turning off bind insecure by default*/ ++ trans->bind_insecure = 0; + } + + ret = dict_get_str(options, "transport-type", &type); +-- +1.8.3.1 + diff --git a/0004-glusterd-spec-fixing-autogen-issue.patch b/0004-glusterd-spec-fixing-autogen-issue.patch new file mode 100644 index 0000000..f3cb2ec --- /dev/null +++ b/0004-glusterd-spec-fixing-autogen-issue.patch @@ -0,0 +1,47 @@ +From aa73240892a7072be68772370fd95173e6e77d10 Mon Sep 17 00:00:00 2001 +From: Atin Mukherjee +Date: Mon, 21 Mar 2016 17:07:00 +0530 +Subject: [PATCH 04/52] glusterd/spec: fixing autogen issue + +Backport of https://code.engineering.redhat.com/gerrit/#/c/59463/ + +Because of the incorrect build section, autogen.sh wasn't re-run during the rpm +build process. The `extras/Makefile.in` was not regenerated with the changes +made to `extras/Makefile.am` in the firewalld patch. This meant that +`extras/Makefile` was generated without the firewalld changes. So the firewalld +config wasn't installed during `make install` and rpmbuild later failed when it +failed to find `/usr/lib/firewalld/glusterfs.xml` + +Label: DOWNSTREAM ONLY + +>Reviewed-on: https://code.engineering.redhat.com/gerrit/59463 + +Change-Id: I498bcceeacbd839640282eb6467c9f1464505697 +Signed-off-by: Atin Mukherjee +Reviewed-on: https://code.engineering.redhat.com/gerrit/70343 +Reviewed-by: Milind Changire +--- + glusterfs.spec.in | 7 +------ + 1 file changed, 1 insertion(+), 6 deletions(-) + +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index c655f16..f5c1f79 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -700,12 +700,7 @@ done + + %build + +-# RHEL6 and earlier need to manually replace config.guess and config.sub +-%if ( 0%{?rhel} && 0%{?rhel} <= 6 ) +-./autogen.sh +-%endif +- +-%configure \ ++./autogen.sh && %configure \ + %{?_with_asan} \ + %{?_with_cmocka} \ + %{?_with_debug} \ +-- +1.8.3.1 + diff --git a/0005-libglusterfs-glusterd-Fix-compilation-errors.patch b/0005-libglusterfs-glusterd-Fix-compilation-errors.patch new file mode 100644 index 0000000..5aa4f20 --- /dev/null +++ b/0005-libglusterfs-glusterd-Fix-compilation-errors.patch @@ -0,0 +1,36 @@ +From 44f758a56c5c5ad340ebc6d6a6478e8712c2c101 Mon Sep 17 00:00:00 2001 +From: Atin Mukherjee +Date: Mon, 21 Mar 2016 22:31:02 +0530 +Subject: [PATCH 05/52] libglusterfs/glusterd: Fix compilation errors + +1. Removed duplicate definition of GD_OP_VER_PERSISTENT_AFR_XATTRS introduced in +d367a88 where GD_OP_VER_PERSISTENT_AFR_XATTRS was redfined + +2. Fixed incorrect op-version + +Label: DOWNSTREAM ONLY + +Change-Id: Icfa3206e8a41a11875641f57523732b80837f8f6 +Signed-off-by: Atin Mukherjee +Reviewed-on: https://code.engineering.redhat.com/gerrit/70384 +Reviewed-by: Nithya Balachandran +--- + xlators/mgmt/glusterd/src/glusterd-store.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/xlators/mgmt/glusterd/src/glusterd-store.c b/xlators/mgmt/glusterd/src/glusterd-store.c +index 64447e7..51ca3d1 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-store.c ++++ b/xlators/mgmt/glusterd/src/glusterd-store.c +@@ -967,7 +967,7 @@ glusterd_volume_exclude_options_write(int fd, glusterd_volinfo_t *volinfo) + goto out; + } + +- if (conf->op_version >= GD_OP_VERSION_RHS_3_0) { ++ if (conf->op_version >= GD_OP_VERSION_3_7_0) { + snprintf(buf, sizeof(buf), "%d", volinfo->disperse_count); + ret = gf_store_save_value(fd, GLUSTERD_STORE_KEY_VOL_DISPERSE_CNT, buf); + if (ret) +-- +1.8.3.1 + diff --git a/0006-build-remove-ghost-directory-entries.patch b/0006-build-remove-ghost-directory-entries.patch new file mode 100644 index 0000000..68dd8f3 --- /dev/null +++ b/0006-build-remove-ghost-directory-entries.patch @@ -0,0 +1,58 @@ +From 1f28e008825ae291208a9e6c714dd642f715a2a1 Mon Sep 17 00:00:00 2001 +From: "Bala.FA" +Date: Mon, 7 Apr 2014 15:24:10 +0530 +Subject: [PATCH 06/52] build: remove ghost directory entries + +ovirt requires hook directories for gluster management and ghost +directories are no more ghost entries + +Label: DOWNSTREAM ONLY + +Change-Id: Iaf1066ba0655619024f87eaaa039f0010578c567 +Signed-off-by: Bala.FA +Reviewed-on: https://code.engineering.redhat.com/gerrit/60133 +Tested-by: Milind Changire +--- + glusterfs.spec.in | 19 +++++++++++++++++-- + 1 file changed, 17 insertions(+), 2 deletions(-) + +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index f5c1f79..6be492e 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -799,15 +799,30 @@ install -D -p -m 0644 extras/glusterfs-logrotate \ + %{buildroot}%{_sysconfdir}/logrotate.d/glusterfs + + %if ( 0%{!?_without_georeplication:1} ) +-# geo-rep ghosts + mkdir -p %{buildroot}%{_sharedstatedir}/glusterd/geo-replication + touch %{buildroot}%{_sharedstatedir}/glusterd/geo-replication/gsyncd_template.conf + install -D -p -m 0644 extras/glusterfs-georep-logrotate \ + %{buildroot}%{_sysconfdir}/logrotate.d/glusterfs-georep + %endif + ++%if ( 0%{!?_without_syslog:1} ) ++%if ( 0%{?fedora} ) || ( 0%{?rhel} && 0%{?rhel} > 6 ) ++install -D -p -m 0644 extras/gluster-rsyslog-7.2.conf \ ++ %{buildroot}%{_sysconfdir}/rsyslog.d/gluster.conf.example ++%endif ++ ++%if ( 0%{?rhel} && 0%{?rhel} == 6 ) ++install -D -p -m 0644 extras/gluster-rsyslog-5.8.conf \ ++ %{buildroot}%{_sysconfdir}/rsyslog.d/gluster.conf.example ++%endif ++ ++%if ( 0%{?fedora} ) || ( 0%{?rhel} && 0%{?rhel} >= 6 ) ++install -D -p -m 0644 extras/logger.conf.example \ ++ %{buildroot}%{_sysconfdir}/glusterfs/logger.conf.example ++%endif ++%endif ++ + %if ( 0%{!?_without_server:1} ) +-# the rest of the ghosts + touch %{buildroot}%{_sharedstatedir}/glusterd/glusterd.info + touch %{buildroot}%{_sharedstatedir}/glusterd/options + subdirs=(add-brick create copy-file delete gsync-create remove-brick reset set start stop) +-- +1.8.3.1 + diff --git a/0007-build-add-RHGS-specific-changes.patch b/0007-build-add-RHGS-specific-changes.patch new file mode 100644 index 0000000..ac092bd --- /dev/null +++ b/0007-build-add-RHGS-specific-changes.patch @@ -0,0 +1,620 @@ +From 7744475550cd27f58f536741e9c50c639d3b02d8 Mon Sep 17 00:00:00 2001 +From: "Bala.FA" +Date: Thu, 6 Dec 2018 20:06:27 +0530 +Subject: [PATCH 07/52] build: add RHGS specific changes + +Label: DOWNSTREAM ONLY + +Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1074947 +Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1097782 +Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1115267 +Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1221743 +Change-Id: I08333334745adf2350e772c6454ffcfe9c08cb89 +Reviewed-on: https://code.engineering.redhat.com/gerrit/24983 +Reviewed-on: https://code.engineering.redhat.com/gerrit/25451 +Reviewed-on: https://code.engineering.redhat.com/gerrit/25518 +Reviewed-on: https://code.engineering.redhat.com/gerrit/25983 +Signed-off-by: Bala.FA +Reviewed-on: https://code.engineering.redhat.com/gerrit/60134 +Tested-by: Milind Changire +--- + glusterfs.spec.in | 485 +++++++++++++++++++++++++++++++++++++++++++++++++++++- + 1 file changed, 481 insertions(+), 4 deletions(-) + +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index 6be492e..eb04491 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -95,9 +95,16 @@ + %{?_without_server:%global _without_server --without-server} + + # disable server components forcefully as rhel <= 6 +-%if ( 0%{?rhel} && 0%{?rhel} <= 6 ) ++%if ( 0%{?rhel} ) ++%if ( "%{?dist}" == ".el6rhs" ) || ( "%{?dist}" == ".el7rhs" ) || ( "%{?dist}" == ".el7rhgs" ) ++%global _without_server %{nil} ++%else + %global _without_server --without-server + %endif ++%endif ++ ++%global _without_extra_xlators 1 ++%global _without_regression_tests 1 + + # syslog + # if you wish to build rpms without syslog logging, compile like this +@@ -229,7 +236,8 @@ Release: 0.1%{?prereltag:.%{prereltag}}%{?dist} + %else + Name: @PACKAGE_NAME@ + Version: @PACKAGE_VERSION@ +-Release: 0.@PACKAGE_RELEASE@%{?dist} ++Release: @PACKAGE_RELEASE@%{?dist} ++ExcludeArch: i686 + %endif + License: GPLv2 or LGPLv3+ + URL: http://docs.gluster.org/ +@@ -243,8 +251,6 @@ Source8: glusterfsd.init + Source0: @PACKAGE_NAME@-@PACKAGE_VERSION@.tar.gz + %endif + +-BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX) +- + Requires(pre): shadow-utils + %if ( 0%{?_with_systemd:1} ) + BuildRequires: systemd +@@ -384,7 +390,9 @@ This package provides cloudsync plugins for archival feature. + Summary: Development Libraries + Requires: %{name}%{?_isa} = %{version}-%{release} + # Needed for the Glupy examples to work ++%if ( 0%{!?_without_extra_xlators:1} ) + Requires: %{name}-extra-xlators%{?_isa} = %{version}-%{release} ++%endif + + %description devel + GlusterFS is a distributed file-system capable of scaling to several +@@ -397,6 +405,7 @@ is in user space and easily manageable. + + This package provides the development libraries and include files. + ++%if ( 0%{!?_without_extra_xlators:1} ) + %package extra-xlators + Summary: Extra Gluster filesystem Translators + # We need python-gluster rpm for gluster module's __init__.py in Python +@@ -415,6 +424,7 @@ is in user space and easily manageable. + + This package provides extra filesystem Translators, such as Glupy, + for GlusterFS. ++%endif + + %package fuse + Summary: Fuse client +@@ -440,6 +450,30 @@ is in user space and easily manageable. + This package provides support to FUSE based clients and inlcudes the + glusterfs(d) binary. + ++%if ( 0%{!?_without_server:1} ) ++%package ganesha ++Summary: NFS-Ganesha configuration ++Group: Applications/File ++ ++Requires: %{name}-server%{?_isa} = %{version}-%{release} ++Requires: nfs-ganesha-gluster, pcs, dbus ++%if ( 0%{?rhel} && 0%{?rhel} == 6 ) ++Requires: cman, pacemaker, corosync ++%endif ++ ++%description ganesha ++GlusterFS is a distributed file-system capable of scaling to several ++petabytes. It aggregates various storage bricks over Infiniband RDMA ++or TCP/IP interconnect into one large parallel network file ++system. GlusterFS is one of the most sophisticated file systems in ++terms of features and extensibility. It borrows a powerful concept ++called Translators from GNU Hurd kernel. Much of the code in GlusterFS ++is in user space and easily manageable. ++ ++This package provides the configuration and related files for using ++NFS-Ganesha as the NFS server using GlusterFS ++%endif ++ + %if ( 0%{!?_without_georeplication:1} ) + %package geo-replication + Summary: GlusterFS Geo-replication +@@ -541,6 +575,7 @@ is in user space and easily manageable. + This package provides support to ib-verbs library. + %endif + ++%if ( 0%{!?_without_regression_tests:1} ) + %package regression-tests + Summary: Development Tools + Requires: %{name}%{?_isa} = %{version}-%{release} +@@ -556,6 +591,7 @@ Requires: nfs-utils xfsprogs yajl psmisc bc + %description regression-tests + The Gluster Test Framework, is a suite of scripts used for + regression testing of Gluster. ++%endif + + %if ( 0%{!?_without_ocf:1} ) + %package resource-agents +@@ -1092,6 +1128,16 @@ exit 0 + %if 0%{?_tmpfilesdir:1} && 0%{!?_without_server:1} + %{_tmpfilesdir}/gluster.conf + %endif ++%if ( 0%{?_without_extra_xlators:1} ) ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/encryption/rot-13.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/quiesce.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/playground/template.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/testing/performance/symlink-cache.so ++%endif ++%if ( 0%{?_without_regression_tests:1} ) ++%exclude %{_datadir}/glusterfs/run-tests.sh ++%exclude %{_datadir}/glusterfs/tests ++%endif + + %files api + %exclude %{_libdir}/*.so +@@ -1134,12 +1180,14 @@ exit 0 + %dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/protocol + %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/protocol/client.so + ++%if ( 0%{!?_without_extra_xlators:1} ) + %files extra-xlators + %dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator + %dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features + %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/quiesce.so + %dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/playground + %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/playground/template.so ++%endif + + %files fuse + # glusterfs is a symlink to glusterfsd, -server depends on -fuse. +@@ -1239,11 +1287,13 @@ exit 0 + %{_libdir}/glusterfs/%{version}%{?prereltag}/rpc-transport/rdma* + %endif + ++%if ( 0%{!?_without_regression_tests:1} ) + %files regression-tests + %dir %{_datadir}/glusterfs + %{_datadir}/glusterfs/run-tests.sh + %{_datadir}/glusterfs/tests + %exclude %{_datadir}/glusterfs/tests/vagrant ++%endif + + %if ( 0%{!?_without_ocf:1} ) + %files resource-agents +@@ -1424,6 +1474,433 @@ exit 0 + %endif + %endif + ++##----------------------------------------------------------------------------- ++## All %pretrans should be placed here and keep them sorted ++## ++%if 0%{!?_without_server:1} ++%pretrans -p ++if not posix.access("/bin/bash", "x") then ++ -- initial installation, no shell, no running glusterfsd ++ return 0 ++end ++ ++-- TODO: move this completely to a lua script ++-- For now, we write a temporary bash script and execute that. ++ ++script = [[#!/bin/sh ++pidof -c -o %PPID -x glusterfsd &>/dev/null ++ ++if [ $? -eq 0 ]; then ++ pushd . > /dev/null 2>&1 ++ for volume in /var/lib/glusterd/vols/*; do cd $volume; ++ vol_type=`grep '^type=' info | awk -F'=' '{print $2}'` ++ volume_started=`grep '^status=' info | awk -F'=' '{print $2}'` ++ if [ $vol_type -eq 0 ] && [ $volume_started -eq 1 ] ; then ++ echo "ERROR: Distribute volumes detected. In-service rolling upgrade requires distribute volume(s) to be stopped." ++ echo "ERROR: Please stop distribute volume(s) before proceeding... exiting!" ++ exit 1; ++ fi ++ done ++ ++ popd > /dev/null 2>&1 ++ echo "WARNING: Updating glusterfs requires its processes to be killed. This action does NOT incur downtime." ++ echo "WARNING: Ensure to wait for the upgraded server to finish healing before proceeding." ++ echo "WARNING: Refer upgrade section of install guide for more details" ++ echo "Please run # service glusterd stop; pkill glusterfs; pkill glusterfsd; pkill gsyncd.py;" ++ exit 1; ++fi ++]] ++ ++-- rpm in RHEL5 does not have os.tmpname() ++-- io.tmpfile() can not be resolved to a filename to pass to bash :-/ ++tmpname = "/tmp/glusterfs_pretrans_" .. os.date("%s") ++tmpfile = io.open(tmpname, "w") ++tmpfile:write(script) ++tmpfile:close() ++ok, how, val = os.execute("/bin/bash " .. tmpname) ++os.remove(tmpname) ++if not (ok == 0) then ++ error("Detected running glusterfs processes", ok) ++end ++ ++ ++ ++%pretrans api -p ++if not posix.access("/bin/bash", "x") then ++ -- initial installation, no shell, no running glusterfsd ++ return 0 ++end ++ ++-- TODO: move this completely to a lua script ++-- For now, we write a temporary bash script and execute that. ++ ++script = [[#!/bin/sh ++pidof -c -o %PPID -x glusterfsd &>/dev/null ++ ++if [ $? -eq 0 ]; then ++ pushd . > /dev/null 2>&1 ++ for volume in /var/lib/glusterd/vols/*; do cd $volume; ++ vol_type=`grep '^type=' info | awk -F'=' '{print $2}'` ++ volume_started=`grep '^status=' info | awk -F'=' '{print $2}'` ++ if [ $vol_type -eq 0 ] && [ $volume_started -eq 1 ] ; then ++ exit 1; ++ fi ++ done ++ ++ popd > /dev/null 2>&1 ++ exit 1; ++fi ++]] ++ ++-- rpm in RHEL5 does not have os.tmpname() ++-- io.tmpfile() can not be resolved to a filename to pass to bash :-/ ++tmpname = "/tmp/glusterfs-api_pretrans_" .. os.date("%s") ++tmpfile = io.open(tmpname, "w") ++tmpfile:write(script) ++tmpfile:close() ++ok, how, val = os.execute("/bin/bash " .. tmpname) ++os.remove(tmpname) ++if not (ok == 0) then ++ error("Detected running glusterfs processes", ok) ++end ++ ++ ++ ++%pretrans api-devel -p ++if not posix.access("/bin/bash", "x") then ++ -- initial installation, no shell, no running glusterfsd ++ return 0 ++end ++ ++-- TODO: move this completely to a lua script ++-- For now, we write a temporary bash script and execute that. ++ ++script = [[#!/bin/sh ++pidof -c -o %PPID -x glusterfsd &>/dev/null ++ ++if [ $? -eq 0 ]; then ++ pushd . > /dev/null 2>&1 ++ for volume in /var/lib/glusterd/vols/*; do cd $volume; ++ vol_type=`grep '^type=' info | awk -F'=' '{print $2}'` ++ volume_started=`grep '^status=' info | awk -F'=' '{print $2}'` ++ if [ $vol_type -eq 0 ] && [ $volume_started -eq 1 ] ; then ++ exit 1; ++ fi ++ done ++ ++ popd > /dev/null 2>&1 ++ exit 1; ++fi ++]] ++ ++-- rpm in RHEL5 does not have os.tmpname() ++-- io.tmpfile() can not be resolved to a filename to pass to bash :-/ ++tmpname = "/tmp/glusterfs-api-devel_pretrans_" .. os.date("%s") ++tmpfile = io.open(tmpname, "w") ++tmpfile:write(script) ++tmpfile:close() ++ok, how, val = os.execute("/bin/bash " .. tmpname) ++os.remove(tmpname) ++if not (ok == 0) then ++ error("Detected running glusterfs processes", ok) ++end ++ ++ ++ ++%pretrans devel -p ++if not posix.access("/bin/bash", "x") then ++ -- initial installation, no shell, no running glusterfsd ++ return 0 ++end ++ ++-- TODO: move this completely to a lua script ++-- For now, we write a temporary bash script and execute that. ++ ++script = [[#!/bin/sh ++pidof -c -o %PPID -x glusterfsd &>/dev/null ++ ++if [ $? -eq 0 ]; then ++ pushd . > /dev/null 2>&1 ++ for volume in /var/lib/glusterd/vols/*; do cd $volume; ++ vol_type=`grep '^type=' info | awk -F'=' '{print $2}'` ++ volume_started=`grep '^status=' info | awk -F'=' '{print $2}'` ++ if [ $vol_type -eq 0 ] && [ $volume_started -eq 1 ] ; then ++ exit 1; ++ fi ++ done ++ ++ popd > /dev/null 2>&1 ++ exit 1; ++fi ++]] ++ ++-- rpm in RHEL5 does not have os.tmpname() ++-- io.tmpfile() can not be resolved to a filename to pass to bash :-/ ++tmpname = "/tmp/glusterfs-devel_pretrans_" .. os.date("%s") ++tmpfile = io.open(tmpname, "w") ++tmpfile:write(script) ++tmpfile:close() ++ok, how, val = os.execute("/bin/bash " .. tmpname) ++os.remove(tmpname) ++if not (ok == 0) then ++ error("Detected running glusterfs processes", ok) ++end ++ ++ ++ ++%pretrans fuse -p ++if not posix.access("/bin/bash", "x") then ++ -- initial installation, no shell, no running glusterfsd ++ return 0 ++end ++ ++-- TODO: move this completely to a lua script ++-- For now, we write a temporary bash script and execute that. ++ ++script = [[#!/bin/sh ++pidof -c -o %PPID -x glusterfsd &>/dev/null ++ ++if [ $? -eq 0 ]; then ++ pushd . > /dev/null 2>&1 ++ for volume in /var/lib/glusterd/vols/*; do cd $volume; ++ vol_type=`grep '^type=' info | awk -F'=' '{print $2}'` ++ volume_started=`grep '^status=' info | awk -F'=' '{print $2}'` ++ if [ $vol_type -eq 0 ] && [ $volume_started -eq 1 ] ; then ++ exit 1; ++ fi ++ done ++ ++ popd > /dev/null 2>&1 ++ exit 1; ++fi ++]] ++ ++-- rpm in RHEL5 does not have os.tmpname() ++-- io.tmpfile() can not be resolved to a filename to pass to bash :-/ ++tmpname = "/tmp/glusterfs-fuse_pretrans_" .. os.date("%s") ++tmpfile = io.open(tmpname, "w") ++tmpfile:write(script) ++tmpfile:close() ++ok, how, val = os.execute("/bin/bash " .. tmpname) ++os.remove(tmpname) ++if not (ok == 0) then ++ error("Detected running glusterfs processes", ok) ++end ++ ++ ++ ++%if 0%{?_can_georeplicate} ++%if ( 0%{!?_without_georeplication:1} ) ++%pretrans geo-replication -p ++if not posix.access("/bin/bash", "x") then ++ -- initial installation, no shell, no running glusterfsd ++ return 0 ++end ++ ++-- TODO: move this completely to a lua script ++-- For now, we write a temporary bash script and execute that. ++ ++script = [[#!/bin/sh ++pidof -c -o %PPID -x glusterfsd &>/dev/null ++ ++if [ $? -eq 0 ]; then ++ pushd . > /dev/null 2>&1 ++ for volume in /var/lib/glusterd/vols/*; do cd $volume; ++ vol_type=`grep '^type=' info | awk -F'=' '{print $2}'` ++ volume_started=`grep '^status=' info | awk -F'=' '{print $2}'` ++ if [ $vol_type -eq 0 ] && [ $volume_started -eq 1 ] ; then ++ exit 1; ++ fi ++ done ++ ++ popd > /dev/null 2>&1 ++ exit 1; ++fi ++]] ++ ++-- rpm in RHEL5 does not have os.tmpname() ++-- io.tmpfile() can not be resolved to a filename to pass to bash :-/ ++tmpname = "/tmp/glusterfs-geo-replication_pretrans_" .. os.date("%s") ++tmpfile = io.open(tmpname, "w") ++tmpfile:write(script) ++tmpfile:close() ++ok, how, val = os.execute("/bin/bash " .. tmpname) ++os.remove(tmpname) ++if not (ok == 0) then ++ error("Detected running glusterfs processes", ok) ++end ++%endif ++%endif ++ ++ ++ ++%pretrans libs -p ++if not posix.access("/bin/bash", "x") then ++ -- initial installation, no shell, no running glusterfsd ++ return 0 ++end ++ ++-- TODO: move this completely to a lua script ++-- For now, we write a temporary bash script and execute that. ++ ++script = [[#!/bin/sh ++pidof -c -o %PPID -x glusterfsd &>/dev/null ++ ++if [ $? -eq 0 ]; then ++ pushd . > /dev/null 2>&1 ++ for volume in /var/lib/glusterd/vols/*; do cd $volume; ++ vol_type=`grep '^type=' info | awk -F'=' '{print $2}'` ++ volume_started=`grep '^status=' info | awk -F'=' '{print $2}'` ++ if [ $vol_type -eq 0 ] && [ $volume_started -eq 1 ] ; then ++ exit 1; ++ fi ++ done ++ ++ popd > /dev/null 2>&1 ++ exit 1; ++fi ++]] ++ ++-- rpm in RHEL5 does not have os.tmpname() ++-- io.tmpfile() can not be resolved to a filename to pass to bash :-/ ++tmpname = "/tmp/glusterfs-libs_pretrans_" .. os.date("%s") ++tmpfile = io.open(tmpname, "w") ++tmpfile:write(script) ++tmpfile:close() ++ok, how, val = os.execute("/bin/bash " .. tmpname) ++os.remove(tmpname) ++if not (ok == 0) then ++ error("Detected running glusterfs processes", ok) ++end ++ ++ ++ ++%if ( 0%{!?_without_rdma:1} ) ++%pretrans rdma -p ++if not posix.access("/bin/bash", "x") then ++ -- initial installation, no shell, no running glusterfsd ++ return 0 ++end ++ ++-- TODO: move this completely to a lua script ++-- For now, we write a temporary bash script and execute that. ++ ++script = [[#!/bin/sh ++pidof -c -o %PPID -x glusterfsd &>/dev/null ++ ++if [ $? -eq 0 ]; then ++ pushd . > /dev/null 2>&1 ++ for volume in /var/lib/glusterd/vols/*; do cd $volume; ++ vol_type=`grep '^type=' info | awk -F'=' '{print $2}'` ++ volume_started=`grep '^status=' info | awk -F'=' '{print $2}'` ++ if [ $vol_type -eq 0 ] && [ $volume_started -eq 1 ] ; then ++ exit 1; ++ fi ++ done ++ ++ popd > /dev/null 2>&1 ++ exit 1; ++fi ++]] ++ ++-- rpm in RHEL5 does not have os.tmpname() ++-- io.tmpfile() can not be resolved to a filename to pass to bash :-/ ++tmpname = "/tmp/glusterfs-rdma_pretrans_" .. os.date("%s") ++tmpfile = io.open(tmpname, "w") ++tmpfile:write(script) ++tmpfile:close() ++ok, how, val = os.execute("/bin/bash " .. tmpname) ++os.remove(tmpname) ++if not (ok == 0) then ++ error("Detected running glusterfs processes", ok) ++end ++%endif ++ ++ ++ ++%if ( 0%{!?_without_ocf:1} ) ++%pretrans resource-agents -p ++if not posix.access("/bin/bash", "x") then ++ -- initial installation, no shell, no running glusterfsd ++ return 0 ++end ++ ++-- TODO: move this completely to a lua script ++-- For now, we write a temporary bash script and execute that. ++ ++script = [[#!/bin/sh ++pidof -c -o %PPID -x glusterfsd &>/dev/null ++ ++if [ $? -eq 0 ]; then ++ pushd . > /dev/null 2>&1 ++ for volume in /var/lib/glusterd/vols/*; do cd $volume; ++ vol_type=`grep '^type=' info | awk -F'=' '{print $2}'` ++ volume_started=`grep '^status=' info | awk -F'=' '{print $2}'` ++ if [ $vol_type -eq 0 ] && [ $volume_started -eq 1 ] ; then ++ exit 1; ++ fi ++ done ++ ++ popd > /dev/null 2>&1 ++ exit 1; ++fi ++]] ++ ++-- rpm in RHEL5 does not have os.tmpname() ++-- io.tmpfile() can not be resolved to a filename to pass to bash :-/ ++tmpname = "/tmp/glusterfs-resource-agents_pretrans_" .. os.date("%s") ++tmpfile = io.open(tmpname, "w") ++tmpfile:write(script) ++tmpfile:close() ++ok, how, val = os.execute("/bin/bash " .. tmpname) ++os.remove(tmpname) ++if not (ok == 0) then ++ error("Detected running glusterfs processes", ok) ++end ++%endif ++ ++ ++ ++%pretrans server -p ++if not posix.access("/bin/bash", "x") then ++ -- initial installation, no shell, no running glusterfsd ++ return 0 ++end ++ ++-- TODO: move this completely to a lua script ++-- For now, we write a temporary bash script and execute that. ++ ++script = [[#!/bin/sh ++pidof -c -o %PPID -x glusterfsd &>/dev/null ++ ++if [ $? -eq 0 ]; then ++ pushd . > /dev/null 2>&1 ++ for volume in /var/lib/glusterd/vols/*; do cd $volume; ++ vol_type=`grep '^type=' info | awk -F'=' '{print $2}'` ++ volume_started=`grep '^status=' info | awk -F'=' '{print $2}'` ++ if [ $vol_type -eq 0 ] && [ $volume_started -eq 1 ] ; then ++ exit 1; ++ fi ++ done ++ ++ popd > /dev/null 2>&1 ++ exit 1; ++fi ++]] ++ ++-- rpm in RHEL5 does not have os.tmpname() ++-- io.tmpfile() can not be resolved to a filename to pass to bash :-/ ++tmpname = "/tmp/glusterfs-server_pretrans_" .. os.date("%s") ++tmpfile = io.open(tmpname, "w") ++tmpfile:write(script) ++tmpfile:close() ++ok, how, val = os.execute("/bin/bash " .. tmpname) ++os.remove(tmpname) ++if not (ok == 0) then ++ error("Detected running glusterfs processes", ok) ++end ++%endif ++ + %changelog + * Wed Mar 6 2019 Kaleb S. KEITHLEY + - remove unneeded ldconfig in scriptlets +-- +1.8.3.1 + diff --git a/0008-secalert-remove-setuid-bit-for-fusermount-glusterfs.patch b/0008-secalert-remove-setuid-bit-for-fusermount-glusterfs.patch new file mode 100644 index 0000000..66a39d2 --- /dev/null +++ b/0008-secalert-remove-setuid-bit-for-fusermount-glusterfs.patch @@ -0,0 +1,35 @@ +From 0ab54c5b274f29fcdd4787325c7183a84e875bbc Mon Sep 17 00:00:00 2001 +From: "Bala.FA" +Date: Thu, 22 May 2014 08:37:27 +0530 +Subject: [PATCH 08/52] secalert: remove setuid bit for fusermount-glusterfs + +glusterfs-fuse: File /usr/bin/fusermount-glusterfs on x86_64 is setuid +root but is not on the setxid whitelist + +Label: DOWNSTREAM ONLY + +Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=989480 +Change-Id: Icf6e5db72ae15ccc60b02be6713fb6c4f4c8a15f +Signed-off-by: Bala.FA +Reviewed-on: https://code.engineering.redhat.com/gerrit/25453 +Signed-off-by: Bala.FA +Reviewed-on: https://code.engineering.redhat.com/gerrit/60135 +Tested-by: Milind Changire +--- + contrib/fuse-util/Makefile.am | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/contrib/fuse-util/Makefile.am b/contrib/fuse-util/Makefile.am +index abbc10e..a071c81 100644 +--- a/contrib/fuse-util/Makefile.am ++++ b/contrib/fuse-util/Makefile.am +@@ -9,6 +9,5 @@ AM_CFLAGS = -Wall $(GF_CFLAGS) + + install-exec-hook: + -chown root $(DESTDIR)$(bindir)/fusermount-glusterfs +- chmod u+s $(DESTDIR)$(bindir)/fusermount-glusterfs + + CLEANFILES = +-- +1.8.3.1 + diff --git a/0009-build-introduce-security-hardening-flags-in-gluster.patch b/0009-build-introduce-security-hardening-flags-in-gluster.patch new file mode 100644 index 0000000..7cfe937 --- /dev/null +++ b/0009-build-introduce-security-hardening-flags-in-gluster.patch @@ -0,0 +1,57 @@ +From 2adb5d540e9344149ae2591811ad34928775e6fd Mon Sep 17 00:00:00 2001 +From: Atin Mukherjee +Date: Wed, 3 Jun 2015 11:09:21 +0530 +Subject: [PATCH 09/52] build: introduce security hardening flags in gluster + +This patch introduces two of the security hardening compiler flags RELRO & PIE +in gluster codebase. Using _hardened_build as 1 doesn't guarantee the existance +of these flags in the compilation as different versions of RHEL have different +redhat-rpm-config macro. So the idea is to export these flags at spec file +level. + +Label: DOWNSTREAM ONLY + +Change-Id: I0a1a56d0a8f54f110d306ba5e55e39b1b073dc84 +Signed-off-by: Atin Mukherjee +Reviewed-on: https://code.engineering.redhat.com/gerrit/49780 +Reviewed-by: Balamurugan Arumugam +Tested-by: Balamurugan Arumugam +Reviewed-on: https://code.engineering.redhat.com/gerrit/60137 +Tested-by: Milind Changire +--- + glusterfs.spec.in | 19 +++++++++++++++++++ + 1 file changed, 19 insertions(+) + +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index eb04491..8a31a98 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -736,6 +736,25 @@ done + + %build + ++# In RHEL7 few hardening flags are available by default, however the RELRO ++# default behaviour is partial, convert to full ++%if ( 0%{?rhel} && 0%{?rhel} >= 7 ) ++LDFLAGS="$RPM_LD_FLAGS -Wl,-z,relro,-z,now" ++export LDFLAGS ++%else ++%if ( 0%{?rhel} && 0%{?rhel} == 6 ) ++CFLAGS="$RPM_OPT_FLAGS -fPIE -DPIE" ++LDFLAGS="$RPM_LD_FLAGS -pie -Wl,-z,relro,-z,now" ++%else ++#It appears that with gcc-4.1.2 in RHEL5 there is an issue using both -fPIC and ++ # -fPIE that makes -z relro not work; -fPIE seems to undo what -fPIC does ++CFLAGS="$CFLAGS $RPM_OPT_FLAGS" ++LDFLAGS="$RPM_LD_FLAGS -Wl,-z,relro,-z,now" ++%endif ++export CFLAGS ++export LDFLAGS ++%endif ++ + ./autogen.sh && %configure \ + %{?_with_asan} \ + %{?_with_cmocka} \ +-- +1.8.3.1 + diff --git a/0010-spec-fix-add-pre-transaction-scripts-for-geo-rep-and.patch b/0010-spec-fix-add-pre-transaction-scripts-for-geo-rep-and.patch new file mode 100644 index 0000000..9226936 --- /dev/null +++ b/0010-spec-fix-add-pre-transaction-scripts-for-geo-rep-and.patch @@ -0,0 +1,100 @@ +From bf5906cbc9bf986c7495db792d098001e28c47e3 Mon Sep 17 00:00:00 2001 +From: Niels de Vos +Date: Wed, 22 Apr 2015 15:39:59 +0200 +Subject: [PATCH 10/52] spec: fix/add pre-transaction scripts for geo-rep and + cli packages + +The cli subpackage never had a %pretrans script, this has been added +now. + +The %pretrans script for ge-repliaction was never included in the RPM +package because it was disable by a undefined macro (_can_georeplicate). +This macro is not used/set anywhere else and _without_georeplication +should take care of it anyway. + +Note: This is a Red Hat Gluster Storage specific patch. Upstream + packaging guidelines do not allow these kind of 'features'. + +Label: DOWNSTREAM ONLY + +Change-Id: I16aab5bba72f1ed178f3bcac47f9d8ef767cfcef +Signed-off-by: Niels de Vos +Signed-off-by: Bala.FA +Reviewed-on: https://code.engineering.redhat.com/gerrit/50491 +Reviewed-on: https://code.engineering.redhat.com/gerrit/60138 +Tested-by: Milind Changire +--- + glusterfs.spec.in | 43 +++++++++++++++++++++++++++++++++++++++++-- + 1 file changed, 41 insertions(+), 2 deletions(-) + +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index 8a31a98..b70dbfc 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -1626,6 +1626,47 @@ end + + + ++%pretrans cli -p ++if not posix.access("/bin/bash", "x") then ++ -- initial installation, no shell, no running glusterfsd ++ return 0 ++end ++ ++-- TODO: move this completely to a lua script ++-- For now, we write a temporary bash script and execute that. ++ ++script = [[#!/bin/sh ++pidof -c -o %PPID -x glusterfsd &>/dev/null ++ ++if [ $? -eq 0 ]; then ++ pushd . > /dev/null 2>&1 ++ for volume in /var/lib/glusterd/vols/*; do cd $volume; ++ vol_type=`grep '^type=' info | awk -F'=' '{print $2}'` ++ volume_started=`grep '^status=' info | awk -F'=' '{print $2}'` ++ if [ $vol_type -eq 0 ] && [ $volume_started -eq 1 ] ; then ++ exit 1; ++ fi ++ done ++ ++ popd > /dev/null 2>&1 ++ exit 1; ++fi ++]] ++ ++-- rpm in RHEL5 does not have os.tmpname() ++-- io.tmpfile() can not be resolved to a filename to pass to bash :-/ ++tmpname = "/tmp/glusterfs-cli_pretrans_" .. os.date("%s") ++tmpfile = io.open(tmpname, "w") ++tmpfile:write(script) ++tmpfile:close() ++ok, how, val = os.execute("/bin/bash " .. tmpname) ++os.remove(tmpname) ++if not (ok == 0) then ++ error("Detected running glusterfs processes", ok) ++end ++ ++ ++ + %pretrans devel -p + if not posix.access("/bin/bash", "x") then + -- initial installation, no shell, no running glusterfsd +@@ -1708,7 +1749,6 @@ end + + + +-%if 0%{?_can_georeplicate} + %if ( 0%{!?_without_georeplication:1} ) + %pretrans geo-replication -p + if not posix.access("/bin/bash", "x") then +@@ -1749,7 +1789,6 @@ if not (ok == 0) then + error("Detected running glusterfs processes", ok) + end + %endif +-%endif + + + +-- +1.8.3.1 + diff --git a/0011-rpm-glusterfs-devel-for-client-builds-should-not-dep.patch b/0011-rpm-glusterfs-devel-for-client-builds-should-not-dep.patch new file mode 100644 index 0000000..cc79317 --- /dev/null +++ b/0011-rpm-glusterfs-devel-for-client-builds-should-not-dep.patch @@ -0,0 +1,138 @@ +From 40eb62a8872ce061416e899fb6c0784b6253ab16 Mon Sep 17 00:00:00 2001 +From: Niels de Vos +Date: Fri, 7 Dec 2018 14:05:21 +0530 +Subject: [PATCH 11/52] rpm: glusterfs-devel for client-builds should not + depend on -server + +glusterfs-devel for client-side packages should *not* include the +libgfdb.so symlink and libgfdb.pc file or any of the libchangelog +ones. + +Label: DOWNSTREAM ONLY + +Change-Id: Ifb4a9cf48841e5af5dd0a98b6de51e2ee469fc56 +Signed-off-by: Niels de Vos +Reviewed-on: https://code.engineering.redhat.com/gerrit/51019 +Reviewed-by: Balamurugan Arumugam +Tested-by: Balamurugan Arumugam +Reviewed-on: https://code.engineering.redhat.com/gerrit/60139 +Tested-by: Milind Changire +--- + glusterfs.spec.in | 86 +++++++++++++++++++++++++++++++++++++++---------------- + 1 file changed, 62 insertions(+), 24 deletions(-) + +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index b70dbfc..1c631db 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -450,30 +450,6 @@ is in user space and easily manageable. + This package provides support to FUSE based clients and inlcudes the + glusterfs(d) binary. + +-%if ( 0%{!?_without_server:1} ) +-%package ganesha +-Summary: NFS-Ganesha configuration +-Group: Applications/File +- +-Requires: %{name}-server%{?_isa} = %{version}-%{release} +-Requires: nfs-ganesha-gluster, pcs, dbus +-%if ( 0%{?rhel} && 0%{?rhel} == 6 ) +-Requires: cman, pacemaker, corosync +-%endif +- +-%description ganesha +-GlusterFS is a distributed file-system capable of scaling to several +-petabytes. It aggregates various storage bricks over Infiniband RDMA +-or TCP/IP interconnect into one large parallel network file +-system. GlusterFS is one of the most sophisticated file systems in +-terms of features and extensibility. It borrows a powerful concept +-called Translators from GNU Hurd kernel. Much of the code in GlusterFS +-is in user space and easily manageable. +- +-This package provides the configuration and related files for using +-NFS-Ganesha as the NFS server using GlusterFS +-%endif +- + %if ( 0%{!?_without_georeplication:1} ) + %package geo-replication + Summary: GlusterFS Geo-replication +@@ -1157,6 +1133,62 @@ exit 0 + %exclude %{_datadir}/glusterfs/run-tests.sh + %exclude %{_datadir}/glusterfs/tests + %endif ++%if 0%{?_without_server:1} ++%exclude %{_sysconfdir}/glusterfs/gluster-rsyslog-5.8.conf ++%exclude %{_sysconfdir}/glusterfs/gluster-rsyslog-7.2.conf ++%exclude %{_sysconfdir}/glusterfs/glusterd.vol ++%exclude %{_sysconfdir}/glusterfs/glusterfs-georep-logrotate ++%exclude %{_sysconfdir}/glusterfs/glusterfs-logrotate ++%exclude %{_sysconfdir}/glusterfs/group-db-workload ++%exclude %{_sysconfdir}/glusterfs/group-distributed-virt ++%exclude %{_sysconfdir}/glusterfs/group-gluster-block ++%exclude %{_sysconfdir}/glusterfs/group-metadata-cache ++%exclude %{_sysconfdir}/glusterfs/group-nl-cache ++%exclude %{_sysconfdir}/glusterfs/group-virt.example ++%exclude %{_sysconfdir}/glusterfs/logger.conf.example ++%exclude %{_sysconfdir}/rsyslog.d/gluster.conf.example ++%exclude %{_prefix}/bin/glusterfind ++%exclude %{_prefix}/lib/firewalld/services/glusterfs.xml ++%exclude %{_prefix}/lib/systemd/system/glusterd.service ++%exclude %{_prefix}/lib/systemd/system/glusterfssharedstorage.service ++%exclude %{_prefix}/lib/tmpfiles.d/gluster.conf ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/arbiter.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/bit-rot.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/bitrot-stub.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/index.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/leases.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/locks.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/marker.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/posix-locks.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/quota.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/quotad.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/sdfs.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/selinux.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/snapview-server.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/thin-arbiter.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/trash.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/upcall.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/mgmt/glusterd.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/performance/decompounder.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/protocol/server.so ++%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/storage/posix.so ++%exclude %{_libexecdir}/glusterfs/* ++%exclude %{_sbindir}/conf.py ++%exclude %{_sbindir}/gcron.py ++%exclude %{_sbindir}/gf_attach ++%exclude %{_sbindir}/gfind_missing_files ++%exclude %{_sbindir}/glfsheal ++%exclude %{_sbindir}/gluster ++%exclude %{_sbindir}/gluster-setgfid2path ++%exclude %{_sbindir}/glusterd ++%exclude %{_sbindir}/snap_scheduler.py ++%exclude %{_datadir}/glusterfs/scripts/control-cpu-load.sh ++%exclude %{_datadir}/glusterfs/scripts/control-mem.sh ++%exclude %{_datadir}/glusterfs/scripts/post-upgrade-script-for-quota.sh ++%exclude %{_datadir}/glusterfs/scripts/pre-upgrade-script-for-quota.sh ++%exclude %{_datadir}/glusterfs/scripts/stop-all-gluster-processes.sh ++%exclude %{_sharedstatedir}/glusterd/* ++%endif + + %files api + %exclude %{_libdir}/*.so +@@ -1190,7 +1222,13 @@ exit 0 + %exclude %{_includedir}/glusterfs/api + %exclude %{_libdir}/libgfapi.so + %{_libdir}/*.so ++%if ( 0%{?_without_server:1} ) ++%exclude %{_libdir}/pkgconfig/libgfchangelog.pc ++%exclude %{_libdir}/libgfchangelog.so ++%else + %{_libdir}/pkgconfig/libgfchangelog.pc ++%{_libdir}/libgfchangelog.so ++%endif + + %files client-xlators + %dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator +-- +1.8.3.1 + diff --git a/0012-build-add-pretrans-check.patch b/0012-build-add-pretrans-check.patch new file mode 100644 index 0000000..efac62f --- /dev/null +++ b/0012-build-add-pretrans-check.patch @@ -0,0 +1,73 @@ +From f054086daf4549a6227196fe37a57a7e49aa5849 Mon Sep 17 00:00:00 2001 +From: "Bala.FA" +Date: Fri, 7 Dec 2018 14:13:40 +0530 +Subject: [PATCH 12/52] build: add pretrans check + +This patch adds pretrans check for client-xlators + +NOTE: ganesha and python-gluster sub-packages are now obsolete + +Label: DOWNSTREAM ONLY + +Change-Id: I454016319832c11902c0ca79a79fbbcf8ac0a121 +Signed-off-by: Bala.FA +Reviewed-on: https://code.engineering.redhat.com/gerrit/50967 +Reviewed-on: https://code.engineering.redhat.com/gerrit/60140 +Tested-by: Milind Changire +--- + glusterfs.spec.in | 39 +++++++++++++++++++++++++++++++++++++++ + 1 file changed, 39 insertions(+) + +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index 1c631db..a1ff6e0 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -1704,6 +1704,45 @@ if not (ok == 0) then + end + + ++%pretrans client-xlators -p ++if not posix.access("/bin/bash", "x") then ++ -- initial installation, no shell, no running glusterfsd ++ return 0 ++end ++ ++-- TODO: move this completely to a lua script ++-- For now, we write a temporary bash script and execute that. ++ ++script = [[#!/bin/sh ++pidof -c -o %PPID -x glusterfsd &>/dev/null ++ ++if [ $? -eq 0 ]; then ++ pushd . > /dev/null 2>&1 ++ for volume in /var/lib/glusterd/vols/*; do cd $volume; ++ vol_type=`grep '^type=' info | awk -F'=' '{print $2}'` ++ volume_started=`grep '^status=' info | awk -F'=' '{print $2}'` ++ if [ $vol_type -eq 0 ] && [ $volume_started -eq 1 ] ; then ++ exit 1; ++ fi ++ done ++ ++ popd > /dev/null 2>&1 ++ exit 1; ++fi ++]] ++ ++-- rpm in RHEL5 does not have os.tmpname() ++-- io.tmpfile() can not be resolved to a filename to pass to bash :-/ ++tmpname = "/tmp/glusterfs-client-xlators_pretrans_" .. os.date("%s") ++tmpfile = io.open(tmpname, "w") ++tmpfile:write(script) ++tmpfile:close() ++ok, how, val = os.execute("/bin/bash " .. tmpname) ++os.remove(tmpname) ++if not (ok == 0) then ++ error("Detected running glusterfs processes", ok) ++end ++ + + %pretrans devel -p + if not posix.access("/bin/bash", "x") then +-- +1.8.3.1 + diff --git a/0013-glusterd-fix-info-file-checksum-mismatch-during-upgr.patch b/0013-glusterd-fix-info-file-checksum-mismatch-during-upgr.patch new file mode 100644 index 0000000..5873f3e --- /dev/null +++ b/0013-glusterd-fix-info-file-checksum-mismatch-during-upgr.patch @@ -0,0 +1,50 @@ +From 39932e6bbc8de25813387bb1394cc7942b79ef46 Mon Sep 17 00:00:00 2001 +From: anand +Date: Wed, 18 Nov 2015 16:13:46 +0530 +Subject: [PATCH 13/52] glusterd: fix info file checksum mismatch during + upgrade + +peers are moving rejected state when upgrading from RHS2.1 to RHGS3.1.2 +due to checksum mismatch. + +Label: DOWNSTREAM ONLY + +Change-Id: Ifea6b7dfe8477c7f17eefc5ca87ced58aaa21c84 +Signed-off-by: anand +Reviewed-on: https://code.engineering.redhat.com/gerrit/61774 +Reviewed-by: Atin Mukherjee +Tested-by: Atin Mukherjee +--- + xlators/mgmt/glusterd/src/glusterd-store.c | 16 ++++++++++++---- + 1 file changed, 12 insertions(+), 4 deletions(-) + +diff --git a/xlators/mgmt/glusterd/src/glusterd-store.c b/xlators/mgmt/glusterd/src/glusterd-store.c +index 51ca3d1..fb52957 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-store.c ++++ b/xlators/mgmt/glusterd/src/glusterd-store.c +@@ -1009,10 +1009,18 @@ glusterd_volume_exclude_options_write(int fd, glusterd_volinfo_t *volinfo) + goto out; + } + +- snprintf(buf, sizeof(buf), "%d", volinfo->op_version); +- ret = gf_store_save_value(fd, GLUSTERD_STORE_KEY_VOL_OP_VERSION, buf); +- if (ret) +- goto out; ++ if (conf->op_version >= GD_OP_VERSION_RHS_3_0) { ++ snprintf (buf, sizeof (buf), "%d", volinfo->op_version); ++ ret = gf_store_save_value (fd, GLUSTERD_STORE_KEY_VOL_OP_VERSION, buf); ++ if (ret) ++ goto out; ++ ++ snprintf (buf, sizeof (buf), "%d", volinfo->client_op_version); ++ ret = gf_store_save_value (fd, GLUSTERD_STORE_KEY_VOL_CLIENT_OP_VERSION, ++ buf); ++ if (ret) ++ goto out; ++ } + + snprintf(buf, sizeof(buf), "%d", volinfo->client_op_version); + ret = gf_store_save_value(fd, GLUSTERD_STORE_KEY_VOL_CLIENT_OP_VERSION, +-- +1.8.3.1 + diff --git a/0014-build-spec-file-conflict-resolution.patch b/0014-build-spec-file-conflict-resolution.patch new file mode 100644 index 0000000..fb8aeba --- /dev/null +++ b/0014-build-spec-file-conflict-resolution.patch @@ -0,0 +1,72 @@ +From f76d2370160c50a1f59d08a03a444254c289da60 Mon Sep 17 00:00:00 2001 +From: Milind Changire +Date: Fri, 7 Dec 2018 16:18:07 +0530 +Subject: [PATCH 14/52] build: spec file conflict resolution + +Missed conflict resolution for removing references to +gluster.conf.example as mentioned in patch titled: +packaging: gratuitous dependencies on rsyslog-mm{count,jsonparse} +by Kaleb + +References to hook scripts S31ganesha-start.sh and +S31ganesha-reset.sh got lost in the downstream only +patch conflict resolution. + +Commented blanket reference to %{_sharedsstatedir}/glusterd/* +in section %files server to avoid rpmbuild warning related to +multiple references to hook scripts and other files under +/var/lib/glusterd. + +Label: DOWNSTREAM ONLY + +Change-Id: I9d409f1595ab985ed9f79d9d4f4298877609ba17 +Signed-off-by: Milind Changire +Reviewed-on: https://code.engineering.redhat.com/gerrit/70535 +Reviewed-by: Rajesh Joseph +Tested-by: Rajesh Joseph +--- + glusterfs.spec.in | 21 +-------------------- + 1 file changed, 1 insertion(+), 20 deletions(-) + +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index a1ff6e0..8c57f57 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -96,9 +96,7 @@ + + # disable server components forcefully as rhel <= 6 + %if ( 0%{?rhel} ) +-%if ( "%{?dist}" == ".el6rhs" ) || ( "%{?dist}" == ".el7rhs" ) || ( "%{?dist}" == ".el7rhgs" ) +-%global _without_server %{nil} +-%else ++%if (!(( "%{?dist}" == ".el6rhs" ) || ( "%{?dist}" == ".el7rhs" ) || ( "%{?dist}" == ".el7rhgs" ))) + %global _without_server --without-server + %endif + %endif +@@ -836,23 +834,6 @@ install -D -p -m 0644 extras/glusterfs-georep-logrotate \ + %{buildroot}%{_sysconfdir}/logrotate.d/glusterfs-georep + %endif + +-%if ( 0%{!?_without_syslog:1} ) +-%if ( 0%{?fedora} ) || ( 0%{?rhel} && 0%{?rhel} > 6 ) +-install -D -p -m 0644 extras/gluster-rsyslog-7.2.conf \ +- %{buildroot}%{_sysconfdir}/rsyslog.d/gluster.conf.example +-%endif +- +-%if ( 0%{?rhel} && 0%{?rhel} == 6 ) +-install -D -p -m 0644 extras/gluster-rsyslog-5.8.conf \ +- %{buildroot}%{_sysconfdir}/rsyslog.d/gluster.conf.example +-%endif +- +-%if ( 0%{?fedora} ) || ( 0%{?rhel} && 0%{?rhel} >= 6 ) +-install -D -p -m 0644 extras/logger.conf.example \ +- %{buildroot}%{_sysconfdir}/glusterfs/logger.conf.example +-%endif +-%endif +- + %if ( 0%{!?_without_server:1} ) + touch %{buildroot}%{_sharedstatedir}/glusterd/glusterd.info + touch %{buildroot}%{_sharedstatedir}/glusterd/options +-- +1.8.3.1 + diff --git a/0015-build-randomize-temp-file-names-in-pretrans-scriptle.patch b/0015-build-randomize-temp-file-names-in-pretrans-scriptle.patch new file mode 100644 index 0000000..b82e19b --- /dev/null +++ b/0015-build-randomize-temp-file-names-in-pretrans-scriptle.patch @@ -0,0 +1,198 @@ +From 3d0e09400dc21dbb5f76fd9ca4bfce3edad0d626 Mon Sep 17 00:00:00 2001 +From: Milind Changire +Date: Fri, 14 Oct 2016 12:53:27 +0530 +Subject: [PATCH 15/52] build: randomize temp file names in pretrans scriptlets + +Security issue CVE-2015-1795 mentions about possibility of file name +spoof attack for the %pretrans server scriptlet. +Since %pretrans scriptlets are executed only for server builds, we can +use os.tmpname() to randomize temporary file names for all %pretrans +scriptlets using this mechanism. + +Label: DOWNSTREAM ONLY + +Change-Id: Ic82433897432794b6d311d836355aa4bad886369 +Signed-off-by: Milind Changire +Reviewed-on: https://code.engineering.redhat.com/gerrit/86187 +Reviewed-by: Siddharth Sharma +Reviewed-by: Niels de Vos +Reviewed-by: Atin Mukherjee +--- + glusterfs.spec.in | 84 +++++++++++++++++++++++++++++++------------------------ + 1 file changed, 48 insertions(+), 36 deletions(-) + +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index 8c57f57..3a98822 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -1549,9 +1549,10 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- rpm in RHEL5 does not have os.tmpname() +--- io.tmpfile() can not be resolved to a filename to pass to bash :-/ +-tmpname = "/tmp/glusterfs_pretrans_" .. os.date("%s") ++-- Since we run pretrans scripts only for RPMs built for a server build, ++-- we can now use os.tmpname() since it is available on RHEL6 and later ++-- platforms which are server platforms. ++tmpname = os.tmpname() + tmpfile = io.open(tmpname, "w") + tmpfile:write(script) + tmpfile:close() +@@ -1590,9 +1591,10 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- rpm in RHEL5 does not have os.tmpname() +--- io.tmpfile() can not be resolved to a filename to pass to bash :-/ +-tmpname = "/tmp/glusterfs-api_pretrans_" .. os.date("%s") ++-- Since we run pretrans scripts only for RPMs built for a server build, ++-- we can now use os.tmpname() since it is available on RHEL6 and later ++-- platforms which are server platforms. ++tmpname = os.tmpname() + tmpfile = io.open(tmpname, "w") + tmpfile:write(script) + tmpfile:close() +@@ -1631,9 +1633,10 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- rpm in RHEL5 does not have os.tmpname() +--- io.tmpfile() can not be resolved to a filename to pass to bash :-/ +-tmpname = "/tmp/glusterfs-api-devel_pretrans_" .. os.date("%s") ++-- Since we run pretrans scripts only for RPMs built for a server build, ++-- we can now use os.tmpname() since it is available on RHEL6 and later ++-- platforms which are server platforms. ++tmpname = os.tmpname() + tmpfile = io.open(tmpname, "w") + tmpfile:write(script) + tmpfile:close() +@@ -1672,9 +1675,10 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- rpm in RHEL5 does not have os.tmpname() +--- io.tmpfile() can not be resolved to a filename to pass to bash :-/ +-tmpname = "/tmp/glusterfs-cli_pretrans_" .. os.date("%s") ++-- Since we run pretrans scripts only for RPMs built for a server build, ++-- we can now use os.tmpname() since it is available on RHEL6 and later ++-- platforms which are server platforms. ++tmpname = os.tmpname() + tmpfile = io.open(tmpname, "w") + tmpfile:write(script) + tmpfile:close() +@@ -1712,9 +1716,10 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- rpm in RHEL5 does not have os.tmpname() +--- io.tmpfile() can not be resolved to a filename to pass to bash :-/ +-tmpname = "/tmp/glusterfs-client-xlators_pretrans_" .. os.date("%s") ++-- Since we run pretrans scripts only for RPMs built for a server build, ++-- we can now use os.tmpname() since it is available on RHEL6 and later ++-- platforms which are server platforms. ++tmpname = os.tmpname() + tmpfile = io.open(tmpname, "w") + tmpfile:write(script) + tmpfile:close() +@@ -1752,9 +1757,10 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- rpm in RHEL5 does not have os.tmpname() +--- io.tmpfile() can not be resolved to a filename to pass to bash :-/ +-tmpname = "/tmp/glusterfs-devel_pretrans_" .. os.date("%s") ++-- Since we run pretrans scripts only for RPMs built for a server build, ++-- we can now use os.tmpname() since it is available on RHEL6 and later ++-- platforms which are server platforms. ++tmpname = os.tmpname() + tmpfile = io.open(tmpname, "w") + tmpfile:write(script) + tmpfile:close() +@@ -1793,9 +1799,10 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- rpm in RHEL5 does not have os.tmpname() +--- io.tmpfile() can not be resolved to a filename to pass to bash :-/ +-tmpname = "/tmp/glusterfs-fuse_pretrans_" .. os.date("%s") ++-- Since we run pretrans scripts only for RPMs built for a server build, ++-- we can now use os.tmpname() since it is available on RHEL6 and later ++-- platforms which are server platforms. ++tmpname = os.tmpname() + tmpfile = io.open(tmpname, "w") + tmpfile:write(script) + tmpfile:close() +@@ -1835,9 +1842,10 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- rpm in RHEL5 does not have os.tmpname() +--- io.tmpfile() can not be resolved to a filename to pass to bash :-/ +-tmpname = "/tmp/glusterfs-geo-replication_pretrans_" .. os.date("%s") ++-- Since we run pretrans scripts only for RPMs built for a server build, ++-- we can now use os.tmpname() since it is available on RHEL6 and later ++-- platforms which are server platforms. ++tmpname = os.tmpname() + tmpfile = io.open(tmpname, "w") + tmpfile:write(script) + tmpfile:close() +@@ -1877,9 +1885,10 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- rpm in RHEL5 does not have os.tmpname() +--- io.tmpfile() can not be resolved to a filename to pass to bash :-/ +-tmpname = "/tmp/glusterfs-libs_pretrans_" .. os.date("%s") ++-- Since we run pretrans scripts only for RPMs built for a server build, ++-- we can now use os.tmpname() since it is available on RHEL6 and later ++-- platforms which are server platforms. ++tmpname = os.tmpname() + tmpfile = io.open(tmpname, "w") + tmpfile:write(script) + tmpfile:close() +@@ -1919,9 +1928,10 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- rpm in RHEL5 does not have os.tmpname() +--- io.tmpfile() can not be resolved to a filename to pass to bash :-/ +-tmpname = "/tmp/glusterfs-rdma_pretrans_" .. os.date("%s") ++-- Since we run pretrans scripts only for RPMs built for a server build, ++-- we can now use os.tmpname() since it is available on RHEL6 and later ++-- platforms which are server platforms. ++tmpname = os.tmpname() + tmpfile = io.open(tmpname, "w") + tmpfile:write(script) + tmpfile:close() +@@ -1962,9 +1972,10 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- rpm in RHEL5 does not have os.tmpname() +--- io.tmpfile() can not be resolved to a filename to pass to bash :-/ +-tmpname = "/tmp/glusterfs-resource-agents_pretrans_" .. os.date("%s") ++-- Since we run pretrans scripts only for RPMs built for a server build, ++-- we can now use os.tmpname() since it is available on RHEL6 and later ++-- platforms which are server platforms. ++tmpname = os.tmpname() + tmpfile = io.open(tmpname, "w") + tmpfile:write(script) + tmpfile:close() +@@ -2004,9 +2015,10 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- rpm in RHEL5 does not have os.tmpname() +--- io.tmpfile() can not be resolved to a filename to pass to bash :-/ +-tmpname = "/tmp/glusterfs-server_pretrans_" .. os.date("%s") ++-- Since we run pretrans scripts only for RPMs built for a server build, ++-- we can now use os.tmpname() since it is available on RHEL6 and later ++-- platforms which are server platforms. ++tmpname = os.tmpname() + tmpfile = io.open(tmpname, "w") + tmpfile:write(script) + tmpfile:close() +-- +1.8.3.1 + diff --git a/0016-glusterd-parallel-readdir-Change-the-op-version-of-p.patch b/0016-glusterd-parallel-readdir-Change-the-op-version-of-p.patch new file mode 100644 index 0000000..402b835 --- /dev/null +++ b/0016-glusterd-parallel-readdir-Change-the-op-version-of-p.patch @@ -0,0 +1,42 @@ +From c283f15ac9bfb1c98ce95ed0000ebed81cd3b318 Mon Sep 17 00:00:00 2001 +From: Poornima G +Date: Wed, 26 Apr 2017 14:07:58 +0530 +Subject: [PATCH 16/52] glusterd, parallel-readdir: Change the op-version of + parallel-readdir to 31100 + +Issue: Downstream 3.2 was released with op-version 31001, parallel-readdir +feature in upstream was released in 3.10 and hence with op-version 31000. +With this, parallel-readdir will be allowed in 3.2 cluster/clients as well. +But 3.2 didn't have parallel-readdir feature backported. + +Fix: +Increase the op-version of parallel-readdir feature only in downstream +to 31100(3.3 highest op-version) + +Label: DOWNSTREAM ONLY + +Change-Id: I2640520985627f3a1cb4fb96e28350f8bb9b146c +Signed-off-by: Poornima G +Reviewed-on: https://code.engineering.redhat.com/gerrit/104403 +Reviewed-by: Atin Mukherjee +Tested-by: Atin Mukherjee +--- + xlators/mgmt/glusterd/src/glusterd-volume-set.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/xlators/mgmt/glusterd/src/glusterd-volume-set.c b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +index d07fc10..a31ecda 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-volume-set.c ++++ b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +@@ -2718,7 +2718,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .option = "parallel-readdir", + .value = "off", + .type = DOC, +- .op_version = GD_OP_VERSION_3_10_0, ++ .op_version = GD_OP_VERSION_3_11_0, + .validate_fn = validate_parallel_readdir, + .description = "If this option is enabled, the readdir operation " + "is performed in parallel on all the bricks, thus " +-- +1.8.3.1 + diff --git a/0017-glusterd-Revert-op-version-for-cluster.max-brick-per.patch b/0017-glusterd-Revert-op-version-for-cluster.max-brick-per.patch new file mode 100644 index 0000000..f536c9c --- /dev/null +++ b/0017-glusterd-Revert-op-version-for-cluster.max-brick-per.patch @@ -0,0 +1,37 @@ +From 5d3315a53611f23a69f88bc8266448e258e2e10f Mon Sep 17 00:00:00 2001 +From: Samikshan Bairagya +Date: Mon, 10 Jul 2017 11:54:52 +0530 +Subject: [PATCH 17/52] glusterd: Revert op-version for + "cluster.max-brick-per-process" + +The op-version for the "cluster.max-brick-per-process" option was +set to 3.12.0 in the upstream patch and was backported here: +https://code.engineering.redhat.com/gerrit/#/c/111799. This commit +reverts the op-version for this option to 3.11.1 instead. + +Label: DOWNSTREAM ONLY + +Change-Id: I23639cef43d41915eea0394d019b1e0796a99d7b +Signed-off-by: Samikshan Bairagya +Reviewed-on: https://code.engineering.redhat.com/gerrit/111804 +Reviewed-by: Atin Mukherjee +--- + xlators/mgmt/glusterd/src/glusterd-volume-set.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/xlators/mgmt/glusterd/src/glusterd-volume-set.c b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +index a31ecda..9a6fe9f 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-volume-set.c ++++ b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +@@ -2794,7 +2794,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { + {.key = GLUSTERD_BRICKMUX_LIMIT_KEY, + .voltype = "mgmt/glusterd", + .value = GLUSTERD_BRICKMUX_LIMIT_DFLT_VALUE, +- .op_version = GD_OP_VERSION_3_12_0, ++ .op_version = GD_OP_VERSION_3_11_1, + .validate_fn = validate_mux_limit, + .type = GLOBAL_DOC, + .description = "This option can be used to limit the number of brick " +-- +1.8.3.1 + diff --git a/0018-cli-Add-message-for-user-before-modifying-brick-mult.patch b/0018-cli-Add-message-for-user-before-modifying-brick-mult.patch new file mode 100644 index 0000000..ab3530e --- /dev/null +++ b/0018-cli-Add-message-for-user-before-modifying-brick-mult.patch @@ -0,0 +1,56 @@ +From 539626a64e5b8cfe05d42f5398073e8a57644073 Mon Sep 17 00:00:00 2001 +From: Samikshan Bairagya +Date: Wed, 9 Aug 2017 14:32:59 +0530 +Subject: [PATCH 18/52] cli: Add message for user before modifying + brick-multiplex option + +Users should ne notified that brick-multiplexing feature is +supported only for container workloads (CNS/CRS). It should also be +made known to users that it is advisable to either have all volumes +in stopped state or have no bricks running before modifying the +"brick-multiplex" option. This commit makes sure these messages +are displayed to the user before brick-multiplexing is enabled or +disabled. + +Label: DOWNSTREAM ONLY + +Change-Id: Ic40294b26c691ea03185c4d1fce840ef23f95718 +Signed-off-by: Samikshan Bairagya +Reviewed-on: https://code.engineering.redhat.com/gerrit/114793 +Reviewed-by: Atin Mukherjee +--- + cli/src/cli-cmd-parser.c | 18 ++++++++++++++++++ + 1 file changed, 18 insertions(+) + +diff --git a/cli/src/cli-cmd-parser.c b/cli/src/cli-cmd-parser.c +index d9913f6..f148c59 100644 +--- a/cli/src/cli-cmd-parser.c ++++ b/cli/src/cli-cmd-parser.c +@@ -1698,6 +1698,24 @@ cli_cmd_volume_set_parse(struct cli_state *state, const char **words, + } + } + ++ if ((strcmp (key, "cluster.brick-multiplex") == 0)) { ++ question = "Brick-multiplexing is supported only for " ++ "container workloads (CNS/CRS). Also it is " ++ "advised to make sure that either all " ++ "volumes are in stopped state or no bricks " ++ "are running before this option is modified." ++ "Do you still want to continue?"; ++ ++ answer = cli_cmd_get_confirmation (state, question); ++ if (GF_ANSWER_NO == answer) { ++ gf_log ("cli", GF_LOG_ERROR, "Operation " ++ "cancelled, exiting"); ++ *op_errstr = gf_strdup ("Aborted by user."); ++ ret = -1; ++ goto out; ++ } ++ } ++ + ret = dict_set_int32(dict, "count", wordcount - 3); + + if (ret) +-- +1.8.3.1 + diff --git a/0019-build-launch-glusterd-upgrade-after-all-new-bits-are.patch b/0019-build-launch-glusterd-upgrade-after-all-new-bits-are.patch new file mode 100644 index 0000000..e1287c9 --- /dev/null +++ b/0019-build-launch-glusterd-upgrade-after-all-new-bits-are.patch @@ -0,0 +1,99 @@ +From 8a3035bf612943694a3cd1c6a857bd009e84f55d Mon Sep 17 00:00:00 2001 +From: Milind Changire +Date: Tue, 10 Oct 2017 09:58:24 +0530 +Subject: [PATCH 19/52] build: launch glusterd upgrade after all new bits are + installed + +Problem: +glusterd upgrade mode needs new bits from glusterfs-rdma which +optional and causes the dependency graph to break since it is +not tied into glusterfs-server requirements + +Solution: +Run glusterd upgrade mode after all new bits are installed +i.e. in %posttrans server section + +Label: DOWNSTREAM ONLY + +Change-Id: I356e02d0bf0eaaef43c20ce07b388262f63093a4 +Signed-off-by: Milind Changire +Reviewed-on: https://code.engineering.redhat.com/gerrit/120094 +Reviewed-by: Atin Mukherjee +Tested-by: RHGS Build Bot +Reviewed-by: Raghavendra Talur +--- + glusterfs.spec.in | 51 +++++++++++++++++++++++++++++---------------------- + 1 file changed, 29 insertions(+), 22 deletions(-) + +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index 3a98822..208a82d 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -946,28 +946,6 @@ fi + %firewalld_reload + %endif + +-pidof -c -o %PPID -x glusterd &> /dev/null +-if [ $? -eq 0 ]; then +- kill -9 `pgrep -f gsyncd.py` &> /dev/null +- +- killall --wait glusterd &> /dev/null +- glusterd --xlator-option *.upgrade=on -N +- +- #Cleaning leftover glusterd socket file which is created by glusterd in +- #rpm_script_t context. +- rm -f %{_rundir}/glusterd.socket +- +- # glusterd _was_ running, we killed it, it exited after *.upgrade=on, +- # so start it again +- %service_start glusterd +-else +- glusterd --xlator-option *.upgrade=on -N +- +- #Cleaning leftover glusterd socket file which is created by glusterd in +- #rpm_script_t context. +- rm -f %{_rundir}/glusterd.socket +-fi +-exit 0 + %endif + + ##----------------------------------------------------------------------------- +@@ -2027,6 +2005,35 @@ os.remove(tmpname) + if not (ok == 0) then + error("Detected running glusterfs processes", ok) + end ++ ++%posttrans server ++pidof -c -o %PPID -x glusterd &> /dev/null ++if [ $? -eq 0 ]; then ++ kill -9 `pgrep -f gsyncd.py` &> /dev/null ++ ++ killall --wait -SIGTERM glusterd &> /dev/null ++ ++ if [ "$?" != "0" ]; then ++ echo "killall failed while killing glusterd" ++ fi ++ ++ glusterd --xlator-option *.upgrade=on -N ++ ++ #Cleaning leftover glusterd socket file which is created by glusterd in ++ #rpm_script_t context. ++ rm -rf /var/run/glusterd.socket ++ ++ # glusterd _was_ running, we killed it, it exited after *.upgrade=on, ++ # so start it again ++ %service_start glusterd ++else ++ glusterd --xlator-option *.upgrade=on -N ++ ++ #Cleaning leftover glusterd socket file which is created by glusterd in ++ #rpm_script_t context. ++ rm -rf /var/run/glusterd.socket ++fi ++ + %endif + + %changelog +-- +1.8.3.1 + diff --git a/0020-spec-unpackaged-files-found-for-RHEL-7-client-build.patch b/0020-spec-unpackaged-files-found-for-RHEL-7-client-build.patch new file mode 100644 index 0000000..c00c7f4 --- /dev/null +++ b/0020-spec-unpackaged-files-found-for-RHEL-7-client-build.patch @@ -0,0 +1,38 @@ +From 968e5e698a070f9e6905a86c9c8338c36fcfa339 Mon Sep 17 00:00:00 2001 +From: moagrawa +Date: Mon, 15 Jan 2018 18:21:27 +0530 +Subject: [PATCH 20/52] spec: unpackaged files found for RHEL-7 client build + +Problem: unpackages files found for RHEL-7 client build + +Solution: Update glusterfs.specs.in to exclude unpackage files +Label: DOWNSTREAM ONLY + +Change-Id: I761188a6a8447105b53bf3334ded963c645cab5b +Signed-off-by: moagrawa +Reviewed-on: https://code.engineering.redhat.com/gerrit/127758 +Tested-by: RHGS Build Bot +Reviewed-by: Milind Changire +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +--- + glusterfs.spec.in | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index 208a82d..ec06176 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -1141,8 +1141,10 @@ exit 0 + %exclude %{_sbindir}/gluster-setgfid2path + %exclude %{_sbindir}/glusterd + %exclude %{_sbindir}/snap_scheduler.py ++%if ( 0%{?_with_systemd:1} ) + %exclude %{_datadir}/glusterfs/scripts/control-cpu-load.sh + %exclude %{_datadir}/glusterfs/scripts/control-mem.sh ++%endif + %exclude %{_datadir}/glusterfs/scripts/post-upgrade-script-for-quota.sh + %exclude %{_datadir}/glusterfs/scripts/pre-upgrade-script-for-quota.sh + %exclude %{_datadir}/glusterfs/scripts/stop-all-gluster-processes.sh +-- +1.8.3.1 + diff --git a/0021-cli-glusterfsd-remove-copyright-information.patch b/0021-cli-glusterfsd-remove-copyright-information.patch new file mode 100644 index 0000000..0aa1d07 --- /dev/null +++ b/0021-cli-glusterfsd-remove-copyright-information.patch @@ -0,0 +1,66 @@ +From fbc7f0e5ac8c292b865a8e02ceed2efa101d145c Mon Sep 17 00:00:00 2001 +From: Atin Mukherjee +Date: Mon, 12 Mar 2018 19:47:11 +0530 +Subject: [PATCH 21/52] cli/glusterfsd: remove copyright information + +There's no point of dumping upstream copyright information in --version. + +Label: DOWNSTREAM ONLY + +Change-Id: I3a10e30878698e1d53082936bbf22bca560a3896 +Signed-off-by: Atin Mukherjee +Reviewed-on: https://code.engineering.redhat.com/gerrit/132445 +Tested-by: RHGS Build Bot +Reviewed-by: Milind Changire +--- + cli/src/cli.c | 11 +---------- + glusterfsd/src/glusterfsd.c | 11 +---------- + 2 files changed, 2 insertions(+), 20 deletions(-) + +diff --git a/cli/src/cli.c b/cli/src/cli.c +index 84ce0f4..08f117e 100644 +--- a/cli/src/cli.c ++++ b/cli/src/cli.c +@@ -65,16 +65,7 @@ extern int connected; + /* using argp for command line parsing */ + + const char *argp_program_version = +- "" PACKAGE_NAME " " PACKAGE_VERSION +- "\nRepository revision: " GLUSTERFS_REPOSITORY_REVISION +- "\n" +- "Copyright (c) 2006-2016 Red Hat, Inc. " +- "\n" +- "GlusterFS comes with ABSOLUTELY NO WARRANTY.\n" +- "It is licensed to you under your choice of the GNU Lesser\n" +- "General Public License, version 3 or any later version (LGPLv3\n" +- "or later), or the GNU General Public License, version 2 (GPLv2),\n" +- "in all cases as published by the Free Software Foundation."; ++ PACKAGE_NAME" "PACKAGE_VERSION; + const char *argp_program_bug_address = "<" PACKAGE_BUGREPORT ">"; + + struct rpc_clnt *global_quotad_rpc; +diff --git a/glusterfsd/src/glusterfsd.c b/glusterfsd/src/glusterfsd.c +index 5d46b3d..c983882 100644 +--- a/glusterfsd/src/glusterfsd.c ++++ b/glusterfsd/src/glusterfsd.c +@@ -86,16 +86,7 @@ static char argp_doc[] = + "--volfile-server=SERVER [MOUNT-POINT]\n" + "--volfile=VOLFILE [MOUNT-POINT]"; + const char *argp_program_version = +- "" PACKAGE_NAME " " PACKAGE_VERSION +- "\nRepository revision: " GLUSTERFS_REPOSITORY_REVISION +- "\n" +- "Copyright (c) 2006-2016 Red Hat, Inc. " +- "\n" +- "GlusterFS comes with ABSOLUTELY NO WARRANTY.\n" +- "It is licensed to you under your choice of the GNU Lesser\n" +- "General Public License, version 3 or any later version (LGPLv3\n" +- "or later), or the GNU General Public License, version 2 (GPLv2),\n" +- "in all cases as published by the Free Software Foundation."; ++ PACKAGE_NAME" "PACKAGE_VERSION; + const char *argp_program_bug_address = "<" PACKAGE_BUGREPORT ">"; + + static error_t +-- +1.8.3.1 + diff --git a/0022-cli-Remove-upstream-doc-reference.patch b/0022-cli-Remove-upstream-doc-reference.patch new file mode 100644 index 0000000..5f9bf28 --- /dev/null +++ b/0022-cli-Remove-upstream-doc-reference.patch @@ -0,0 +1,40 @@ +From 00db0c44d109e6f3e394487bf76ff28ba2eee7de Mon Sep 17 00:00:00 2001 +From: Ravishankar N +Date: Thu, 15 Mar 2018 12:56:02 +0530 +Subject: [PATCH 22/52] cli: Remove upstream doc reference + +...that is displayed while creating replica 2 volumes. + +Label: DOWNSTREAM ONLY + +Change-Id: I16b45c8ad3a33cdd2a464d84f51d006d8f568b23 +Signed-off-by: Ravishankar N +Reviewed-on: https://code.engineering.redhat.com/gerrit/132744 +Reviewed-by: Karthik Subrahmanya +Tested-by: RHGS Build Bot +Reviewed-by: Atin Mukherjee +--- + cli/src/cli-cmd-parser.c | 7 ++----- + 1 file changed, 2 insertions(+), 5 deletions(-) + +diff --git a/cli/src/cli-cmd-parser.c b/cli/src/cli-cmd-parser.c +index f148c59..760a10c 100644 +--- a/cli/src/cli-cmd-parser.c ++++ b/cli/src/cli-cmd-parser.c +@@ -606,11 +606,8 @@ cli_cmd_volume_create_parse(struct cli_state *state, const char **words, + "Replica 2 volumes are prone" + " to split-brain. Use " + "Arbiter or Replica 3 to " +- "avoid this. See: " +- "http://docs.gluster.org/en/latest/" +- "Administrator%20Guide/" +- "Split%20brain%20and%20ways%20to%20deal%20with%20it/." +- "\nDo you still want to " ++ "avoid this.\n" ++ "Do you still want to " + "continue?\n"; + answer = cli_cmd_get_confirmation(state, question); + if (GF_ANSWER_NO == answer) { +-- +1.8.3.1 + diff --git a/0023-hooks-remove-selinux-hooks.patch b/0023-hooks-remove-selinux-hooks.patch new file mode 100644 index 0000000..3d14855 --- /dev/null +++ b/0023-hooks-remove-selinux-hooks.patch @@ -0,0 +1,148 @@ +From 421743b7cfa6a249544f6abb4cca5a612bd20ea1 Mon Sep 17 00:00:00 2001 +From: Atin Mukherjee +Date: Tue, 11 Dec 2018 16:21:43 +0530 +Subject: [PATCH 23/52] hooks: remove selinux hooks + +Label: DOWNSTREAM ONLY + +Change-Id: I810466a0ca99ab21f5a8eac8cdffbb18333d10ad +Signed-off-by: Atin Mukherjee +Reviewed-on: https://code.engineering.redhat.com/gerrit/135800 +Tested-by: RHGS Build Bot +Reviewed-by: Jiffin Thottan +Reviewed-by: Milind Changire +--- + configure.ac | 20 -------------------- + extras/hook-scripts/Makefile.am | 2 +- + extras/hook-scripts/create/Makefile.am | 1 - + extras/hook-scripts/create/post/Makefile.am | 8 -------- + extras/hook-scripts/delete/Makefile.am | 1 - + extras/hook-scripts/delete/pre/Makefile.am | 8 -------- + glusterfs.spec.in | 2 -- + 7 files changed, 1 insertion(+), 41 deletions(-) + delete mode 100644 extras/hook-scripts/create/Makefile.am + delete mode 100644 extras/hook-scripts/create/post/Makefile.am + delete mode 100644 extras/hook-scripts/delete/Makefile.am + delete mode 100644 extras/hook-scripts/delete/pre/Makefile.am + +diff --git a/configure.ac b/configure.ac +index 2f341de..0d06f5a 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -214,10 +214,6 @@ AC_CONFIG_FILES([Makefile + extras/hook-scripts/add-brick/Makefile + extras/hook-scripts/add-brick/pre/Makefile + extras/hook-scripts/add-brick/post/Makefile +- extras/hook-scripts/create/Makefile +- extras/hook-scripts/create/post/Makefile +- extras/hook-scripts/delete/Makefile +- extras/hook-scripts/delete/pre/Makefile + extras/hook-scripts/start/Makefile + extras/hook-scripts/start/post/Makefile + extras/hook-scripts/set/Makefile +@@ -909,21 +905,6 @@ fi + AM_CONDITIONAL([BUILD_CLOUDSYNC], [test "x$BUILD_CLOUDSYNC" = "xyes"]) + dnl end cloudsync section + +-dnl SELinux feature enablement +-case $host_os in +- linux*) +- AC_ARG_ENABLE([selinux], +- AC_HELP_STRING([--disable-selinux], +- [Disable SELinux features]), +- [USE_SELINUX="${enableval}"], [USE_SELINUX="yes"]) +- ;; +- *) +- USE_SELINUX=no +- ;; +-esac +-AM_CONDITIONAL(USE_SELINUX, test "x${USE_SELINUX}" = "xyes") +-dnl end of SELinux feature enablement +- + AC_CHECK_HEADERS([execinfo.h], [have_backtrace=yes]) + if test "x${have_backtrace}" = "xyes"; then + AC_DEFINE(HAVE_BACKTRACE, 1, [define if found backtrace]) +@@ -1599,7 +1580,6 @@ echo "XML output : $BUILD_XML_OUTPUT" + echo "Unit Tests : $BUILD_UNITTEST" + echo "Track priv ports : $TRACK_PRIVPORTS" + echo "POSIX ACLs : $BUILD_POSIX_ACLS" +-echo "SELinux features : $USE_SELINUX" + echo "firewalld-config : $BUILD_FIREWALLD" + echo "Events : $BUILD_EVENTS" + echo "EC dynamic support : $EC_DYNAMIC_SUPPORT" +diff --git a/extras/hook-scripts/Makefile.am b/extras/hook-scripts/Makefile.am +index 26059d7..771b37e 100644 +--- a/extras/hook-scripts/Makefile.am ++++ b/extras/hook-scripts/Makefile.am +@@ -1,5 +1,5 @@ + EXTRA_DIST = S40ufo-stop.py S56glusterd-geo-rep-create-post.sh +-SUBDIRS = add-brick create delete set start stop reset ++SUBDIRS = add-brick set start stop reset + + scriptsdir = $(GLUSTERD_WORKDIR)/hooks/1/gsync-create/post/ + if USE_GEOREP +diff --git a/extras/hook-scripts/create/Makefile.am b/extras/hook-scripts/create/Makefile.am +deleted file mode 100644 +index b083a91..0000000 +--- a/extras/hook-scripts/create/Makefile.am ++++ /dev/null +@@ -1 +0,0 @@ +-SUBDIRS = post +diff --git a/extras/hook-scripts/create/post/Makefile.am b/extras/hook-scripts/create/post/Makefile.am +deleted file mode 100644 +index fd1892e..0000000 +--- a/extras/hook-scripts/create/post/Makefile.am ++++ /dev/null +@@ -1,8 +0,0 @@ +-EXTRA_DIST = S10selinux-label-brick.sh +- +-scriptsdir = $(GLUSTERD_WORKDIR)/hooks/1/create/post/ +-if WITH_SERVER +-if USE_SELINUX +-scripts_SCRIPTS = S10selinux-label-brick.sh +-endif +-endif +diff --git a/extras/hook-scripts/delete/Makefile.am b/extras/hook-scripts/delete/Makefile.am +deleted file mode 100644 +index c98a05d..0000000 +--- a/extras/hook-scripts/delete/Makefile.am ++++ /dev/null +@@ -1 +0,0 @@ +-SUBDIRS = pre +diff --git a/extras/hook-scripts/delete/pre/Makefile.am b/extras/hook-scripts/delete/pre/Makefile.am +deleted file mode 100644 +index 4fbfbe7..0000000 +--- a/extras/hook-scripts/delete/pre/Makefile.am ++++ /dev/null +@@ -1,8 +0,0 @@ +-EXTRA_DIST = S10selinux-del-fcontext.sh +- +-scriptsdir = $(GLUSTERD_WORKDIR)/hooks/1/delete/pre/ +-if WITH_SERVER +-if USE_SELINUX +-scripts_SCRIPTS = S10selinux-del-fcontext.sh +-endif +-endif +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index ec06176..db50b8e 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -1413,7 +1413,6 @@ exit 0 + %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/add-brick/pre/S28Quota-enable-root-xattr-heal.sh + %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/create + %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/create/post +- %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/create/post/S10selinux-label-brick.sh + %ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/create/pre + %ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/copy-file + %ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/copy-file/post +@@ -1422,7 +1421,6 @@ exit 0 + %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/delete/post + %{_sharedstatedir}/glusterd/hooks/1/delete/post/S57glusterfind-delete-post + %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/delete/pre +- %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/delete/pre/S10selinux-del-fcontext.sh + %ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/remove-brick + %ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/remove-brick/post + %ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/remove-brick/pre +-- +1.8.3.1 + diff --git a/0024-glusterd-Make-localtime-logging-option-invisible-in-.patch b/0024-glusterd-Make-localtime-logging-option-invisible-in-.patch new file mode 100644 index 0000000..59fe63f --- /dev/null +++ b/0024-glusterd-Make-localtime-logging-option-invisible-in-.patch @@ -0,0 +1,50 @@ +From 79c19f0c6d02228aa8cf4b9299afeb7e0b2ad0da Mon Sep 17 00:00:00 2001 +From: Atin Mukherjee +Date: Mon, 16 Apr 2018 17:44:19 +0530 +Subject: [PATCH 24/52] glusterd: Make localtime-logging option invisible in + downstream + +Label: DOWNSTREAM ONLY + +Change-Id: Ie631edebb7e19152392bfd3c369a96e88796bd75 +Signed-off-by: Atin Mukherjee +Reviewed-on: https://code.engineering.redhat.com/gerrit/135754 +Tested-by: RHGS Build Bot +--- + xlators/mgmt/glusterd/src/glusterd-op-sm.c | 2 +- + xlators/mgmt/glusterd/src/glusterd-volume-set.c | 3 ++- + 2 files changed, 3 insertions(+), 2 deletions(-) + +diff --git a/xlators/mgmt/glusterd/src/glusterd-op-sm.c b/xlators/mgmt/glusterd/src/glusterd-op-sm.c +index dd3f9eb..cbbb5d9 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-op-sm.c ++++ b/xlators/mgmt/glusterd/src/glusterd-op-sm.c +@@ -86,7 +86,7 @@ glusterd_all_vol_opts valid_all_vol_opts[] = { + * TBD: Discuss the default value for this. Maybe this should be a + * dynamic value depending on the memory specifications per node */ + {GLUSTERD_BRICKMUX_LIMIT_KEY, GLUSTERD_BRICKMUX_LIMIT_DFLT_VALUE}, +- {GLUSTERD_LOCALTIME_LOGGING_KEY, "disable"}, ++ /*{GLUSTERD_LOCALTIME_LOGGING_KEY, "disable"},*/ + {GLUSTERD_DAEMON_LOG_LEVEL_KEY, "INFO"}, + {NULL}, + }; +diff --git a/xlators/mgmt/glusterd/src/glusterd-volume-set.c b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +index 9a6fe9f..fed2864 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-volume-set.c ++++ b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +@@ -2850,10 +2850,11 @@ struct volopt_map_entry glusterd_volopt_map[] = { + "to have enabled when clients and/or bricks support " + "SELinux."}, + {.key = GLUSTERD_LOCALTIME_LOGGING_KEY, ++ /*{.key = GLUSTERD_LOCALTIME_LOGGING_KEY, + .voltype = "mgmt/glusterd", + .type = GLOBAL_DOC, + .op_version = GD_OP_VERSION_3_12_0, +- .validate_fn = validate_boolean}, ++ .validate_fn = validate_boolean},*/ + {.key = GLUSTERD_DAEMON_LOG_LEVEL_KEY, + .voltype = "mgmt/glusterd", + .type = GLOBAL_NO_DOC, +-- +1.8.3.1 + diff --git a/0025-build-make-RHGS-version-available-for-server.patch b/0025-build-make-RHGS-version-available-for-server.patch new file mode 100644 index 0000000..90f2592 --- /dev/null +++ b/0025-build-make-RHGS-version-available-for-server.patch @@ -0,0 +1,45 @@ +From 12ae1a9a62c2c94af44f55b03575ab8806bd22ee Mon Sep 17 00:00:00 2001 +From: Milind Changire +Date: Mon, 23 Apr 2018 13:16:30 +0530 +Subject: [PATCH 25/52] build: make RHGS version available for server + +Make /usr/share/glusterfs/release available for gluserfs-server package. +This file contains the RHGS release number for the release. + +Label: DOWNSTREAM ONLY + +Change-Id: I7485f77cfb8ca7f0f8363a20124900ae9ae8a528 +Signed-off-by: Milind Changire +Reviewed-on: https://code.engineering.redhat.com/gerrit/137139 +Tested-by: RHGS Build Bot +Reviewed-by: Atin Mukherjee +--- + glusterfs.spec.in | 5 +++++ + 1 file changed, 5 insertions(+) + +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index db50b8e..bdb47ba 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -862,6 +862,10 @@ install -p -m 0744 -D extras/command-completion/gluster.bash \ + %{buildroot}%{_sysconfdir}/bash_completion.d/gluster + %endif + ++%if ( 0%{!?_without_server:1} ) ++echo "RHGS 3.5" > %{buildroot}%{_datadir}/glusterfs/release ++%endif ++ + %clean + rm -rf %{buildroot} + +@@ -1452,6 +1456,7 @@ exit 0 + + # Extra utility script + %dir %{_libexecdir}/glusterfs ++ %{_datadir}/glusterfs/release + %dir %{_datadir}/glusterfs/scripts + %{_datadir}/glusterfs/scripts/stop-all-gluster-processes.sh + %if ( 0%{?_with_systemd:1} ) +-- +1.8.3.1 + diff --git a/0026-glusterd-Introduce-daemon-log-level-cluster-wide-opt.patch b/0026-glusterd-Introduce-daemon-log-level-cluster-wide-opt.patch new file mode 100644 index 0000000..8aa9fde --- /dev/null +++ b/0026-glusterd-Introduce-daemon-log-level-cluster-wide-opt.patch @@ -0,0 +1,68 @@ +From a3538a7d1fb7674acdf0934847f4004d8fbc4709 Mon Sep 17 00:00:00 2001 +From: Milind Changire +Date: Tue, 11 Dec 2018 17:57:50 +0530 +Subject: [PATCH 26/52] glusterd: Introduce daemon-log-level cluster wide + option + +This option, applicable to the node level daemons can be very helpful in +controlling the log level of these services. Please note any daemon +which is started prior to setting the specific value of this option (if +not INFO) will need to go through a restart to have this change into +effect. + +> upstream patch : https://review.gluster.org/#/c/20442/ + +Please note there's a difference in deownstream delta. The op-version +against this option is already tageed as 3_11_2 in RHGS 3.3.1 and hence +the same is retained. Marking this DOWNSTREAM_ONLY label because of + +Label: DOWNSTREAM ONLY + +IMPORTANT: +This patch only sets .op_version in glusterd-volume-set.c to +GD_OP_VERSION_3_11_2 as per Atin's recommendation on +Tue, Dec 11, 2018 5:46pm IST + +>Change-Id: I7f6d2620bab2b094c737f5cc816bc093e9c9c4c9 +>fixes: bz#1597473 +>Signed-off-by: Atin Mukherjee + +Change-Id: I7f6d2620bab2b094c737f5cc816bc093e9c9c4c9 +Signed-off-by: Atin Mukherjee +Reviewed-on: https://code.engineering.redhat.com/gerrit/143137 +Tested-by: RHGS Build Bot +Reviewed-by: Sanju Rakonde +--- + libglusterfs/src/glusterfs/globals.h | 2 ++ + xlators/mgmt/glusterd/src/glusterd-volume-set.c | 2 +- + 2 files changed, 3 insertions(+), 1 deletion(-) + +diff --git a/libglusterfs/src/glusterfs/globals.h b/libglusterfs/src/glusterfs/globals.h +index b9da872..a278f18 100644 +--- a/libglusterfs/src/glusterfs/globals.h ++++ b/libglusterfs/src/glusterfs/globals.h +@@ -104,6 +104,8 @@ + + #define GD_OP_VERSION_3_11_1 31101 /* Op-version for GlusterFS 3.11.1 */ + ++#define GD_OP_VERSION_3_11_2 31102 /* Op-version for GlusterFS 3.11.2 */ ++ + #define GD_OP_VERSION_3_12_0 31200 /* Op-version for GlusterFS 3.12.0 */ + + #define GD_OP_VERSION_3_12_2 31202 /* Op-version for GlusterFS 3.12.2 */ +diff --git a/xlators/mgmt/glusterd/src/glusterd-volume-set.c b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +index fed2864..84f2705 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-volume-set.c ++++ b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +@@ -2859,7 +2859,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .voltype = "mgmt/glusterd", + .type = GLOBAL_NO_DOC, + .value = "INFO", +- .op_version = GD_OP_VERSION_5_0}, ++ .op_version = GD_OP_VERSION_3_11_2}, + {.key = "debug.delay-gen", + .voltype = "debug/delay-gen", + .option = "!debug", +-- +1.8.3.1 + diff --git a/0027-glusterd-change-op-version-of-fips-mode-rchecksum.patch b/0027-glusterd-change-op-version-of-fips-mode-rchecksum.patch new file mode 100644 index 0000000..76b430c --- /dev/null +++ b/0027-glusterd-change-op-version-of-fips-mode-rchecksum.patch @@ -0,0 +1,50 @@ +From 9be3c4745b161f1815f77cd19b550ac9795845f5 Mon Sep 17 00:00:00 2001 +From: Ravishankar N +Date: Thu, 20 Sep 2018 22:01:05 +0530 +Subject: [PATCH 27/52] glusterd: change op-version of fips-mode-rchecksum + +..to GD_OP_VERSION_3_13_3 since GD_OP_VERSION_4_0_0 is not present in +rhgs-3.4.1 + +Label: DOWNSTREAM ONLY + +Change-Id: I759272748177d174b15123faffc2305f7a5ec58f +Signed-off-by: Ravishankar N +Reviewed-on: https://code.engineering.redhat.com/gerrit/150714 +Tested-by: RHGS Build Bot +Reviewed-by: Atin Mukherjee +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +--- + libglusterfs/src/glusterfs/globals.h | 2 ++ + xlators/mgmt/glusterd/src/glusterd-volume-set.c | 2 +- + 2 files changed, 3 insertions(+), 1 deletion(-) + +diff --git a/libglusterfs/src/glusterfs/globals.h b/libglusterfs/src/glusterfs/globals.h +index a278f18..4a82889 100644 +--- a/libglusterfs/src/glusterfs/globals.h ++++ b/libglusterfs/src/glusterfs/globals.h +@@ -118,6 +118,8 @@ + + #define GD_OP_VERSION_3_13_2 31302 /* Op-version for GlusterFS 3.13.2 */ + ++#define GD_OP_VERSION_3_13_3 31303 /* Op-version for GlusterFS 3.13.3 */ ++ + #define GD_OP_VERSION_4_0_0 40000 /* Op-version for GlusterFS 4.0.0 */ + + #define GD_OP_VERSION_4_1_0 40100 /* Op-version for GlusterFS 4.1.0 */ +diff --git a/xlators/mgmt/glusterd/src/glusterd-volume-set.c b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +index 84f2705..2bd0a9c 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-volume-set.c ++++ b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +@@ -2329,7 +2329,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .key = "storage.fips-mode-rchecksum", + .type = NO_DOC, + .voltype = "storage/posix", +- .op_version = GD_OP_VERSION_4_0_0, ++ .op_version = GD_OP_VERSION_3_13_3, + }, + { + .option = "force-create-mode", +-- +1.8.3.1 + diff --git a/0028-glusterd-Reset-op-version-for-features.shard-deletio.patch b/0028-glusterd-Reset-op-version-for-features.shard-deletio.patch new file mode 100644 index 0000000..b39c16b --- /dev/null +++ b/0028-glusterd-Reset-op-version-for-features.shard-deletio.patch @@ -0,0 +1,52 @@ +From 64ffcf770c5c0087f8937b5235ed0ad5b0efe7f2 Mon Sep 17 00:00:00 2001 +From: Krutika Dhananjay +Date: Wed, 12 Sep 2018 21:41:35 +0530 +Subject: [PATCH 28/52] glusterd: Reset op-version for + "features.shard-deletion-rate" + +The op-version for the "features.shard-deletion-rate" option was set to +4.2.0 in the upstream patch and backported at +e75be952569eb69325d5f505f7ab94aace31be52. +This commit reverts the op-version for this option to 3.13.3. + +Label: DOWNSTREAM ONLY + +Change-Id: Ie3d12f3119ad7a4b40d81bd8bd6ed591658e8371 +Signed-off-by: Krutika Dhananjay +Reviewed-on: https://code.engineering.redhat.com/gerrit/154865 +Tested-by: RHGS Build Bot +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +--- + libglusterfs/src/glusterfs/globals.h | 2 ++ + xlators/mgmt/glusterd/src/glusterd-volume-set.c | 2 +- + 2 files changed, 3 insertions(+), 1 deletion(-) + +diff --git a/libglusterfs/src/glusterfs/globals.h b/libglusterfs/src/glusterfs/globals.h +index 4a82889..4d95f75 100644 +--- a/libglusterfs/src/glusterfs/globals.h ++++ b/libglusterfs/src/glusterfs/globals.h +@@ -120,6 +120,8 @@ + + #define GD_OP_VERSION_3_13_3 31303 /* Op-version for GlusterFS 3.13.3 */ + ++#define GD_OP_VERSION_3_13_4 31304 /* Op-version for GlusterFS 3.13.4 */ ++ + #define GD_OP_VERSION_4_0_0 40000 /* Op-version for GlusterFS 4.0.0 */ + + #define GD_OP_VERSION_4_1_0 40100 /* Op-version for GlusterFS 4.1.0 */ +diff --git a/xlators/mgmt/glusterd/src/glusterd-volume-set.c b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +index 2bd0a9c..2f3271f 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-volume-set.c ++++ b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +@@ -2552,7 +2552,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { + }, + {.key = "features.shard-deletion-rate", + .voltype = "features/shard", +- .op_version = GD_OP_VERSION_5_0, ++ .op_version = GD_OP_VERSION_3_13_4, + .flags = VOLOPT_FLAG_CLIENT_OPT}, + { + .key = "features.scrub-throttle", +-- +1.8.3.1 + diff --git a/0029-glusterd-Reset-op-version-for-features.shard-lru-lim.patch b/0029-glusterd-Reset-op-version-for-features.shard-lru-lim.patch new file mode 100644 index 0000000..752a81b --- /dev/null +++ b/0029-glusterd-Reset-op-version-for-features.shard-lru-lim.patch @@ -0,0 +1,39 @@ +From b504052d003aa41fbd44eec286d1733b6f2a168e Mon Sep 17 00:00:00 2001 +From: Krutika Dhananjay +Date: Tue, 6 Nov 2018 18:44:55 +0530 +Subject: [PATCH 29/52] glusterd: Reset op-version for + "features.shard-lru-limit" + +The op-version for the "features.shard-lru-limit" option was set to +4.2.0 in the upstream patch and backported at +41e7e33c6512e98a1567e5a5532d3898b59cfa98 + +This commit reverts the op-version for this option to 3.13.4. + +Label: DOWNSTREAM ONLY + +Change-Id: I7d3ed6b373851267c78fc6815a83bee2c0906413 +Signed-off-by: Krutika Dhananjay +Reviewed-on: https://code.engineering.redhat.com/gerrit/155127 +Tested-by: RHGS Build Bot +Reviewed-by: Xavi Hernandez +--- + xlators/mgmt/glusterd/src/glusterd-volume-set.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/xlators/mgmt/glusterd/src/glusterd-volume-set.c b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +index 2f3271f..4bf89a6 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-volume-set.c ++++ b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +@@ -2546,7 +2546,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { + { + .key = "features.shard-lru-limit", + .voltype = "features/shard", +- .op_version = GD_OP_VERSION_5_0, ++ .op_version = GD_OP_VERSION_3_13_4, + .flags = VOLOPT_FLAG_CLIENT_OPT, + .type = NO_DOC, + }, +-- +1.8.3.1 + diff --git a/0030-selinux-glusterd-add-features.selinux-to-glusterd-vo.patch b/0030-selinux-glusterd-add-features.selinux-to-glusterd-vo.patch new file mode 100644 index 0000000..b50236d --- /dev/null +++ b/0030-selinux-glusterd-add-features.selinux-to-glusterd-vo.patch @@ -0,0 +1,42 @@ +From 1d2d29396ee25f09c7d379a992ac9bd244e89c39 Mon Sep 17 00:00:00 2001 +From: Jiffin Tony Thottan +Date: Thu, 13 Dec 2018 14:28:57 +0530 +Subject: [PATCH 30/52] selinux/glusterd : add "features.selinux" to + glusterd-volume-set.c + +updates: #593 +Change-Id: I38675ba4d47c8ba7f94cfb4734692683ddb3dcfd +Signed-off-by: Jiffin Tony Thottan +--- + xlators/mgmt/glusterd/src/glusterd-volume-set.c | 8 +++----- + 1 file changed, 3 insertions(+), 5 deletions(-) + +diff --git a/xlators/mgmt/glusterd/src/glusterd-volume-set.c b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +index 4bf89a6..11265bf 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-volume-set.c ++++ b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +@@ -1203,10 +1203,9 @@ struct volopt_map_entry glusterd_volopt_map[] = { + .voltype = "performance/io-threads", + .option = "pass-through", + .op_version = GD_OP_VERSION_4_1_0}, +- {.key = "performance.least-rate-limit", +- .voltype = "performance/io-threads", +- .op_version = 1 +- }, ++ {.key = "performance.least-rate-limit", ++ .voltype = "performance/io-threads", ++ .op_version = 1}, + + /* Other perf xlators' options */ + {.key = "performance.io-cache-pass-through", +@@ -2849,7 +2848,6 @@ struct volopt_map_entry glusterd_volopt_map[] = { + "trusted.gluster.selinux on the bricks. Recommended " + "to have enabled when clients and/or bricks support " + "SELinux."}, +- {.key = GLUSTERD_LOCALTIME_LOGGING_KEY, + /*{.key = GLUSTERD_LOCALTIME_LOGGING_KEY, + .voltype = "mgmt/glusterd", + .type = GLOBAL_DOC, +-- +1.8.3.1 + diff --git a/0031-glusterd-turn-off-selinux-feature-in-downstream.patch b/0031-glusterd-turn-off-selinux-feature-in-downstream.patch new file mode 100644 index 0000000..a7e1e26 --- /dev/null +++ b/0031-glusterd-turn-off-selinux-feature-in-downstream.patch @@ -0,0 +1,34 @@ +From c3176144e531e22bfe97d0fef3b0e3e449fb1d32 Mon Sep 17 00:00:00 2001 +From: Atin Mukherjee +Date: Mon, 16 Apr 2018 13:47:12 +0530 +Subject: [PATCH 31/52] glusterd: turn off selinux feature in downstream + +In RHGS 3.4.0 selinux feature was never meant to be qualified. + +Label: DOWNSTREAM ONLY + +Change-Id: I0cd5eb5207a757c8b6ef789980c061f211410bd5 +Signed-off-by: Atin Mukherjee +Reviewed-on: https://code.engineering.redhat.com/gerrit/135716 +Tested-by: RHGS Build Bot +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +--- + xlators/mgmt/glusterd/src/glusterd-volume-set.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/xlators/mgmt/glusterd/src/glusterd-volume-set.c b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +index 11265bf..d1244e4 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-volume-set.c ++++ b/xlators/mgmt/glusterd/src/glusterd-volume-set.c +@@ -2842,7 +2842,7 @@ struct volopt_map_entry glusterd_volopt_map[] = { + {.key = VKEY_FEATURES_SELINUX, + .voltype = "features/selinux", + .type = NO_DOC, +- .value = "on", ++ .value = "off", + .op_version = GD_OP_VERSION_3_11_0, + .description = "Convert security.selinux xattrs to " + "trusted.gluster.selinux on the bricks. Recommended " +-- +1.8.3.1 + diff --git a/0032-glusterd-update-gd-op-version-to-3_7_0.patch b/0032-glusterd-update-gd-op-version-to-3_7_0.patch new file mode 100644 index 0000000..82b34e3 --- /dev/null +++ b/0032-glusterd-update-gd-op-version-to-3_7_0.patch @@ -0,0 +1,29 @@ +From bfa7055c3901b34a49f7933ea9edcf6465843de1 Mon Sep 17 00:00:00 2001 +From: Milind Changire +Date: Wed, 23 Jan 2019 14:22:00 +0530 +Subject: [PATCH 32/52] glusterd: update gd-op-version to 3_7_0 + +Label: DOWNSTREAM ONLY + +Change-Id: Ia6456134cd7e544a415692d09cd1ccbb6e02dd82 +Signed-off-by: Milind Changire +--- + xlators/mgmt/glusterd/src/glusterd-rebalance.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/xlators/mgmt/glusterd/src/glusterd-rebalance.c b/xlators/mgmt/glusterd/src/glusterd-rebalance.c +index 6365b6e..e20e3c4 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-rebalance.c ++++ b/xlators/mgmt/glusterd/src/glusterd-rebalance.c +@@ -1174,7 +1174,7 @@ glusterd_op_stage_rebalance(dict_t *dict, char **op_errstr) + * 'force' + */ + ret = glusterd_check_client_op_version_support( +- volname, GD_OP_VERSION_3_6_0, NULL); ++ volname, GD_OP_VERSION_3_7_0, NULL); + if (ret) { + ret = gf_asprintf(op_errstr, + "Volume %s has one or " +-- +1.8.3.1 + diff --git a/0033-build-add-missing-explicit-package-dependencies.patch b/0033-build-add-missing-explicit-package-dependencies.patch new file mode 100644 index 0000000..57c2919 --- /dev/null +++ b/0033-build-add-missing-explicit-package-dependencies.patch @@ -0,0 +1,83 @@ +From 52e2d75c2c8e32d2e4f69840e34d21b39279284a Mon Sep 17 00:00:00 2001 +From: Milind Changire +Date: Thu, 13 Dec 2018 12:46:56 +0530 +Subject: [PATCH 33/52] build: add missing explicit package dependencies + +Add dependencies for glusterfs-libs, and other packages. +This is an Errata Tool whine. + +Label: DOWNSTREAM ONLY + +Change-Id: Ieaadb6e4ffa84d1811aa740f7891855568ecbcbb +Signed-off-by: Milind Changire +Reviewed-on: https://code.engineering.redhat.com/gerrit/158501 +Tested-by: RHGS Build Bot +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +--- + glusterfs.spec.in | 8 ++++++++ + 1 file changed, 8 insertions(+) + +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index bdb47ba..9cd4372 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -323,6 +323,7 @@ and client framework. + Summary: GlusterFS api library + Requires: %{name}%{?_isa} = %{version}-%{release} + Requires: %{name}-client-xlators%{?_isa} = %{version}-%{release} ++Requires: %{name}-libs%{?_isa} = %{version}-%{release} + + %description api + GlusterFS is a distributed file-system capable of scaling to several +@@ -340,6 +341,7 @@ Summary: Development Libraries + Requires: %{name}%{?_isa} = %{version}-%{release} + Requires: %{name}-devel%{?_isa} = %{version}-%{release} + Requires: libacl-devel ++Requires: %{name}-api%{?_isa} = %{version}-%{release} + + %description api-devel + GlusterFS is a distributed file-system capable of scaling to several +@@ -391,6 +393,8 @@ Requires: %{name}%{?_isa} = %{version}-%{release} + %if ( 0%{!?_without_extra_xlators:1} ) + Requires: %{name}-extra-xlators%{?_isa} = %{version}-%{release} + %endif ++Requires: %{name}-libs%{?_isa} = %{version}-%{release} ++Requires: %{name}-server%{?_isa} = %{version}-%{release} + + %description devel + GlusterFS is a distributed file-system capable of scaling to several +@@ -435,6 +439,7 @@ Requires: %{name}-client-xlators%{?_isa} = %{version}-%{release} + + Obsoletes: %{name}-client < %{version}-%{release} + Provides: %{name}-client = %{version}-%{release} ++Requires: %{name}-libs%{?_isa} = %{version}-%{release} + + %description fuse + GlusterFS is a distributed file-system capable of scaling to several +@@ -459,6 +464,7 @@ Requires: python%{_pythonver}-gluster = %{version}-%{release} + + Requires: rsync + Requires: util-linux ++Requires: %{name}-libs%{?_isa} = %{version}-%{release} + + %description geo-replication + GlusterFS is a distributed file-system capable of scaling to several +@@ -536,6 +542,7 @@ BuildRequires: libibverbs-devel + BuildRequires: librdmacm-devel >= 1.0.15 + %endif + Requires: %{name}%{?_isa} = %{version}-%{release} ++Requires: %{name}-libs%{?_isa} = %{version}-%{release} + + %description rdma + GlusterFS is a distributed file-system capable of scaling to several +@@ -664,6 +671,7 @@ This package provides the glusterfs thin-arbiter translator. + + %package client-xlators + Summary: GlusterFS client-side translators ++Requires: %{name}-libs%{?_isa} = %{version}-%{release} + + %description client-xlators + GlusterFS is a distributed file-system capable of scaling to several +-- +1.8.3.1 + diff --git a/0034-glusterd-introduce-a-new-op-version-for-rhgs-3.4.3.patch b/0034-glusterd-introduce-a-new-op-version-for-rhgs-3.4.3.patch new file mode 100644 index 0000000..587a25a --- /dev/null +++ b/0034-glusterd-introduce-a-new-op-version-for-rhgs-3.4.3.patch @@ -0,0 +1,59 @@ +From 463a920541a7579f2407f22597e4014494422804 Mon Sep 17 00:00:00 2001 +From: Sanju Rakonde +Date: Mon, 17 Dec 2018 14:07:01 +0530 +Subject: [PATCH 34/52] glusterd: introduce a new op-version for rhgs-3.4.3 + +This patch introduces a new op-version 31305 for rhgs-3.4.3 and +sets the max op-version to 31305. + +For migrating profile commands (commit e68845ff7018e5d81d7979684b18e6eda449b088) +we used GD_OP_VERSION_6_0 in upstream. we are changing +it to GD_OP_VERSION_3_13_5 here. + +Label: DOWNSTREAM ONLY + +Change-Id: Ie3a05c70eb4e406889c468343f54e999b1218f19 +Signed-off-by: Sanju Rakonde +Reviewed-on: https://code.engineering.redhat.com/gerrit/158795 +Tested-by: RHGS Build Bot +Reviewed-by: Atin Mukherjee +--- + libglusterfs/src/glusterfs/globals.h | 2 ++ + xlators/mgmt/glusterd/src/glusterd-handler.c | 4 ++-- + 2 files changed, 4 insertions(+), 2 deletions(-) + +diff --git a/libglusterfs/src/glusterfs/globals.h b/libglusterfs/src/glusterfs/globals.h +index 4d95f75..6642ba0 100644 +--- a/libglusterfs/src/glusterfs/globals.h ++++ b/libglusterfs/src/glusterfs/globals.h +@@ -122,6 +122,8 @@ + + #define GD_OP_VERSION_3_13_4 31304 /* Op-version for GlusterFS 3.13.4 */ + ++#define GD_OP_VERSION_3_13_5 31305 /* Op-version for GlusterFS 3.13.5 */ ++ + #define GD_OP_VERSION_4_0_0 40000 /* Op-version for GlusterFS 4.0.0 */ + + #define GD_OP_VERSION_4_1_0 40100 /* Op-version for GlusterFS 4.1.0 */ +diff --git a/xlators/mgmt/glusterd/src/glusterd-handler.c b/xlators/mgmt/glusterd/src/glusterd-handler.c +index 387643d..de44af7 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-handler.c ++++ b/xlators/mgmt/glusterd/src/glusterd-handler.c +@@ -3085,12 +3085,12 @@ __glusterd_handle_cli_profile_volume(rpcsvc_request_t *req) + goto out; + } + +- if (conf->op_version < GD_OP_VERSION_6_0) { ++ if (conf->op_version < GD_OP_VERSION_3_13_5) { + gf_msg_debug(this->name, 0, + "The cluster is operating at " + "version less than %d. Falling back " + "to op-sm framework.", +- GD_OP_VERSION_6_0); ++ GD_OP_VERSION_3_13_5); + ret = glusterd_op_begin(req, cli_op, dict, err_str, sizeof(err_str)); + glusterd_friend_sm(); + glusterd_op_sm(); +-- +1.8.3.1 + diff --git a/0035-glusterd-tag-rebalance-mgmt_v3-command-to-op-version.patch b/0035-glusterd-tag-rebalance-mgmt_v3-command-to-op-version.patch new file mode 100644 index 0000000..643ba3a --- /dev/null +++ b/0035-glusterd-tag-rebalance-mgmt_v3-command-to-op-version.patch @@ -0,0 +1,41 @@ +From 254033a80d85460675c921c272fb94bb7e9f67d4 Mon Sep 17 00:00:00 2001 +From: Atin Mukherjee +Date: Tue, 18 Dec 2018 17:57:25 +0530 +Subject: [PATCH 35/52] glusterd: tag rebalance mgmt_v3 command to op-version + 31305 + +In upstream migrating rebalance command is tagged to op-version 60000 +but in downstream the latest new op-version is 31305. + +Label: DOWNSTREAM ONLY + +Change-Id: I30bbad3efca29bf42b9a750581eb1aebc8a30ff9 +Signed-off-by: Atin Mukherjee +Reviewed-on: https://code.engineering.redhat.com/gerrit/158943 +Tested-by: RHGS Build Bot +--- + xlators/mgmt/glusterd/src/glusterd-rebalance.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/xlators/mgmt/glusterd/src/glusterd-rebalance.c b/xlators/mgmt/glusterd/src/glusterd-rebalance.c +index e20e3c4..ed5ded5 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-rebalance.c ++++ b/xlators/mgmt/glusterd/src/glusterd-rebalance.c +@@ -573,12 +573,12 @@ __glusterd_handle_defrag_volume(rpcsvc_request_t *req) + } else + op = GD_OP_REBALANCE; + +- if (priv->op_version < GD_OP_VERSION_6_0) { ++ if (priv->op_version < GD_OP_VERSION_3_13_5) { + gf_msg_debug(this->name, 0, + "The cluster is operating at " + "version less than %d. Falling back " + "to op-sm framework.", +- GD_OP_VERSION_6_0); ++ GD_OP_VERSION_3_13_5); + ret = glusterd_op_begin(req, op, dict, msg, sizeof(msg)); + glusterd_friend_sm(); + glusterd_op_sm(); +-- +1.8.3.1 + diff --git a/0036-build-add-conditional-dependency-on-server-for-devel.patch b/0036-build-add-conditional-dependency-on-server-for-devel.patch new file mode 100644 index 0000000..352078b --- /dev/null +++ b/0036-build-add-conditional-dependency-on-server-for-devel.patch @@ -0,0 +1,47 @@ +From d6458c40706d8886187bd9c2016087a3a1eee882 Mon Sep 17 00:00:00 2001 +From: Milind Changire +Date: Wed, 19 Dec 2018 13:17:42 +0530 +Subject: [PATCH 36/52] build: add conditional dependency on server for devel + +Add conditional depedency on server for glusterfs-devel + +Label: DOWNSTREAM ONLY + +Change-Id: Icc45df3db137dbc03d240c1ac774b5c8735c5f2f +Signed-off-by: Milind Changire +Reviewed-on: https://code.engineering.redhat.com/gerrit/159030 +Tested-by: RHGS Build Bot +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +--- + glusterfs.spec.in | 7 +++++++ + 1 file changed, 7 insertions(+) + +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index 9cd4372..9db5a34 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -394,7 +394,9 @@ Requires: %{name}%{?_isa} = %{version}-%{release} + Requires: %{name}-extra-xlators%{?_isa} = %{version}-%{release} + %endif + Requires: %{name}-libs%{?_isa} = %{version}-%{release} ++%if ( 0%{!?_without_server:1} ) + Requires: %{name}-server%{?_isa} = %{version}-%{release} ++%endif + + %description devel + GlusterFS is a distributed file-system capable of scaling to several +@@ -2067,6 +2069,11 @@ fi + * Thu Feb 21 2019 Jiffin Tony Thottan + - Obsoleting gluster-gnfs package + ++* Wed Dec 19 2018 Milind Changire ++- Add explicit package dependencies (#1656357) ++- Remove absolute paths from spec file (#1350745) ++- Do not package crypt.so for FIPS compliance (#1653224) ++ + * Wed Nov 28 2018 Krutika Dhananjay + - Install /var/lib/glusterd/groups/distributed-virt by default + +-- +1.8.3.1 + diff --git a/0037-cli-change-the-warning-message.patch b/0037-cli-change-the-warning-message.patch new file mode 100644 index 0000000..e4a4544 --- /dev/null +++ b/0037-cli-change-the-warning-message.patch @@ -0,0 +1,35 @@ +From 7e0342e0d01204f136b0bd28931a6313ea216649 Mon Sep 17 00:00:00 2001 +From: Sanju Rakonde +Date: Wed, 6 Feb 2019 19:06:45 +0530 +Subject: [PATCH 37/52] cli: change the warning message + +This patch changes the warning message user gets, when enabling brick +multiplexing to reflect OCS instead of CNS/CRS. + +Label: DOWNSTREAM ONLY + +Change-Id: Id5fd87955d5a692f8e57560245f8b0cf9882e1da +Signed-off-by: Sanju Rakonde +Reviewed-on: https://code.engineering.redhat.com/gerrit/162405 +Reviewed-by: Atin Mukherjee +Tested-by: RHGS Build Bot +--- + cli/src/cli-cmd-parser.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/cli/src/cli-cmd-parser.c b/cli/src/cli-cmd-parser.c +index 760a10c..541dc62 100644 +--- a/cli/src/cli-cmd-parser.c ++++ b/cli/src/cli-cmd-parser.c +@@ -1697,7 +1697,7 @@ cli_cmd_volume_set_parse(struct cli_state *state, const char **words, + + if ((strcmp (key, "cluster.brick-multiplex") == 0)) { + question = "Brick-multiplexing is supported only for " +- "container workloads (CNS/CRS). Also it is " ++ "OCS converged or independent mode. Also it is " + "advised to make sure that either all " + "volumes are in stopped state or no bricks " + "are running before this option is modified." +-- +1.8.3.1 + diff --git a/0038-spec-avoid-creation-of-temp-file-in-lua-script.patch b/0038-spec-avoid-creation-of-temp-file-in-lua-script.patch new file mode 100644 index 0000000..00a5af3 --- /dev/null +++ b/0038-spec-avoid-creation-of-temp-file-in-lua-script.patch @@ -0,0 +1,230 @@ +From a577dd0a3cbf435681f10d095a0dca0595c6a354 Mon Sep 17 00:00:00 2001 +From: Milind Changire +Date: Sat, 9 Feb 2019 14:01:28 +0530 +Subject: [PATCH 38/52] spec: avoid creation of temp file in lua script + +Avoiding creation of temporary file to execute bash shell script from a +lua scriptlet increases install time security. + +Label: DOWNSTREAM ONLY + +Change-Id: Ie5b9035f292402b18dea768aca8bc82a1e7fa615 +Signed-off-by: Milind Changire +Reviewed-on: https://code.engineering.redhat.com/gerrit/162621 +Tested-by: RHGS Build Bot +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +--- + glusterfs.spec.in | 120 ++++++------------------------------------------------ + 1 file changed, 12 insertions(+), 108 deletions(-) + +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index 9db5a34..df8d116 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -1542,15 +1542,7 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- Since we run pretrans scripts only for RPMs built for a server build, +--- we can now use os.tmpname() since it is available on RHEL6 and later +--- platforms which are server platforms. +-tmpname = os.tmpname() +-tmpfile = io.open(tmpname, "w") +-tmpfile:write(script) +-tmpfile:close() +-ok, how, val = os.execute("/bin/bash " .. tmpname) +-os.remove(tmpname) ++ok, how, val = os.execute(script) + if not (ok == 0) then + error("Detected running glusterfs processes", ok) + end +@@ -1584,15 +1576,7 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- Since we run pretrans scripts only for RPMs built for a server build, +--- we can now use os.tmpname() since it is available on RHEL6 and later +--- platforms which are server platforms. +-tmpname = os.tmpname() +-tmpfile = io.open(tmpname, "w") +-tmpfile:write(script) +-tmpfile:close() +-ok, how, val = os.execute("/bin/bash " .. tmpname) +-os.remove(tmpname) ++ok, how, val = os.execute(script) + if not (ok == 0) then + error("Detected running glusterfs processes", ok) + end +@@ -1626,15 +1610,7 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- Since we run pretrans scripts only for RPMs built for a server build, +--- we can now use os.tmpname() since it is available on RHEL6 and later +--- platforms which are server platforms. +-tmpname = os.tmpname() +-tmpfile = io.open(tmpname, "w") +-tmpfile:write(script) +-tmpfile:close() +-ok, how, val = os.execute("/bin/bash " .. tmpname) +-os.remove(tmpname) ++ok, how, val = os.execute(script) + if not (ok == 0) then + error("Detected running glusterfs processes", ok) + end +@@ -1668,15 +1644,7 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- Since we run pretrans scripts only for RPMs built for a server build, +--- we can now use os.tmpname() since it is available on RHEL6 and later +--- platforms which are server platforms. +-tmpname = os.tmpname() +-tmpfile = io.open(tmpname, "w") +-tmpfile:write(script) +-tmpfile:close() +-ok, how, val = os.execute("/bin/bash " .. tmpname) +-os.remove(tmpname) ++ok, how, val = os.execute(script) + if not (ok == 0) then + error("Detected running glusterfs processes", ok) + end +@@ -1709,15 +1677,7 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- Since we run pretrans scripts only for RPMs built for a server build, +--- we can now use os.tmpname() since it is available on RHEL6 and later +--- platforms which are server platforms. +-tmpname = os.tmpname() +-tmpfile = io.open(tmpname, "w") +-tmpfile:write(script) +-tmpfile:close() +-ok, how, val = os.execute("/bin/bash " .. tmpname) +-os.remove(tmpname) ++ok, how, val = os.execute(script) + if not (ok == 0) then + error("Detected running glusterfs processes", ok) + end +@@ -1750,15 +1710,7 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- Since we run pretrans scripts only for RPMs built for a server build, +--- we can now use os.tmpname() since it is available on RHEL6 and later +--- platforms which are server platforms. +-tmpname = os.tmpname() +-tmpfile = io.open(tmpname, "w") +-tmpfile:write(script) +-tmpfile:close() +-ok, how, val = os.execute("/bin/bash " .. tmpname) +-os.remove(tmpname) ++ok, how, val = os.execute(script) + if not (ok == 0) then + error("Detected running glusterfs processes", ok) + end +@@ -1792,15 +1744,7 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- Since we run pretrans scripts only for RPMs built for a server build, +--- we can now use os.tmpname() since it is available on RHEL6 and later +--- platforms which are server platforms. +-tmpname = os.tmpname() +-tmpfile = io.open(tmpname, "w") +-tmpfile:write(script) +-tmpfile:close() +-ok, how, val = os.execute("/bin/bash " .. tmpname) +-os.remove(tmpname) ++ok, how, val = os.execute(script) + if not (ok == 0) then + error("Detected running glusterfs processes", ok) + end +@@ -1835,15 +1779,7 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- Since we run pretrans scripts only for RPMs built for a server build, +--- we can now use os.tmpname() since it is available on RHEL6 and later +--- platforms which are server platforms. +-tmpname = os.tmpname() +-tmpfile = io.open(tmpname, "w") +-tmpfile:write(script) +-tmpfile:close() +-ok, how, val = os.execute("/bin/bash " .. tmpname) +-os.remove(tmpname) ++ok, how, val = os.execute(script) + if not (ok == 0) then + error("Detected running glusterfs processes", ok) + end +@@ -1878,15 +1814,7 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- Since we run pretrans scripts only for RPMs built for a server build, +--- we can now use os.tmpname() since it is available on RHEL6 and later +--- platforms which are server platforms. +-tmpname = os.tmpname() +-tmpfile = io.open(tmpname, "w") +-tmpfile:write(script) +-tmpfile:close() +-ok, how, val = os.execute("/bin/bash " .. tmpname) +-os.remove(tmpname) ++ok, how, val = os.execute(script) + if not (ok == 0) then + error("Detected running glusterfs processes", ok) + end +@@ -1921,15 +1849,7 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- Since we run pretrans scripts only for RPMs built for a server build, +--- we can now use os.tmpname() since it is available on RHEL6 and later +--- platforms which are server platforms. +-tmpname = os.tmpname() +-tmpfile = io.open(tmpname, "w") +-tmpfile:write(script) +-tmpfile:close() +-ok, how, val = os.execute("/bin/bash " .. tmpname) +-os.remove(tmpname) ++ok, how, val = os.execute(script) + if not (ok == 0) then + error("Detected running glusterfs processes", ok) + end +@@ -1965,15 +1885,7 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- Since we run pretrans scripts only for RPMs built for a server build, +--- we can now use os.tmpname() since it is available on RHEL6 and later +--- platforms which are server platforms. +-tmpname = os.tmpname() +-tmpfile = io.open(tmpname, "w") +-tmpfile:write(script) +-tmpfile:close() +-ok, how, val = os.execute("/bin/bash " .. tmpname) +-os.remove(tmpname) ++ok, how, val = os.execute(script) + if not (ok == 0) then + error("Detected running glusterfs processes", ok) + end +@@ -2008,15 +1920,7 @@ if [ $? -eq 0 ]; then + fi + ]] + +--- Since we run pretrans scripts only for RPMs built for a server build, +--- we can now use os.tmpname() since it is available on RHEL6 and later +--- platforms which are server platforms. +-tmpname = os.tmpname() +-tmpfile = io.open(tmpname, "w") +-tmpfile:write(script) +-tmpfile:close() +-ok, how, val = os.execute("/bin/bash " .. tmpname) +-os.remove(tmpname) ++ok, how, val = os.execute(script) + if not (ok == 0) then + error("Detected running glusterfs processes", ok) + end +-- +1.8.3.1 + diff --git a/0039-cli-fix-query-to-user-during-brick-mux-selection.patch b/0039-cli-fix-query-to-user-during-brick-mux-selection.patch new file mode 100644 index 0000000..82684cb --- /dev/null +++ b/0039-cli-fix-query-to-user-during-brick-mux-selection.patch @@ -0,0 +1,61 @@ +From ec707e099d4e4338d1ea21560d367b02e6339532 Mon Sep 17 00:00:00 2001 +From: Sunil Kumar Acharya +Date: Mon, 1 Apr 2019 16:16:47 +0530 +Subject: [PATCH 39/52] cli: fix query to user during brick-mux selection + +Label: DOWNSTREAM ONLY + +Change-Id: I59472066b917ea2b23de72bcd91dc3e275d5e055 +Signed-off-by: Sunil Kumar Acharya +--- + cli/src/cli-cmd-parser.c | 33 +++++++++++++++++---------------- + 1 file changed, 17 insertions(+), 16 deletions(-) + +diff --git a/cli/src/cli-cmd-parser.c b/cli/src/cli-cmd-parser.c +index 541dc62..d9ccba1 100644 +--- a/cli/src/cli-cmd-parser.c ++++ b/cli/src/cli-cmd-parser.c +@@ -1693,23 +1693,24 @@ cli_cmd_volume_set_parse(struct cli_state *state, const char **words, + goto out; + } + } +- } +- +- if ((strcmp (key, "cluster.brick-multiplex") == 0)) { +- question = "Brick-multiplexing is supported only for " +- "OCS converged or independent mode. Also it is " +- "advised to make sure that either all " +- "volumes are in stopped state or no bricks " +- "are running before this option is modified." +- "Do you still want to continue?"; + +- answer = cli_cmd_get_confirmation (state, question); +- if (GF_ANSWER_NO == answer) { +- gf_log ("cli", GF_LOG_ERROR, "Operation " +- "cancelled, exiting"); +- *op_errstr = gf_strdup ("Aborted by user."); +- ret = -1; +- goto out; ++ if ((strcmp (key, "cluster.brick-multiplex") == 0)) { ++ question = ++ "Brick-multiplexing is supported only for " ++ "OCS converged or independent mode. Also it is " ++ "advised to make sure that either all " ++ "volumes are in stopped state or no bricks " ++ "are running before this option is modified." ++ "Do you still want to continue?"; ++ ++ answer = cli_cmd_get_confirmation (state, question); ++ if (GF_ANSWER_NO == answer) { ++ gf_log ("cli", GF_LOG_ERROR, "Operation " ++ "cancelled, exiting"); ++ *op_errstr = gf_strdup ("Aborted by user."); ++ ret = -1; ++ goto out; ++ } + } + } + +-- +1.8.3.1 + diff --git a/0040-build-Remove-unsupported-test-cases-failing-consiste.patch b/0040-build-Remove-unsupported-test-cases-failing-consiste.patch new file mode 100644 index 0000000..1d10507 --- /dev/null +++ b/0040-build-Remove-unsupported-test-cases-failing-consiste.patch @@ -0,0 +1,136 @@ +From 79c74009892804419dce264399f3fde357d5b1c3 Mon Sep 17 00:00:00 2001 +From: Susant Palai +Date: Tue, 2 Apr 2019 11:07:03 +0530 +Subject: [PATCH 40/52] build: Remove unsupported test cases failing + consistently + +The following two test cases failing in downstream regression runs. +Hence removing them as they are not supported downstream. + +tests/basic/cloudsync-sanity.t +tests/bugs/distribute/bug-882278.t + +Label: DOWNSTREAM ONLY + +Change-Id: Ie4b506639a017ec9910e44df1b721d9bfadf07b3 +Signed-off-by: Susant Palai +Reviewed-on: https://code.engineering.redhat.com/gerrit/166662 +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +Tested-by: Sunil Kumar Heggodu Gopala Acharya +--- + tests/basic/cloudsync-sanity.t | 22 ------------ + tests/bugs/distribute/bug-882278.t | 73 -------------------------------------- + 2 files changed, 95 deletions(-) + delete mode 100644 tests/basic/cloudsync-sanity.t + delete mode 100755 tests/bugs/distribute/bug-882278.t + +diff --git a/tests/basic/cloudsync-sanity.t b/tests/basic/cloudsync-sanity.t +deleted file mode 100644 +index 3cf719d..0000000 +--- a/tests/basic/cloudsync-sanity.t ++++ /dev/null +@@ -1,22 +0,0 @@ +-#!/bin/bash +- +-. $(dirname $0)/../include.rc +-. $(dirname $0)/../volume.rc +- +-cleanup; +- +-TEST glusterd +-TEST pidof glusterd +- +-TEST $CLI volume create $V0 replica 3 $H0:$B0/${V0}{1,2,3,4,5,6,7,8,9}; +-TEST $CLI volume set $V0 features.cloudsync enable; +-TEST $CLI volume start $V0; +- +-## Mount FUSE +-TEST $GFS -s $H0 --volfile-id $V0 $M1; +- +-# This test covers lookup, mkdir, mknod, symlink, link, rename, +-# create operations +-TEST $(dirname $0)/rpc-coverage.sh $M1 +- +-cleanup; +diff --git a/tests/bugs/distribute/bug-882278.t b/tests/bugs/distribute/bug-882278.t +deleted file mode 100755 +index 8cb5147..0000000 +--- a/tests/bugs/distribute/bug-882278.t ++++ /dev/null +@@ -1,73 +0,0 @@ +-#!/bin/bash +- +-. $(dirname $0)/../../include.rc +-. $(dirname $0)/../../volume.rc +-cleanup +- +-# Is there a good reason to require --fqdn elsewhere? It's worse than useless +-# here. +-H0=$(hostname -s) +- +-function recreate { +- # The rm is necessary so we don't get fooled by leftovers from old runs. +- rm -rf $1 && mkdir -p $1 +-} +- +-function count_lines { +- grep "$1" $2/* | wc -l +-} +- +-TEST glusterd +-TEST pidof glusterd +-TEST $CLI volume info; +- +-## Start and create a volume +-TEST recreate ${B0}/${V0}-0 +-TEST recreate ${B0}/${V0}-1 +-TEST $CLI volume create $V0 $H0:$B0/${V0}-{0,1} +-TEST $CLI volume set $V0 cluster.nufa on +- +-function volinfo_field() +-{ +- local vol=$1; +- local field=$2; +- +- $CLI volume info $vol | grep "^$field: " | sed 's/.*: //'; +-} +- +- +-## Verify volume is created +-EXPECT "$V0" volinfo_field $V0 'Volume Name'; +-EXPECT 'Created' volinfo_field $V0 'Status'; +- +-## Start volume and verify +-TEST $CLI volume start $V0; +-EXPECT 'Started' volinfo_field $V0 'Status'; +- +-## Mount native +-special_option="--xlator-option ${V0}-dht.local-volume-name=${V0}-client-1" +-TEST glusterfs --volfile-server=$H0 --volfile-id=$V0 $special_option $M0 +- +-## Create a bunch of test files. +-for i in $(seq 0 99); do +- echo hello > $(printf $M0/file%02d $i) +-done +- +-## Make sure the files went to the right place. There might be link files in +-## the other brick, but they won't have any contents. +-EXPECT "0" count_lines hello ${B0}/${V0}-0 +-EXPECT "100" count_lines hello ${B0}/${V0}-1 +- +-if [ "$EXIT_EARLY" = "1" ]; then +- exit 0; +-fi +- +-## Finish up +-EXPECT_WITHIN $UMOUNT_TIMEOUT "Y" force_umount $M0 +-TEST $CLI volume stop $V0; +-EXPECT 'Stopped' volinfo_field $V0 'Status'; +- +-TEST $CLI volume delete $V0; +-TEST ! $CLI volume info $V0; +- +-cleanup; +-- +1.8.3.1 + diff --git a/0041-tests-geo-rep-Build-failed-in-Jenkins-for-test-bug-1.patch b/0041-tests-geo-rep-Build-failed-in-Jenkins-for-test-bug-1.patch new file mode 100644 index 0000000..c1e1720 --- /dev/null +++ b/0041-tests-geo-rep-Build-failed-in-Jenkins-for-test-bug-1.patch @@ -0,0 +1,43 @@ +From c8f0ac9b429e1ff73a3e87247193c35c66212540 Mon Sep 17 00:00:00 2001 +From: Shwetha K Acharya +Date: Tue, 2 Apr 2019 12:06:53 +0530 +Subject: [PATCH 41/52] tests/geo-rep: Build failed in Jenkins for test + bug-1600145.t + +Problem: the ((strcmp (key, "cluster.brick-multiplex") == 0)) +comparision in cli/src/cli-cmd-parser.c is expecting +either yes or no confirmation from cli, which is not handled +in bug-1600145.t, causing test to wait till timeout and +then fail. + +Solution: Passing yes as pipeline to +`gluster v set all cluster.brick-multiplex on` in bug-1600145.t + +Label: DOWNSTREAM ONLY + +Change-Id: I1a6c2a992b65380cea145fd1c46d22ec1251c77e +Signed-off-by: Shwetha K Acharya +Reviewed-on: https://code.engineering.redhat.com/gerrit/166694 +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +Tested-by: Sunil Kumar Heggodu Gopala Acharya +Reviewed-by: Sunny Kumar +--- + tests/00-geo-rep/bug-1600145.t | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tests/00-geo-rep/bug-1600145.t b/tests/00-geo-rep/bug-1600145.t +index 1d38bf9..359bc4f 100644 +--- a/tests/00-geo-rep/bug-1600145.t ++++ b/tests/00-geo-rep/bug-1600145.t +@@ -29,7 +29,7 @@ slave_mnt=$M1 + + ##create_and_start_master_volume + TEST $CLI volume create $GMV0 replica 2 $H0:$B0/${GMV0}{1,2}; +-gluster v set all cluster.brick-multiplex on ++yes | gluster v set all cluster.brick-multiplex on + TEST $CLI volume start $GMV0 + + ##create_and_start_slave_volume +-- +1.8.3.1 + diff --git a/0042-spec-client-server-Builds-are-failing-on-rhel-6.patch b/0042-spec-client-server-Builds-are-failing-on-rhel-6.patch new file mode 100644 index 0000000..7e3d69f --- /dev/null +++ b/0042-spec-client-server-Builds-are-failing-on-rhel-6.patch @@ -0,0 +1,123 @@ +From f25a92028ecc2018953a6375bba43a21d3a93566 Mon Sep 17 00:00:00 2001 +From: Mohit Agrawal +Date: Thu, 4 Apr 2019 16:18:51 +0530 +Subject: [PATCH 42/52] spec: (client|server) Builds are failing on rhel-6 + +Problem: 1) For sever-rpm gluster build is throwing an error + undefined reference to `dlcose` on RHEL 6 + 2) For server-rpm build is throwing reference for + For Not found for rot-13.so and symlink-cache.so + 3) For client-rpms build is throwing an error + File Not found for all files with exclude + file in without_server check + +Solution: 1) For server-rpm add LIB_DL link in Makefile + and remove reference for rot.so and symlink-cache.so + from glusterfs.spec.in + 2) Remove exclude files list as they are not + being build + +Label: DOWNSTREAM ONLY +Change-Id: I2b41604cbc8525b91231b0c5caee588c5d5d6b08 +Signed-off-by: Mohit Agrawal +Reviewed-on: https://code.engineering.redhat.com/gerrit/166962 +Tested-by: RHGS Build Bot +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +--- + glusterfs.spec.in | 54 ----------------------------------- + xlators/mgmt/glusterd/src/Makefile.am | 2 +- + 2 files changed, 1 insertion(+), 55 deletions(-) + +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index df8d116..7c7f7c0 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -1097,72 +1097,18 @@ exit 0 + %{_tmpfilesdir}/gluster.conf + %endif + %if ( 0%{?_without_extra_xlators:1} ) +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/encryption/rot-13.so + %exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/quiesce.so + %exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/playground/template.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/testing/performance/symlink-cache.so + %endif + %if ( 0%{?_without_regression_tests:1} ) + %exclude %{_datadir}/glusterfs/run-tests.sh + %exclude %{_datadir}/glusterfs/tests + %endif + %if 0%{?_without_server:1} +-%exclude %{_sysconfdir}/glusterfs/gluster-rsyslog-5.8.conf +-%exclude %{_sysconfdir}/glusterfs/gluster-rsyslog-7.2.conf +-%exclude %{_sysconfdir}/glusterfs/glusterd.vol +-%exclude %{_sysconfdir}/glusterfs/glusterfs-georep-logrotate +-%exclude %{_sysconfdir}/glusterfs/glusterfs-logrotate +-%exclude %{_sysconfdir}/glusterfs/group-db-workload +-%exclude %{_sysconfdir}/glusterfs/group-distributed-virt +-%exclude %{_sysconfdir}/glusterfs/group-gluster-block +-%exclude %{_sysconfdir}/glusterfs/group-metadata-cache +-%exclude %{_sysconfdir}/glusterfs/group-nl-cache +-%exclude %{_sysconfdir}/glusterfs/group-virt.example +-%exclude %{_sysconfdir}/glusterfs/logger.conf.example +-%exclude %{_sysconfdir}/rsyslog.d/gluster.conf.example +-%exclude %{_prefix}/bin/glusterfind +-%exclude %{_prefix}/lib/firewalld/services/glusterfs.xml +-%exclude %{_prefix}/lib/systemd/system/glusterd.service +-%exclude %{_prefix}/lib/systemd/system/glusterfssharedstorage.service +-%exclude %{_prefix}/lib/tmpfiles.d/gluster.conf +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/arbiter.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/bit-rot.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/bitrot-stub.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/index.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/leases.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/locks.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/marker.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/posix-locks.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/quota.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/quotad.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/sdfs.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/selinux.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/snapview-server.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/thin-arbiter.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/trash.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/upcall.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/mgmt/glusterd.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/performance/decompounder.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/protocol/server.so +-%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/storage/posix.so +-%exclude %{_libexecdir}/glusterfs/* +-%exclude %{_sbindir}/conf.py +-%exclude %{_sbindir}/gcron.py +-%exclude %{_sbindir}/gf_attach +-%exclude %{_sbindir}/gfind_missing_files +-%exclude %{_sbindir}/glfsheal +-%exclude %{_sbindir}/gluster +-%exclude %{_sbindir}/gluster-setgfid2path +-%exclude %{_sbindir}/glusterd +-%exclude %{_sbindir}/snap_scheduler.py + %if ( 0%{?_with_systemd:1} ) + %exclude %{_datadir}/glusterfs/scripts/control-cpu-load.sh + %exclude %{_datadir}/glusterfs/scripts/control-mem.sh + %endif +-%exclude %{_datadir}/glusterfs/scripts/post-upgrade-script-for-quota.sh +-%exclude %{_datadir}/glusterfs/scripts/pre-upgrade-script-for-quota.sh +-%exclude %{_datadir}/glusterfs/scripts/stop-all-gluster-processes.sh +-%exclude %{_sharedstatedir}/glusterd/* + %endif + + %files api +diff --git a/xlators/mgmt/glusterd/src/Makefile.am b/xlators/mgmt/glusterd/src/Makefile.am +index 6d09e37..c8dd8e3 100644 +--- a/xlators/mgmt/glusterd/src/Makefile.am ++++ b/xlators/mgmt/glusterd/src/Makefile.am +@@ -6,7 +6,7 @@ xlatordir = $(libdir)/glusterfs/$(PACKAGE_VERSION)/xlator/mgmt + glusterd_la_CPPFLAGS = $(AM_CPPFLAGS) \ + -DFILTERDIR=\"$(libdir)/glusterfs/$(PACKAGE_VERSION)/filter\" \ + -DXLATORDIR=\"$(libdir)/glusterfs/$(PACKAGE_VERSION)/xlator\" +-glusterd_la_LDFLAGS = -module $(GF_XLATOR_DEFAULT_LDFLAGS) ++glusterd_la_LDFLAGS = -module $(GF_XLATOR_DEFAULT_LDFLAGS) $(LIB_DL) + glusterd_la_SOURCES = glusterd.c glusterd-handler.c glusterd-sm.c \ + glusterd-op-sm.c glusterd-utils.c glusterd-rpc-ops.c \ + glusterd-store.c glusterd-handshake.c glusterd-pmap.c \ +-- +1.8.3.1 + diff --git a/0043-inode-don-t-dump-the-whole-table-to-CLI.patch b/0043-inode-don-t-dump-the-whole-table-to-CLI.patch new file mode 100644 index 0000000..7e9d3c3 --- /dev/null +++ b/0043-inode-don-t-dump-the-whole-table-to-CLI.patch @@ -0,0 +1,137 @@ +From 416dfc70ef87400e1ddfd70e5b6e512d330b54a6 Mon Sep 17 00:00:00 2001 +From: Sheetal Pamecha +Date: Tue, 2 Apr 2019 23:25:11 +0530 +Subject: [PATCH 43/52] inode: don't dump the whole table to CLI + +dumping the whole inode table detail to screen doesn't solve any +purpose. We should be getting only toplevel details on CLI, and +then if one wants to debug further, then they need to get to +'statedump' to get full details. + +Patch on upstream master: https://review.gluster.org/#/c/glusterfs/+/22347/ + +BUG: 1578703 +Change-Id: Ie7e7f5a67c1606e3c18ce21ee6df6c7e4550c211 +Signed-off-by: Sheetal Pamecha +Reviewed-on: https://code.engineering.redhat.com/gerrit/166768 +Tested-by: RHGS Build Bot +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +--- + cli/src/cli-rpc-ops.c | 23 ++++++++++++++++++++++- + libglusterfs/src/inode.c | 13 +++++++++++++ + 2 files changed, 35 insertions(+), 1 deletion(-) + +diff --git a/cli/src/cli-rpc-ops.c b/cli/src/cli-rpc-ops.c +index 78043cd..12e7fcc 100644 +--- a/cli/src/cli-rpc-ops.c ++++ b/cli/src/cli-rpc-ops.c +@@ -7606,15 +7606,24 @@ cli_print_volume_status_itables(dict_t *dict, char *prefix) + uint32_t active_size = 0; + uint32_t lru_size = 0; + uint32_t purge_size = 0; ++ uint32_t lru_limit = 0; + int i = 0; + + GF_ASSERT(dict); + GF_ASSERT(prefix); + ++ snprintf(key, sizeof(key), "%s.lru_limit", prefix); ++ ret = dict_get_uint32(dict, key, &lru_limit); ++ if (ret) ++ goto out; ++ cli_out("LRU limit : %u", lru_limit); ++ + snprintf(key, sizeof(key), "%s.active_size", prefix); + ret = dict_get_uint32(dict, key, &active_size); + if (ret) + goto out; ++ ++#ifdef DEBUG + if (active_size != 0) { + cli_out("Active inodes:"); + cli_out("%-40s %14s %14s %9s", "GFID", "Lookups", "Ref", "IA type"); +@@ -7626,10 +7635,16 @@ cli_print_volume_status_itables(dict_t *dict, char *prefix) + } + cli_out(" "); + ++#else ++ cli_out("Active Inodes : %u", active_size); ++ ++#endif + snprintf(key, sizeof(key), "%s.lru_size", prefix); + ret = dict_get_uint32(dict, key, &lru_size); + if (ret) + goto out; ++ ++#ifdef DEBUG + if (lru_size != 0) { + cli_out("LRU inodes:"); + cli_out("%-40s %14s %14s %9s", "GFID", "Lookups", "Ref", "IA type"); +@@ -7640,11 +7655,15 @@ cli_print_volume_status_itables(dict_t *dict, char *prefix) + cli_print_volume_status_inode_entry(dict, key); + } + cli_out(" "); ++#else ++ cli_out("LRU Inodes : %u", lru_size); ++#endif + + snprintf(key, sizeof(key), "%s.purge_size", prefix); + ret = dict_get_uint32(dict, key, &purge_size); + if (ret) + goto out; ++#ifdef DEBUG + if (purge_size != 0) { + cli_out("Purged inodes:"); + cli_out("%-40s %14s %14s %9s", "GFID", "Lookups", "Ref", "IA type"); +@@ -7654,7 +7673,9 @@ cli_print_volume_status_itables(dict_t *dict, char *prefix) + snprintf(key, sizeof(key), "%s.purge%d", prefix, i); + cli_print_volume_status_inode_entry(dict, key); + } +- ++#else ++ cli_out("Purge Inodes : %u", purge_size); ++#endif + out: + return; + } +diff --git a/libglusterfs/src/inode.c b/libglusterfs/src/inode.c +index 87f74e0..96ddea5 100644 +--- a/libglusterfs/src/inode.c ++++ b/libglusterfs/src/inode.c +@@ -2598,6 +2598,11 @@ inode_table_dump_to_dict(inode_table_t *itable, char *prefix, dict_t *dict) + if (ret) + return; + ++ snprintf(key, sizeof(key), "%s.itable.lru_limit", prefix); ++ ret = dict_set_uint32(dict, key, itable->lru_limit); ++ if (ret) ++ goto out; ++ + snprintf(key, sizeof(key), "%s.itable.active_size", prefix); + ret = dict_set_uint32(dict, key, itable->active_size); + if (ret) +@@ -2613,6 +2618,13 @@ inode_table_dump_to_dict(inode_table_t *itable, char *prefix, dict_t *dict) + if (ret) + goto out; + ++#ifdef DEBUG ++ /* Dumping inode details in dictionary and sending it to CLI is not ++ required as when a developer (or support team) asks for this command ++ output, they just want to get top level detail of inode table. ++ If one wants to debug, let them take statedump and debug, this ++ wouldn't be available in CLI during production setup. ++ */ + list_for_each_entry(inode, &itable->active, list) + { + snprintf(key, sizeof(key), "%s.itable.active%d", prefix, count++); +@@ -2632,6 +2644,7 @@ inode_table_dump_to_dict(inode_table_t *itable, char *prefix, dict_t *dict) + snprintf(key, sizeof(key), "%s.itable.purge%d", prefix, count++); + inode_dump_to_dict(inode, key, dict); + } ++#endif + + out: + pthread_mutex_unlock(&itable->lock); +-- +1.8.3.1 + diff --git a/0044-cluster-ec-Don-t-enqueue-an-entry-if-it-is-already-h.patch b/0044-cluster-ec-Don-t-enqueue-an-entry-if-it-is-already-h.patch new file mode 100644 index 0000000..30ab28b --- /dev/null +++ b/0044-cluster-ec-Don-t-enqueue-an-entry-if-it-is-already-h.patch @@ -0,0 +1,360 @@ +From bc6588890ce94101a63b861178cf38db5549d8a8 Mon Sep 17 00:00:00 2001 +From: Ashish Pandey +Date: Wed, 28 Nov 2018 11:22:52 +0530 +Subject: [PATCH 44/52] cluster/ec: Don't enqueue an entry if it is already + healing + +Problem: +1 - heal-wait-qlength is by default 128. If shd is disabled +and we need to heal files, client side heal is needed. +If we access these files that will trigger the heal. +However, it has been observed that a file will be enqueued +multiple times in the heal wait queue, which in turn causes +queue to be filled and prevent other files to be enqueued. + +2 - While a file is going through healing and a write fop from +mount comes on that file, it sends write on all the bricks including +healing one. At the end it updates version and size on all the +bricks. However, it does not unset dirty flag on all the bricks, +even if this write fop was successful on all the bricks. +After healing completion this dirty flag remain set and never +gets cleaned up if SHD is disabled. + +Solution: +1 - If an entry is already in queue or going through heal process, +don't enqueue next client side request to heal the same file. + +2 - Unset dirty on all the bricks at the end if fop has succeeded on +all the bricks even if some of the bricks are going through heal. + +backport of : https://review.gluster.org/#/c/glusterfs/+/21744/ + +Change-Id: Ia61ffe230c6502ce6cb934425d55e2f40dd1a727 +BUG: 1600918 +Signed-off-by: Ashish Pandey +Reviewed-on: https://code.engineering.redhat.com/gerrit/166296 +Tested-by: RHGS Build Bot +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +--- + tests/bugs/ec/bug-1236065.t | 1 - + xlators/cluster/ec/src/ec-common.c | 43 +++++++++------ + xlators/cluster/ec/src/ec-common.h | 8 +++ + xlators/cluster/ec/src/ec-heal.c | 104 +++++++++++++++++++++++++++++++----- + xlators/cluster/ec/src/ec-helpers.c | 1 + + xlators/cluster/ec/src/ec-types.h | 1 + + 6 files changed, 127 insertions(+), 31 deletions(-) + +diff --git a/tests/bugs/ec/bug-1236065.t b/tests/bugs/ec/bug-1236065.t +index 76d25d7..9181e73 100644 +--- a/tests/bugs/ec/bug-1236065.t ++++ b/tests/bugs/ec/bug-1236065.t +@@ -85,7 +85,6 @@ TEST pidof glusterd + EXPECT "$V0" volinfo_field $V0 'Volume Name' + EXPECT 'Started' volinfo_field $V0 'Status' + EXPECT '7' online_brick_count +- + ## cleanup + cd + EXPECT_WITHIN $UMOUNT_TIMEOUT "Y" force_umount $M0 +diff --git a/xlators/cluster/ec/src/ec-common.c b/xlators/cluster/ec/src/ec-common.c +index 8d65670..5183680 100644 +--- a/xlators/cluster/ec/src/ec-common.c ++++ b/xlators/cluster/ec/src/ec-common.c +@@ -313,14 +313,15 @@ ec_check_status(ec_fop_data_t *fop) + + gf_msg(fop->xl->name, GF_LOG_WARNING, 0, EC_MSG_OP_FAIL_ON_SUBVOLS, + "Operation failed on %d of %d subvolumes.(up=%s, mask=%s, " +- "remaining=%s, good=%s, bad=%s)", ++ "remaining=%s, good=%s, bad=%s, %s)", + gf_bits_count(ec->xl_up & ~(fop->remaining | fop->good)), ec->nodes, + ec_bin(str1, sizeof(str1), ec->xl_up, ec->nodes), + ec_bin(str2, sizeof(str2), fop->mask, ec->nodes), + ec_bin(str3, sizeof(str3), fop->remaining, ec->nodes), + ec_bin(str4, sizeof(str4), fop->good, ec->nodes), + ec_bin(str5, sizeof(str5), ec->xl_up & ~(fop->remaining | fop->good), +- ec->nodes)); ++ ec->nodes), ++ ec_msg_str(fop)); + if (fop->use_fd) { + if (fop->fd != NULL) { + ec_fheal(NULL, fop->xl, -1, EC_MINIMUM_ONE, ec_heal_report, NULL, +@@ -2371,37 +2372,47 @@ ec_update_info(ec_lock_link_t *link) + uint64_t dirty[2] = {0, 0}; + uint64_t size; + ec_t *ec = NULL; ++ uintptr_t mask; + + lock = link->lock; + ctx = lock->ctx; + ec = link->fop->xl->private; + + /* pre_version[*] will be 0 if have_version is false */ +- version[0] = ctx->post_version[0] - ctx->pre_version[0]; +- version[1] = ctx->post_version[1] - ctx->pre_version[1]; ++ version[EC_DATA_TXN] = ctx->post_version[EC_DATA_TXN] - ++ ctx->pre_version[EC_DATA_TXN]; ++ version[EC_METADATA_TXN] = ctx->post_version[EC_METADATA_TXN] - ++ ctx->pre_version[EC_METADATA_TXN]; + + size = ctx->post_size - ctx->pre_size; + /* If we set the dirty flag for update fop, we have to unset it. + * If fop has failed on some bricks, leave the dirty as marked. */ ++ + if (lock->unlock_now) { ++ if (version[EC_DATA_TXN]) { ++ /*A data fop will have difference in post and pre version ++ *and for data fop we send writes on healing bricks also */ ++ mask = lock->good_mask | lock->healing; ++ } else { ++ mask = lock->good_mask; ++ } + /* Ensure that nodes are up while doing final + * metadata update.*/ +- if (!(ec->node_mask & ~lock->good_mask) && +- !(ec->node_mask & ~ec->xl_up)) { +- if (ctx->dirty[0] != 0) { +- dirty[0] = -1; ++ if (!(ec->node_mask & ~(mask)) && !(ec->node_mask & ~ec->xl_up)) { ++ if (ctx->dirty[EC_DATA_TXN] != 0) { ++ dirty[EC_DATA_TXN] = -1; + } +- if (ctx->dirty[1] != 0) { +- dirty[1] = -1; ++ if (ctx->dirty[EC_METADATA_TXN] != 0) { ++ dirty[EC_METADATA_TXN] = -1; + } + /*If everything is fine and we already + *have version xattr set on entry, there + *is no need to update version again*/ +- if (ctx->pre_version[0]) { +- version[0] = 0; ++ if (ctx->pre_version[EC_DATA_TXN]) { ++ version[EC_DATA_TXN] = 0; + } +- if (ctx->pre_version[1]) { +- version[1] = 0; ++ if (ctx->pre_version[EC_METADATA_TXN]) { ++ version[EC_METADATA_TXN] = 0; + } + } else { + link->optimistic_changelog = _gf_false; +@@ -2410,8 +2421,8 @@ ec_update_info(ec_lock_link_t *link) + memset(ctx->dirty, 0, sizeof(ctx->dirty)); + } + +- if ((version[0] != 0) || (version[1] != 0) || (dirty[0] != 0) || +- (dirty[1] != 0)) { ++ if ((version[EC_DATA_TXN] != 0) || (version[EC_METADATA_TXN] != 0) || ++ (dirty[EC_DATA_TXN] != 0) || (dirty[EC_METADATA_TXN] != 0)) { + ec_update_size_version(link, version, size, dirty); + return _gf_true; + } +diff --git a/xlators/cluster/ec/src/ec-common.h b/xlators/cluster/ec/src/ec-common.h +index 115e147..54aaa77 100644 +--- a/xlators/cluster/ec/src/ec-common.h ++++ b/xlators/cluster/ec/src/ec-common.h +@@ -190,4 +190,12 @@ ec_lock_unlocked(call_frame_t *frame, void *cookie, xlator_t *this, + void + ec_update_fd_status(fd_t *fd, xlator_t *xl, int child_index, + int32_t ret_status); ++gf_boolean_t ++ec_is_entry_healing(ec_fop_data_t *fop); ++void ++ec_set_entry_healing(ec_fop_data_t *fop); ++void ++ec_reset_entry_healing(ec_fop_data_t *fop); ++char * ++ec_msg_str(ec_fop_data_t *fop); + #endif /* __EC_COMMON_H__ */ +diff --git a/xlators/cluster/ec/src/ec-heal.c b/xlators/cluster/ec/src/ec-heal.c +index eaf80e0..1ca12c1 100644 +--- a/xlators/cluster/ec/src/ec-heal.c ++++ b/xlators/cluster/ec/src/ec-heal.c +@@ -103,6 +103,48 @@ ec_sh_key_match(dict_t *dict, char *key, data_t *val, void *mdata) + } + /* FOP: heal */ + ++void ++ec_set_entry_healing(ec_fop_data_t *fop) ++{ ++ ec_inode_t *ctx = NULL; ++ loc_t *loc = NULL; ++ ++ if (!fop) ++ return; ++ ++ loc = &fop->loc[0]; ++ LOCK(&loc->inode->lock); ++ { ++ ctx = __ec_inode_get(loc->inode, fop->xl); ++ if (ctx) { ++ ctx->heal_count += 1; ++ } ++ } ++ UNLOCK(&loc->inode->lock); ++} ++ ++void ++ec_reset_entry_healing(ec_fop_data_t *fop) ++{ ++ ec_inode_t *ctx = NULL; ++ loc_t *loc = NULL; ++ int32_t heal_count = 0; ++ if (!fop) ++ return; ++ ++ loc = &fop->loc[0]; ++ LOCK(&loc->inode->lock); ++ { ++ ctx = __ec_inode_get(loc->inode, fop->xl); ++ if (ctx) { ++ ctx->heal_count += -1; ++ heal_count = ctx->heal_count; ++ } ++ } ++ UNLOCK(&loc->inode->lock); ++ GF_ASSERT(heal_count >= 0); ++} ++ + uintptr_t + ec_heal_check(ec_fop_data_t *fop, uintptr_t *pgood) + { +@@ -2507,17 +2549,6 @@ ec_heal_do(xlator_t *this, void *data, loc_t *loc, int32_t partial) + "Heal is not required for : %s ", uuid_utoa(loc->gfid)); + goto out; + } +- +- msources = alloca0(ec->nodes); +- mhealed_sinks = alloca0(ec->nodes); +- ret = ec_heal_metadata(frame, ec, loc->inode, msources, mhealed_sinks); +- if (ret == 0) { +- mgood = ec_char_array_to_mask(msources, ec->nodes); +- mbad = ec_char_array_to_mask(mhealed_sinks, ec->nodes); +- } else { +- op_ret = -1; +- op_errno = -ret; +- } + sources = alloca0(ec->nodes); + healed_sinks = alloca0(ec->nodes); + if (IA_ISREG(loc->inode->ia_type)) { +@@ -2538,8 +2569,19 @@ ec_heal_do(xlator_t *this, void *data, loc_t *loc, int32_t partial) + op_ret = -1; + op_errno = -ret; + } ++ msources = alloca0(ec->nodes); ++ mhealed_sinks = alloca0(ec->nodes); ++ ret = ec_heal_metadata(frame, ec, loc->inode, msources, mhealed_sinks); ++ if (ret == 0) { ++ mgood = ec_char_array_to_mask(msources, ec->nodes); ++ mbad = ec_char_array_to_mask(mhealed_sinks, ec->nodes); ++ } else { ++ op_ret = -1; ++ op_errno = -ret; ++ } + + out: ++ ec_reset_entry_healing(fop); + if (fop->cbks.heal) { + fop->cbks.heal(fop->req_frame, fop, fop->xl, op_ret, op_errno, + ec_char_array_to_mask(participants, ec->nodes), +@@ -2650,11 +2692,33 @@ ec_handle_healers_done(ec_fop_data_t *fop) + ec_launch_heal(ec, heal_fop); + } + ++gf_boolean_t ++ec_is_entry_healing(ec_fop_data_t *fop) ++{ ++ ec_inode_t *ctx = NULL; ++ int32_t heal_count = 0; ++ loc_t *loc = NULL; ++ ++ loc = &fop->loc[0]; ++ ++ LOCK(&loc->inode->lock); ++ { ++ ctx = __ec_inode_get(loc->inode, fop->xl); ++ if (ctx) { ++ heal_count = ctx->heal_count; ++ } ++ } ++ UNLOCK(&loc->inode->lock); ++ GF_ASSERT(heal_count >= 0); ++ return heal_count; ++} ++ + void + ec_heal_throttle(xlator_t *this, ec_fop_data_t *fop) + { + gf_boolean_t can_heal = _gf_true; + ec_t *ec = this->private; ++ ec_fop_data_t *fop_rel = NULL; + + if (fop->req_frame == NULL) { + LOCK(&ec->lock); +@@ -2662,8 +2726,13 @@ ec_heal_throttle(xlator_t *this, ec_fop_data_t *fop) + if ((ec->background_heals > 0) && + (ec->heal_wait_qlen + ec->background_heals) > + (ec->heal_waiters + ec->healers)) { +- list_add_tail(&fop->healer, &ec->heal_waiting); +- ec->heal_waiters++; ++ if (!ec_is_entry_healing(fop)) { ++ list_add_tail(&fop->healer, &ec->heal_waiting); ++ ec->heal_waiters++; ++ ec_set_entry_healing(fop); ++ } else { ++ fop_rel = fop; ++ } + fop = __ec_dequeue_heals(ec); + } else { + can_heal = _gf_false; +@@ -2673,8 +2742,12 @@ ec_heal_throttle(xlator_t *this, ec_fop_data_t *fop) + } + + if (can_heal) { +- if (fop) ++ if (fop) { ++ if (fop->req_frame != NULL) { ++ ec_set_entry_healing(fop); ++ } + ec_launch_heal(ec, fop); ++ } + } else { + gf_msg_debug(this->name, 0, + "Max number of heals are " +@@ -2682,6 +2755,9 @@ ec_heal_throttle(xlator_t *this, ec_fop_data_t *fop) + ec_fop_set_error(fop, EBUSY); + ec_heal_fail(ec, fop); + } ++ if (fop_rel) { ++ ec_heal_done(0, NULL, fop_rel); ++ } + } + + void +diff --git a/xlators/cluster/ec/src/ec-helpers.c b/xlators/cluster/ec/src/ec-helpers.c +index e6b0359..43f6e3b 100644 +--- a/xlators/cluster/ec/src/ec-helpers.c ++++ b/xlators/cluster/ec/src/ec-helpers.c +@@ -717,6 +717,7 @@ __ec_inode_get(inode_t *inode, xlator_t *xl) + memset(ctx, 0, sizeof(*ctx)); + INIT_LIST_HEAD(&ctx->heal); + INIT_LIST_HEAD(&ctx->stripe_cache.lru); ++ ctx->heal_count = 0; + value = (uint64_t)(uintptr_t)ctx; + if (__inode_ctx_set(inode, xl, &value) != 0) { + GF_FREE(ctx); +diff --git a/xlators/cluster/ec/src/ec-types.h b/xlators/cluster/ec/src/ec-types.h +index f3d63ca..6ae4a2b 100644 +--- a/xlators/cluster/ec/src/ec-types.h ++++ b/xlators/cluster/ec/src/ec-types.h +@@ -171,6 +171,7 @@ struct _ec_inode { + gf_boolean_t have_config; + gf_boolean_t have_version; + gf_boolean_t have_size; ++ int32_t heal_count; + ec_config_t config; + uint64_t pre_version[2]; + uint64_t post_version[2]; +-- +1.8.3.1 + diff --git a/0045-glusterd-fix-txn-id-mem-leak.patch b/0045-glusterd-fix-txn-id-mem-leak.patch new file mode 100644 index 0000000..b9b2b3e --- /dev/null +++ b/0045-glusterd-fix-txn-id-mem-leak.patch @@ -0,0 +1,126 @@ +From 6c004c6c8b8f98f56e186740881520b8364e6f85 Mon Sep 17 00:00:00 2001 +From: Atin Mukherjee +Date: Mon, 18 Mar 2019 16:08:04 +0530 +Subject: [PATCH 45/52] glusterd: fix txn-id mem leak + +This commit ensures the following: +1. Don't send commit op request to the remote nodes when gluster v +status all is executed as for the status all transaction the local +commit gets the name of the volumes and remote commit ops are +technically a no-op. So no need for additional rpc requests. +2. In op state machine flow, if the transaction is in staged state and +op_info.skip_locking is true, then no need to set the txn id in the +priv->glusterd_txn_opinfo dictionary which never gets freed. + +> Fixes: bz#1691164 +> Change-Id: Ib6a9300ea29633f501abac2ba53fb72ff648c822 +> Signed-off-by: Atin Mukherjee + +upstream patch: https://review.gluster.org/#/c/glusterfs/+/22388/ + +BUG: 1670415 +Change-Id: Ib6a9300ea29633f501abac2ba53fb72ff648c822 +Signed-off-by: Sanju Rakonde +Reviewed-on: https://code.engineering.redhat.com/gerrit/166449 +Tested-by: RHGS Build Bot +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +--- + xlators/mgmt/glusterd/src/glusterd-op-sm.c | 26 ++++++++++++++++++++------ + xlators/mgmt/glusterd/src/glusterd-syncop.c | 16 ++++++++++++++++ + 2 files changed, 36 insertions(+), 6 deletions(-) + +diff --git a/xlators/mgmt/glusterd/src/glusterd-op-sm.c b/xlators/mgmt/glusterd/src/glusterd-op-sm.c +index cbbb5d9..12d857a 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-op-sm.c ++++ b/xlators/mgmt/glusterd/src/glusterd-op-sm.c +@@ -5652,6 +5652,9 @@ glusterd_op_ac_stage_op(glusterd_op_sm_event_t *event, void *ctx) + dict_t *dict = NULL; + xlator_t *this = NULL; + uuid_t *txn_id = NULL; ++ glusterd_op_info_t txn_op_info = { ++ {0}, ++ }; + + this = THIS; + GF_ASSERT(this); +@@ -5686,6 +5689,7 @@ glusterd_op_ac_stage_op(glusterd_op_sm_event_t *event, void *ctx) + ret = -1; + goto out; + } ++ ret = glusterd_get_txn_opinfo(&event->txn_id, &txn_op_info); + + ret = dict_set_bin(rsp_dict, "transaction_id", txn_id, sizeof(*txn_id)); + if (ret) { +@@ -5704,6 +5708,12 @@ out: + + gf_msg_debug(this->name, 0, "Returning with %d", ret); + ++ /* for no volname transactions, the txn_opinfo needs to be cleaned up ++ * as there's no unlock event triggered ++ */ ++ if (txn_op_info.skip_locking) ++ ret = glusterd_clear_txn_opinfo(txn_id); ++ + if (rsp_dict) + dict_unref(rsp_dict); + +@@ -8159,12 +8169,16 @@ glusterd_op_sm() + "Unable to clear " + "transaction's opinfo"); + } else { +- ret = glusterd_set_txn_opinfo(&event->txn_id, &opinfo); +- if (ret) +- gf_msg(this->name, GF_LOG_ERROR, 0, +- GD_MSG_TRANS_OPINFO_SET_FAIL, +- "Unable to set " +- "transaction's opinfo"); ++ if (!(event_type == GD_OP_EVENT_STAGE_OP && ++ opinfo.state.state == GD_OP_STATE_STAGED && ++ opinfo.skip_locking)) { ++ ret = glusterd_set_txn_opinfo(&event->txn_id, &opinfo); ++ if (ret) ++ gf_msg(this->name, GF_LOG_ERROR, 0, ++ GD_MSG_TRANS_OPINFO_SET_FAIL, ++ "Unable to set " ++ "transaction's opinfo"); ++ } + } + + glusterd_destroy_op_event_ctx(event); +diff --git a/xlators/mgmt/glusterd/src/glusterd-syncop.c b/xlators/mgmt/glusterd/src/glusterd-syncop.c +index 1741cf8..618d8bc 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-syncop.c ++++ b/xlators/mgmt/glusterd/src/glusterd-syncop.c +@@ -1392,6 +1392,8 @@ gd_commit_op_phase(glusterd_op_t op, dict_t *op_ctx, dict_t *req_dict, + char *errstr = NULL; + struct syncargs args = {0}; + int type = GF_QUOTA_OPTION_TYPE_NONE; ++ uint32_t cmd = 0; ++ gf_boolean_t origin_glusterd = _gf_false; + + this = THIS; + GF_ASSERT(this); +@@ -1449,6 +1451,20 @@ commit_done: + gd_syncargs_init(&args, op_ctx); + synctask_barrier_init((&args)); + peer_cnt = 0; ++ origin_glusterd = is_origin_glusterd(req_dict); ++ ++ if (op == GD_OP_STATUS_VOLUME) { ++ ret = dict_get_uint32(req_dict, "cmd", &cmd); ++ if (ret) ++ goto out; ++ ++ if (origin_glusterd) { ++ if ((cmd & GF_CLI_STATUS_ALL)) { ++ ret = 0; ++ goto out; ++ } ++ } ++ } + + RCU_READ_LOCK; + cds_list_for_each_entry_rcu(peerinfo, &conf->peers, uuid_list) +-- +1.8.3.1 + diff --git a/0046-protocol-client-Do-not-fallback-to-anon-fd-if-fd-is-.patch b/0046-protocol-client-Do-not-fallback-to-anon-fd-if-fd-is-.patch new file mode 100644 index 0000000..5365515 --- /dev/null +++ b/0046-protocol-client-Do-not-fallback-to-anon-fd-if-fd-is-.patch @@ -0,0 +1,98 @@ +From a0661449cd8ba7b851fec473191733767f4541b8 Mon Sep 17 00:00:00 2001 +From: Pranith Kumar K +Date: Thu, 28 Mar 2019 17:55:54 +0530 +Subject: [PATCH 46/52] protocol/client: Do not fallback to anon-fd if fd is + not open + +If an open comes on a file when a brick is down and after the brick comes up, +a fop comes on the fd, client xlator would still wind the fop on anon-fd +leading to wrong behavior of the fops in some cases. + +Example: +If lk fop is issued on the fd just after the brick is up in the scenario above, +lk fop will be sent on anon-fd instead of failing it on that client xlator. +This lock will never be freed upon close of the fd as flush on anon-fd is +invalid and is not wound below server xlator. + +As a fix, failing the fop unless the fd has FALLBACK_TO_ANON_FD flag. + + >Upstream-patch: https://review.gluster.org/c/glusterfs/+/15804 + >Change-Id: I77692d056660b2858e323bdabdfe0a381807cccc + >fixes bz#1390914 + +BUG: 1695057 +Change-Id: Id656bea8dde14327212fbe7ecc97519dc5b32098 +Signed-off-by: Pranith Kumar K +Reviewed-on: https://code.engineering.redhat.com/gerrit/166833 +Tested-by: RHGS Build Bot +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +--- + tests/bugs/protocol/bug-1390914.t | 36 ++++++++++++++++++++++++++++ + xlators/protocol/client/src/client-helpers.c | 8 ++++++- + 2 files changed, 43 insertions(+), 1 deletion(-) + create mode 100644 tests/bugs/protocol/bug-1390914.t + +diff --git a/tests/bugs/protocol/bug-1390914.t b/tests/bugs/protocol/bug-1390914.t +new file mode 100644 +index 0000000..e3dab92 +--- /dev/null ++++ b/tests/bugs/protocol/bug-1390914.t +@@ -0,0 +1,36 @@ ++#!/bin/bash ++ ++. $(dirname $0)/../../include.rc ++. $(dirname $0)/../../volume.rc ++. $(dirname $0)/../../fileio.rc ++cleanup; ++ ++#test that fops are not wound on anon-fd when fd is not open on that brick ++TEST glusterd; ++TEST pidof glusterd ++ ++TEST $CLI volume create $V0 replica 3 $H0:$B0/${V0}{1,2,3}; ++TEST $CLI volume set $V0 performance.open-behind off ++TEST $CLI volume set $V0 diagnostics.client-log-level DEBUG ++TEST $CLI volume heal $V0 disable ++TEST $CLI volume start $V0 ++TEST $CLI volume profile $V0 start ++TEST $GFS -s $H0 --volfile-id=$V0 --direct-io-mode=enable $M0; ++ ++TEST touch $M0/1 ++TEST kill_brick $V0 $H0 $B0/${V0}1 ++TEST fd_open 200 'w' "$M0/1" ++TEST $CLI volume start $V0 force ++EXPECT_WITHIN $PROCESS_UP_TIMEOUT "1" afr_child_up_status $V0 0 ++ ++#lk should only happen on 2 bricks, if there is a bug, it will plant a lock ++#with anon-fd on first-brick which will never be released because flush won't ++#be wound below server xlator for anon-fd ++TEST flock -x -n 200 ++TEST fd_close 200 ++ ++TEST fd_open 200 'w' "$M0/1" ++#this lock will fail if there is a stale lock ++TEST flock -x -n 200 ++TEST fd_close 200 ++cleanup; +diff --git a/xlators/protocol/client/src/client-helpers.c b/xlators/protocol/client/src/client-helpers.c +index 55e87b3..2dd7106 100644 +--- a/xlators/protocol/client/src/client-helpers.c ++++ b/xlators/protocol/client/src/client-helpers.c +@@ -419,7 +419,13 @@ client_get_remote_fd(xlator_t *this, fd_t *fd, int flags, int64_t *remote_fd) + { + fdctx = this_fd_get_ctx(fd, this); + if (!fdctx) { +- *remote_fd = GF_ANON_FD_NO; ++ if (fd->anonymous) { ++ *remote_fd = GF_ANON_FD_NO; ++ } else { ++ *remote_fd = -1; ++ gf_msg_debug(this->name, EBADF, "not a valid fd for gfid: %s", ++ uuid_utoa(fd->inode->gfid)); ++ } + } else { + if (__is_fd_reopen_in_progress(fdctx)) + *remote_fd = -1; +-- +1.8.3.1 + diff --git a/0047-client-rpc-Fix-the-payload-being-sent-on-the-wire.patch b/0047-client-rpc-Fix-the-payload-being-sent-on-the-wire.patch new file mode 100644 index 0000000..cc71864 --- /dev/null +++ b/0047-client-rpc-Fix-the-payload-being-sent-on-the-wire.patch @@ -0,0 +1,1652 @@ +From 83d816370f7540d4065baac704df65c648a03125 Mon Sep 17 00:00:00 2001 +From: Poornima G +Date: Sun, 24 Mar 2019 09:40:50 +0530 +Subject: [PATCH 47/52] client-rpc: Fix the payload being sent on the wire + +The fops allocate 3 kind of payload(buffer) in the client xlator: +- fop payload, this is the buffer allocated by the write and put fop +- rsphdr paylod, this is the buffer required by the reply cbk of + some fops like lookup, readdir. +- rsp_paylod, this is the buffer required by the reply cbk of fops like + readv etc. + +Currently, in the lookup and readdir fop the rsphdr is sent as payload, +hence the allocated rsphdr buffer is also sent on the wire, increasing +the bandwidth consumption on the wire. + +With this patch, the issue is fixed. + +>Fixes: bz#1692093 +>Change-Id: Ie8158921f4db319e60ad5f52d851fa5c9d4a269b +>Signed-off-by: Poornima G +>Backport-of: https://review.gluster.org/22402/ + +BUG: 1693935 +Change-Id: Id12746a4c9416288bc1387c8b018bbe9cc4b637d +Signed-off-by: Poornima G +Reviewed-on: https://code.engineering.redhat.com/gerrit/166535 +Tested-by: RHGS Build Bot +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +--- + xlators/protocol/client/src/client-handshake.c | 29 ++- + xlators/protocol/client/src/client-helpers.c | 14 +- + xlators/protocol/client/src/client-rpc-fops.c | 235 ++++++++++++---------- + xlators/protocol/client/src/client-rpc-fops_v2.c | 236 ++++++++++++----------- + xlators/protocol/client/src/client.c | 22 ++- + xlators/protocol/client/src/client.h | 16 +- + 6 files changed, 308 insertions(+), 244 deletions(-) + +diff --git a/xlators/protocol/client/src/client-handshake.c b/xlators/protocol/client/src/client-handshake.c +index f9631c5..c43756a 100644 +--- a/xlators/protocol/client/src/client-handshake.c ++++ b/xlators/protocol/client/src/client-handshake.c +@@ -34,7 +34,6 @@ typedef struct client_fd_lk_local { + clnt_fd_ctx_t *fdctx; + } clnt_fd_lk_local_t; + +- + int32_t + client3_getspec(call_frame_t *frame, xlator_t *this, void *data) + { +@@ -201,8 +200,8 @@ clnt_release_reopen_fd(xlator_t *this, clnt_fd_ctx_t *fdctx) + req.fd = fdctx->remote_fd; + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_RELEASE, +- clnt_release_reopen_fd_cbk, NULL, NULL, 0, NULL, +- 0, NULL, (xdrproc_t)xdr_gfs3_releasedir_req); ++ clnt_release_reopen_fd_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_releasedir_req); + out: + if (ret) { + clnt_fd_lk_reacquire_failed(this, fdctx, conf); +@@ -486,8 +485,8 @@ protocol_client_reopendir(clnt_fd_ctx_t *fdctx, xlator_t *this) + frame->local = local; + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_OPENDIR, +- client3_3_reopendir_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_opendir_req); ++ client3_3_reopendir_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_opendir_req); + if (ret) { + gf_msg(this->name, GF_LOG_ERROR, 0, PC_MSG_DIR_OP_FAILED, + "failed to send the re-opendir request"); +@@ -547,8 +546,8 @@ protocol_client_reopenfile(clnt_fd_ctx_t *fdctx, xlator_t *this) + local->loc.path); + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_OPEN, +- client3_3_reopen_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_open_req); ++ client3_3_reopen_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_open_req); + if (ret) { + gf_msg(this->name, GF_LOG_ERROR, 0, PC_MSG_DIR_OP_FAILED, + "failed to send the re-open request"); +@@ -745,8 +744,8 @@ protocol_client_reopendir_v2(clnt_fd_ctx_t *fdctx, xlator_t *this) + frame->local = local; + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_OPENDIR, +- client4_0_reopendir_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_opendir_req); ++ client4_0_reopendir_cbk, NULL, ++ (xdrproc_t)xdr_gfx_opendir_req); + if (ret) { + gf_msg(this->name, GF_LOG_ERROR, 0, PC_MSG_DIR_OP_FAILED, + "failed to send the re-opendir request"); +@@ -806,8 +805,8 @@ protocol_client_reopenfile_v2(clnt_fd_ctx_t *fdctx, xlator_t *this) + local->loc.path); + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_OPEN, +- client4_0_reopen_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_open_req); ++ client4_0_reopen_cbk, NULL, ++ (xdrproc_t)xdr_gfx_open_req); + if (ret) { + gf_msg(this->name, GF_LOG_ERROR, 0, PC_MSG_DIR_OP_FAILED, + "failed to send the re-open request"); +@@ -1312,7 +1311,6 @@ client_setvolume(xlator_t *this, struct rpc_clnt *rpc) + + ret = client_submit_request(this, &req, fr, conf->handshake, + GF_HNDSK_SETVOLUME, client_setvolume_cbk, NULL, +- NULL, 0, NULL, 0, NULL, + (xdrproc_t)xdr_gf_setvolume_req); + + fail: +@@ -1522,8 +1520,7 @@ client_query_portmap(xlator_t *this, struct rpc_clnt *rpc) + + ret = client_submit_request(this, &req, fr, &clnt_pmap_prog, + GF_PMAP_PORTBYBRICK, client_query_portmap_cbk, +- NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_pmap_port_by_brick_req); ++ NULL, (xdrproc_t)xdr_pmap_port_by_brick_req); + + fail: + return ret; +@@ -1624,8 +1621,8 @@ client_handshake(xlator_t *this, struct rpc_clnt *rpc) + + req.gfs_id = 0xbabe; + ret = client_submit_request(this, &req, frame, conf->dump, GF_DUMP_DUMP, +- client_dump_version_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gf_dump_req); ++ client_dump_version_cbk, NULL, ++ (xdrproc_t)xdr_gf_dump_req); + + out: + return ret; +diff --git a/xlators/protocol/client/src/client-helpers.c b/xlators/protocol/client/src/client-helpers.c +index 2dd7106..53b4484 100644 +--- a/xlators/protocol/client/src/client-helpers.c ++++ b/xlators/protocol/client/src/client-helpers.c +@@ -3082,8 +3082,7 @@ send_release4_0_over_wire(xlator_t *this, clnt_fd_ctx_t *fdctx, + gf_msg_trace(this->name, 0, "sending releasedir on fd"); + (void)client_submit_request( + this, &req, fr, conf->fops, GFS3_OP_RELEASEDIR, +- client4_0_releasedir_cbk, NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_gfx_releasedir_req); ++ client4_0_releasedir_cbk, NULL, (xdrproc_t)xdr_gfx_releasedir_req); + } else { + gfx_release_req req = { + { +@@ -3094,8 +3093,8 @@ send_release4_0_over_wire(xlator_t *this, clnt_fd_ctx_t *fdctx, + req.fd = fdctx->remote_fd; + gf_msg_trace(this->name, 0, "sending release on fd"); + (void)client_submit_request(this, &req, fr, conf->fops, GFS3_OP_RELEASE, +- client4_0_release_cbk, NULL, NULL, 0, NULL, +- 0, NULL, (xdrproc_t)xdr_gfx_release_req); ++ client4_0_release_cbk, NULL, ++ (xdrproc_t)xdr_gfx_release_req); + } + + return 0; +@@ -3118,8 +3117,7 @@ send_release3_3_over_wire(xlator_t *this, clnt_fd_ctx_t *fdctx, + gf_msg_trace(this->name, 0, "sending releasedir on fd"); + (void)client_submit_request( + this, &req, fr, conf->fops, GFS3_OP_RELEASEDIR, +- client3_3_releasedir_cbk, NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_gfs3_releasedir_req); ++ client3_3_releasedir_cbk, NULL, (xdrproc_t)xdr_gfs3_releasedir_req); + } else { + gfs3_release_req req = { + { +@@ -3130,8 +3128,8 @@ send_release3_3_over_wire(xlator_t *this, clnt_fd_ctx_t *fdctx, + req.fd = fdctx->remote_fd; + gf_msg_trace(this->name, 0, "sending release on fd"); + (void)client_submit_request(this, &req, fr, conf->fops, GFS3_OP_RELEASE, +- client3_3_release_cbk, NULL, NULL, 0, NULL, +- 0, NULL, (xdrproc_t)xdr_gfs3_release_req); ++ client3_3_release_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_release_req); + } + + return 0; +diff --git a/xlators/protocol/client/src/client-rpc-fops.c b/xlators/protocol/client/src/client-rpc-fops.c +index b7df7cc..1c8b31b 100644 +--- a/xlators/protocol/client/src/client-rpc-fops.c ++++ b/xlators/protocol/client/src/client-rpc-fops.c +@@ -3234,11 +3234,13 @@ client3_3_lookup(call_frame_t *frame, xlator_t *this, void *data) + struct iobref *rsp_iobref = NULL; + struct iobuf *rsp_iobuf = NULL; + struct iovec *rsphdr = NULL; ++ client_payload_t cp; + + if (!frame || !this || !data) + goto unwind; + + memset(vector, 0, sizeof(vector)); ++ memset(&cp, 0, sizeof(client_payload_t)); + + conf = this->private; + args = data; +@@ -3288,9 +3290,12 @@ client3_3_lookup(call_frame_t *frame, xlator_t *this, void *data) + op_errno = -ret; + goto unwind; + } ++ ++ cp.rsphdr = rsphdr; ++ cp.rsphdr_cnt = count; ++ cp.rsp_iobref = local->iobref; + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_LOOKUP, +- client3_3_lookup_cbk, NULL, rsphdr, count, NULL, +- 0, local->iobref, ++ client3_3_lookup_cbk, &cp, + (xdrproc_t)xdr_gfs3_lookup_req); + + if (ret) { +@@ -3338,8 +3343,8 @@ client3_3_stat(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_STAT, +- client3_3_stat_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_stat_req); ++ client3_3_stat_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_stat_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3381,8 +3386,8 @@ client3_3_truncate(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_TRUNCATE, +- client3_3_truncate_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_truncate_req); ++ client3_3_truncate_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_truncate_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3425,8 +3430,7 @@ client3_3_ftruncate(call_frame_t *frame, xlator_t *this, void *data) + } + ret = client_submit_request(this, &req, frame, conf->fops, + GFS3_OP_FTRUNCATE, client3_3_ftruncate_cbk, +- NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_gfs3_ftruncate_req); ++ NULL, (xdrproc_t)xdr_gfs3_ftruncate_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3468,8 +3472,8 @@ client3_3_access(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_ACCESS, +- client3_3_access_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_access_req); ++ client3_3_access_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_access_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3505,10 +3509,12 @@ client3_3_readlink(call_frame_t *frame, xlator_t *this, void *data) + struct iovec vector[MAX_IOVEC] = { + {0}, + }; ++ client_payload_t cp; + + if (!frame || !this || !data) + goto unwind; + ++ memset(&cp, 0, sizeof(client_payload_t)); + args = data; + + conf = this->private; +@@ -3547,9 +3553,11 @@ client3_3_readlink(call_frame_t *frame, xlator_t *this, void *data) + rsp_iobuf = NULL; + rsp_iobref = NULL; + ++ cp.rsphdr = rsphdr; ++ cp.rsphdr_cnt = count; ++ cp.rsp_iobref = local->iobref; + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_READLINK, +- client3_3_readlink_cbk, NULL, rsphdr, count, +- NULL, 0, local->iobref, ++ client3_3_readlink_cbk, &cp, + (xdrproc_t)xdr_gfs3_readlink_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, +@@ -3595,8 +3603,8 @@ client3_3_unlink(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_UNLINK, +- client3_3_unlink_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_unlink_req); ++ client3_3_unlink_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_unlink_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3638,8 +3646,8 @@ client3_3_rmdir(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_RMDIR, +- client3_3_rmdir_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_rmdir_req); ++ client3_3_rmdir_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_rmdir_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3697,8 +3705,8 @@ client3_3_symlink(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_SYMLINK, +- client3_3_symlink_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_symlink_req); ++ client3_3_symlink_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_symlink_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3743,8 +3751,8 @@ client3_3_rename(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_RENAME, +- client3_3_rename_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_rename_req); ++ client3_3_rename_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_rename_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3802,8 +3810,8 @@ client3_3_link(call_frame_t *frame, xlator_t *this, void *data) + loc_path(&local->loc2, NULL); + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_LINK, +- client3_3_link_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_link_req); ++ client3_3_link_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_link_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3857,8 +3865,8 @@ client3_3_mknod(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_MKNOD, +- client3_3_mknod_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_mknod_req); ++ client3_3_mknod_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_mknod_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3924,8 +3932,8 @@ client3_3_mkdir(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_MKDIR, +- client3_3_mkdir_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_mkdir_req); ++ client3_3_mkdir_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_mkdir_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3982,8 +3990,8 @@ client3_3_create(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_CREATE, +- client3_3_create_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_create_req); ++ client3_3_create_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_create_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4043,8 +4051,8 @@ client3_3_open(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_OPEN, +- client3_3_open_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_open_req); ++ client3_3_open_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_open_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4079,10 +4087,12 @@ client3_3_readv(call_frame_t *frame, xlator_t *this, void *data) + }; + struct iobuf *rsp_iobuf = NULL; + struct iobref *rsp_iobref = NULL; ++ client_payload_t cp; + + if (!frame || !this || !data) + goto unwind; + ++ memset(&cp, 0, sizeof(client_payload_t)); + args = data; + conf = this->private; + +@@ -4130,9 +4140,12 @@ client3_3_readv(call_frame_t *frame, xlator_t *this, void *data) + local->iobref = rsp_iobref; + rsp_iobref = NULL; + ++ cp.rsp_payload = &rsp_vec; ++ cp.rsp_payload_cnt = 1; ++ cp.rsp_iobref = local->iobref; + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_READ, +- client3_3_readv_cbk, NULL, NULL, 0, &rsp_vec, 1, +- local->iobref, (xdrproc_t)xdr_gfs3_read_req); ++ client3_3_readv_cbk, &cp, ++ (xdrproc_t)xdr_gfs3_read_req); + if (ret) { + // unwind is done in the cbk + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, +@@ -4167,10 +4180,12 @@ client3_3_writev(call_frame_t *frame, xlator_t *this, void *data) + }; + int op_errno = ESTALE; + int ret = 0; ++ client_payload_t cp; + + if (!frame || !this || !data) + goto unwind; + ++ memset(&cp, 0, sizeof(client_payload_t)); + args = data; + conf = this->private; + +@@ -4187,9 +4202,12 @@ client3_3_writev(call_frame_t *frame, xlator_t *this, void *data) + op_errno = -ret; + goto unwind; + } ++ ++ cp.iobref = args->iobref; ++ cp.payload = args->vector; ++ cp.payload_cnt = args->count; + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_WRITE, +- client3_3_writev_cbk, args->iobref, +- args->vector, args->count, NULL, 0, NULL, ++ client3_3_writev_cbk, &cp, + (xdrproc_t)xdr_gfs3_write_req); + if (ret) { + /* +@@ -4248,8 +4266,8 @@ client3_3_flush(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_FLUSH, +- client3_3_flush_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_flush_req); ++ client3_3_flush_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_flush_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4291,8 +4309,8 @@ client3_3_fsync(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_FSYNC, +- client3_3_fsync_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_fsync_req); ++ client3_3_fsync_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_fsync_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4336,8 +4354,8 @@ client3_3_fstat(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_FSTAT, +- client3_3_fstat_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_fstat_req); ++ client3_3_fstat_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_fstat_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4391,8 +4409,8 @@ client3_3_opendir(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_OPENDIR, +- client3_3_opendir_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_opendir_req); ++ client3_3_opendir_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_opendir_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4435,8 +4453,8 @@ client3_3_fsyncdir(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_FSYNCDIR, +- client3_3_fsyncdir_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_fsyncdir_req); ++ client3_3_fsyncdir_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_fsyncdir_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4479,8 +4497,8 @@ client3_3_statfs(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_STATFS, +- client3_3_statfs_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_statfs_req); ++ client3_3_statfs_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_statfs_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4523,8 +4541,8 @@ client3_3_setxattr(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_SETXATTR, +- client3_3_setxattr_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_setxattr_req); ++ client3_3_setxattr_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_setxattr_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4570,8 +4588,7 @@ client3_3_fsetxattr(call_frame_t *frame, xlator_t *this, void *data) + } + ret = client_submit_request(this, &req, frame, conf->fops, + GFS3_OP_FSETXATTR, client3_3_fsetxattr_cbk, +- NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_gfs3_fsetxattr_req); ++ NULL, (xdrproc_t)xdr_gfs3_fsetxattr_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4611,10 +4628,12 @@ client3_3_fgetxattr(call_frame_t *frame, xlator_t *this, void *data) + struct iovec vector[MAX_IOVEC] = { + {0}, + }; ++ client_payload_t cp; + + if (!frame || !this || !data) + goto unwind; + ++ memset(&cp, 0, sizeof(client_payload_t)); + args = data; + conf = this->private; + +@@ -4654,9 +4673,12 @@ client3_3_fgetxattr(call_frame_t *frame, xlator_t *this, void *data) + op_errno = -ret; + goto unwind; + } ++ ++ cp.rsphdr = rsphdr; ++ cp.rsphdr_cnt = count; ++ cp.rsp_iobref = local->iobref; + ret = client_submit_request(this, &req, frame, conf->fops, +- GFS3_OP_FGETXATTR, client3_3_fgetxattr_cbk, +- NULL, rsphdr, count, NULL, 0, local->iobref, ++ GFS3_OP_FGETXATTR, client3_3_fgetxattr_cbk, &cp, + (xdrproc_t)xdr_gfs3_fgetxattr_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, +@@ -4699,11 +4721,14 @@ client3_3_getxattr(call_frame_t *frame, xlator_t *this, void *data) + struct iovec vector[MAX_IOVEC] = { + {0}, + }; ++ client_payload_t cp; + + if (!frame || !this || !data) { + op_errno = 0; + goto unwind; + } ++ ++ memset(&cp, 0, sizeof(client_payload_t)); + args = data; + + local = mem_get0(this->local_pool); +@@ -4775,9 +4800,12 @@ client3_3_getxattr(call_frame_t *frame, xlator_t *this, void *data) + op_errno = -ret; + goto unwind; + } ++ ++ cp.rsphdr = rsphdr; ++ cp.rsphdr_cnt = count; ++ cp.rsp_iobref = local->iobref; + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_GETXATTR, +- client3_3_getxattr_cbk, NULL, rsphdr, count, +- NULL, 0, local->iobref, ++ client3_3_getxattr_cbk, &cp, + (xdrproc_t)xdr_gfs3_getxattr_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, +@@ -4822,10 +4850,12 @@ client3_3_xattrop(call_frame_t *frame, xlator_t *this, void *data) + struct iovec vector[MAX_IOVEC] = { + {0}, + }; ++ client_payload_t cp; + + if (!frame || !this || !data) + goto unwind; + ++ memset(&cp, 0, sizeof(client_payload_t)); + args = data; + + if (!(args->loc && args->loc->inode)) +@@ -4871,9 +4901,12 @@ client3_3_xattrop(call_frame_t *frame, xlator_t *this, void *data) + op_errno = -ret; + goto unwind; + } ++ ++ cp.rsphdr = rsphdr; ++ cp.rsphdr_cnt = count; ++ cp.rsp_iobref = local->iobref; + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_XATTROP, +- client3_3_xattrop_cbk, NULL, rsphdr, count, +- NULL, 0, local->iobref, ++ client3_3_xattrop_cbk, &cp, + (xdrproc_t)xdr_gfs3_xattrop_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, +@@ -4918,10 +4951,12 @@ client3_3_fxattrop(call_frame_t *frame, xlator_t *this, void *data) + struct iovec vector[MAX_IOVEC] = { + {0}, + }; ++ client_payload_t cp; + + if (!frame || !this || !data) + goto unwind; + ++ memset(&cp, 0, sizeof(client_payload_t)); + args = data; + conf = this->private; + +@@ -4962,9 +4997,11 @@ client3_3_fxattrop(call_frame_t *frame, xlator_t *this, void *data) + rsp_iobuf = NULL; + rsp_iobref = NULL; + ++ cp.rsphdr = rsphdr; ++ cp.rsphdr_cnt = count; ++ cp.rsp_iobref = local->iobref; + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_FXATTROP, +- client3_3_fxattrop_cbk, NULL, rsphdr, count, +- NULL, 0, local->iobref, ++ client3_3_fxattrop_cbk, &cp, + (xdrproc_t)xdr_gfs3_fxattrop_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, +@@ -5016,8 +5053,7 @@ client3_3_removexattr(call_frame_t *frame, xlator_t *this, void *data) + } + ret = client_submit_request(this, &req, frame, conf->fops, + GFS3_OP_REMOVEXATTR, client3_3_removexattr_cbk, +- NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_gfs3_removexattr_req); ++ NULL, (xdrproc_t)xdr_gfs3_removexattr_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5059,10 +5095,9 @@ client3_3_fremovexattr(call_frame_t *frame, xlator_t *this, void *data) + op_errno = -ret; + goto unwind; + } +- ret = client_submit_request(this, &req, frame, conf->fops, +- GFS3_OP_FREMOVEXATTR, +- client3_3_fremovexattr_cbk, NULL, NULL, 0, NULL, +- 0, NULL, (xdrproc_t)xdr_gfs3_fremovexattr_req); ++ ret = client_submit_request( ++ this, &req, frame, conf->fops, GFS3_OP_FREMOVEXATTR, ++ client3_3_fremovexattr_cbk, NULL, (xdrproc_t)xdr_gfs3_fremovexattr_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5104,8 +5139,8 @@ client3_3_lease(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_LEASE, +- client3_3_lease_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_lease_req); ++ client3_3_lease_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_lease_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5167,7 +5202,7 @@ client3_3_lk(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_LK, +- client3_3_lk_cbk, NULL, NULL, 0, NULL, 0, NULL, ++ client3_3_lk_cbk, NULL, + (xdrproc_t)xdr_gfs3_lk_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, +@@ -5210,8 +5245,8 @@ client3_3_inodelk(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_INODELK, +- client3_3_inodelk_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_inodelk_req); ++ client3_3_inodelk_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_inodelk_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5260,8 +5295,8 @@ client3_3_finodelk(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_FINODELK, +- client3_3_finodelk_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_finodelk_req); ++ client3_3_finodelk_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_finodelk_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5305,8 +5340,8 @@ client3_3_entrylk(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_ENTRYLK, +- client3_3_entrylk_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_entrylk_req); ++ client3_3_entrylk_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_entrylk_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5349,8 +5384,8 @@ client3_3_fentrylk(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_FENTRYLK, +- client3_3_fentrylk_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_fentrylk_req); ++ client3_3_fentrylk_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_fentrylk_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5391,8 +5426,7 @@ client3_3_rchecksum(call_frame_t *frame, xlator_t *this, void *data) + } + ret = client_submit_request(this, &req, frame, conf->fops, + GFS3_OP_RCHECKSUM, client3_3_rchecksum_cbk, +- NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_gfs3_rchecksum_req); ++ NULL, (xdrproc_t)xdr_gfs3_rchecksum_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5433,10 +5467,12 @@ client3_3_readdir(call_frame_t *frame, xlator_t *this, void *data) + {0}, + }; + int readdir_rsp_size = 0; ++ client_payload_t cp; + + if (!frame || !this || !data) + goto unwind; + ++ memset(&cp, 0, sizeof(client_payload_t)); + args = data; + conf = this->private; + +@@ -5486,9 +5522,11 @@ client3_3_readdir(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ++ cp.rsphdr = rsphdr; ++ cp.rsphdr_cnt = count; ++ cp.rsp_iobref = rsp_iobref; + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_READDIR, +- client3_3_readdir_cbk, NULL, rsphdr, count, +- NULL, 0, rsp_iobref, ++ client3_3_readdir_cbk, &cp, + (xdrproc_t)xdr_gfs3_readdir_req); + + if (ret) { +@@ -5534,10 +5572,12 @@ client3_3_readdirp(call_frame_t *frame, xlator_t *this, void *data) + {0}, + }; + clnt_local_t *local = NULL; ++ client_payload_t cp; + + if (!frame || !this || !data) + goto unwind; + ++ memset(&cp, 0, sizeof(client_payload_t)); + args = data; + conf = this->private; + +@@ -5587,9 +5627,11 @@ client3_3_readdirp(call_frame_t *frame, xlator_t *this, void *data) + + local->fd = fd_ref(args->fd); + ++ cp.rsphdr = rsphdr; ++ cp.rsphdr_cnt = count; ++ cp.rsp_iobref = rsp_iobref; + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_READDIRP, +- client3_3_readdirp_cbk, NULL, rsphdr, count, +- NULL, 0, rsp_iobref, ++ client3_3_readdirp_cbk, &cp, + (xdrproc_t)xdr_gfs3_readdirp_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, +@@ -5637,8 +5679,8 @@ client3_3_setattr(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_SETATTR, +- client3_3_setattr_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_setattr_req); ++ client3_3_setattr_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_setattr_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5679,8 +5721,8 @@ client3_3_fsetattr(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_FSETATTR, +- client3_3_fsetattr_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_fsetattr_req); ++ client3_3_fsetattr_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_fsetattr_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5722,8 +5764,7 @@ client3_3_fallocate(call_frame_t *frame, xlator_t *this, void *data) + + ret = client_submit_request(this, &req, frame, conf->fops, + GFS3_OP_FALLOCATE, client3_3_fallocate_cbk, +- NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_gfs3_fallocate_req); ++ NULL, (xdrproc_t)xdr_gfs3_fallocate_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5764,8 +5805,8 @@ client3_3_discard(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_DISCARD, +- client3_3_discard_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_discard_req); ++ client3_3_discard_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_discard_req); + if (ret) + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5807,8 +5848,8 @@ client3_3_zerofill(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_ZEROFILL, +- client3_3_zerofill_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_zerofill_req); ++ client3_3_zerofill_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_zerofill_req); + if (ret) + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5850,7 +5891,7 @@ client3_3_ipc(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_IPC, +- client3_3_ipc_cbk, NULL, NULL, 0, NULL, 0, NULL, ++ client3_3_ipc_cbk, NULL, + (xdrproc_t)xdr_gfs3_ipc_req); + if (ret) + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, +@@ -5895,8 +5936,8 @@ client3_3_seek(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_SEEK, +- client3_3_seek_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfs3_seek_req); ++ client3_3_seek_cbk, NULL, ++ (xdrproc_t)xdr_gfs3_seek_req); + if (ret) + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -6083,8 +6124,7 @@ client3_3_getactivelk(call_frame_t *frame, xlator_t *this, void *data) + + ret = client_submit_request(this, &req, frame, conf->fops, + GFS3_OP_GETACTIVELK, client3_3_getactivelk_cbk, +- NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_gfs3_getactivelk_req); ++ NULL, (xdrproc_t)xdr_gfs3_getactivelk_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -6141,8 +6181,7 @@ client3_3_setactivelk(call_frame_t *frame, xlator_t *this, void *data) + + ret = client_submit_request(this, &req, frame, conf->fops, + GFS3_OP_SETACTIVELK, client3_3_setactivelk_cbk, +- NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_gfs3_setactivelk_req); ++ NULL, (xdrproc_t)xdr_gfs3_setactivelk_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +diff --git a/xlators/protocol/client/src/client-rpc-fops_v2.c b/xlators/protocol/client/src/client-rpc-fops_v2.c +index 8f3ee41..2673b6e 100644 +--- a/xlators/protocol/client/src/client-rpc-fops_v2.c ++++ b/xlators/protocol/client/src/client-rpc-fops_v2.c +@@ -3005,11 +3005,13 @@ client4_0_lookup(call_frame_t *frame, xlator_t *this, void *data) + struct iobref *rsp_iobref = NULL; + struct iobuf *rsp_iobuf = NULL; + struct iovec *rsphdr = NULL; ++ client_payload_t cp; + + if (!frame || !this || !data) + goto unwind; + + memset(vector, 0, sizeof(vector)); ++ memset(&cp, 0, sizeof(client_payload_t)); + + conf = this->private; + args = data; +@@ -3059,9 +3061,12 @@ client4_0_lookup(call_frame_t *frame, xlator_t *this, void *data) + op_errno = -ret; + goto unwind; + } ++ ++ cp.rsphdr = rsphdr; ++ cp.rsphdr_cnt = count; ++ cp.rsp_iobref = local->iobref; + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_LOOKUP, +- client4_0_lookup_cbk, NULL, rsphdr, count, NULL, +- 0, local->iobref, ++ client4_0_lookup_cbk, &cp, + (xdrproc_t)xdr_gfx_lookup_req); + + if (ret) { +@@ -3109,8 +3114,8 @@ client4_0_stat(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_STAT, +- client4_0_stat_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_stat_req); ++ client4_0_stat_cbk, NULL, ++ (xdrproc_t)xdr_gfx_stat_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3153,8 +3158,8 @@ client4_0_truncate(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_TRUNCATE, +- client4_0_truncate_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_truncate_req); ++ client4_0_truncate_cbk, NULL, ++ (xdrproc_t)xdr_gfx_truncate_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3198,8 +3203,7 @@ client4_0_ftruncate(call_frame_t *frame, xlator_t *this, void *data) + } + ret = client_submit_request(this, &req, frame, conf->fops, + GFS3_OP_FTRUNCATE, client4_0_ftruncate_cbk, +- NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_gfx_ftruncate_req); ++ NULL, (xdrproc_t)xdr_gfx_ftruncate_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3241,8 +3245,8 @@ client4_0_access(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_ACCESS, +- client4_0_access_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_access_req); ++ client4_0_access_cbk, NULL, ++ (xdrproc_t)xdr_gfx_access_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3295,8 +3299,8 @@ client4_0_readlink(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_READLINK, +- client4_0_readlink_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_readlink_req); ++ client4_0_readlink_cbk, NULL, ++ (xdrproc_t)xdr_gfx_readlink_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3338,8 +3342,8 @@ client4_0_unlink(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_UNLINK, +- client4_0_unlink_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_unlink_req); ++ client4_0_unlink_cbk, NULL, ++ (xdrproc_t)xdr_gfx_unlink_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3381,8 +3385,8 @@ client4_0_rmdir(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_RMDIR, +- client4_0_rmdir_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_rmdir_req); ++ client4_0_rmdir_cbk, NULL, ++ (xdrproc_t)xdr_gfx_rmdir_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3440,8 +3444,8 @@ client4_0_symlink(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_SYMLINK, +- client4_0_symlink_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_symlink_req); ++ client4_0_symlink_cbk, NULL, ++ (xdrproc_t)xdr_gfx_symlink_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3486,8 +3490,8 @@ client4_0_rename(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_RENAME, +- client4_0_rename_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_rename_req); ++ client4_0_rename_cbk, NULL, ++ (xdrproc_t)xdr_gfx_rename_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3546,8 +3550,8 @@ client4_0_link(call_frame_t *frame, xlator_t *this, void *data) + loc_path(&local->loc2, NULL); + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_LINK, +- client4_0_link_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_link_req); ++ client4_0_link_cbk, NULL, ++ (xdrproc_t)xdr_gfx_link_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3601,8 +3605,8 @@ client4_0_mknod(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_MKNOD, +- client4_0_mknod_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_mknod_req); ++ client4_0_mknod_cbk, NULL, ++ (xdrproc_t)xdr_gfx_mknod_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3668,8 +3672,8 @@ client4_0_mkdir(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_MKDIR, +- client4_0_mkdir_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_mkdir_req); ++ client4_0_mkdir_cbk, NULL, ++ (xdrproc_t)xdr_gfx_mkdir_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3726,8 +3730,8 @@ client4_0_create(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_CREATE, +- client4_0_create_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_create_req); ++ client4_0_create_cbk, NULL, ++ (xdrproc_t)xdr_gfx_create_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3787,8 +3791,8 @@ client4_0_open(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_OPEN, +- client4_0_open_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_open_req); ++ client4_0_open_cbk, NULL, ++ (xdrproc_t)xdr_gfx_open_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3823,10 +3827,12 @@ client4_0_readv(call_frame_t *frame, xlator_t *this, void *data) + }; + struct iobuf *rsp_iobuf = NULL; + struct iobref *rsp_iobref = NULL; ++ client_payload_t cp; + + if (!frame || !this || !data) + goto unwind; + ++ memset(&cp, 0, sizeof(client_payload_t)); + args = data; + conf = this->private; + +@@ -3872,9 +3878,12 @@ client4_0_readv(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ++ cp.rsp_payload = &rsp_vec; ++ cp.rsp_payload_cnt = 1; ++ cp.rsp_iobref = local->iobref; + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_READ, +- client4_0_readv_cbk, NULL, NULL, 0, &rsp_vec, 1, +- local->iobref, (xdrproc_t)xdr_gfx_read_req); ++ client4_0_readv_cbk, &cp, ++ (xdrproc_t)xdr_gfx_read_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -3905,10 +3914,12 @@ client4_0_writev(call_frame_t *frame, xlator_t *this, void *data) + }; + int op_errno = ESTALE; + int ret = 0; ++ client_payload_t cp; + + if (!frame || !this || !data) + goto unwind; + ++ memset(&cp, 0, sizeof(client_payload_t)); + args = data; + conf = this->private; + +@@ -3926,9 +3937,11 @@ client4_0_writev(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ++ cp.iobref = args->iobref; ++ cp.payload = args->vector; ++ cp.payload_cnt = args->count; + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_WRITE, +- client4_0_writev_cbk, args->iobref, +- args->vector, args->count, NULL, 0, NULL, ++ client4_0_writev_cbk, &cp, + (xdrproc_t)xdr_gfx_write_req); + if (ret) { + /* +@@ -3987,8 +4000,8 @@ client4_0_flush(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_FLUSH, +- client4_0_flush_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_flush_req); ++ client4_0_flush_cbk, NULL, ++ (xdrproc_t)xdr_gfx_flush_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4030,8 +4043,8 @@ client4_0_fsync(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_FSYNC, +- client4_0_fsync_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_fsync_req); ++ client4_0_fsync_cbk, NULL, ++ (xdrproc_t)xdr_gfx_fsync_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4075,8 +4088,8 @@ client4_0_fstat(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_FSTAT, +- client4_0_fstat_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_fstat_req); ++ client4_0_fstat_cbk, NULL, ++ (xdrproc_t)xdr_gfx_fstat_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4130,8 +4143,8 @@ client4_0_opendir(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_OPENDIR, +- client4_0_opendir_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_opendir_req); ++ client4_0_opendir_cbk, NULL, ++ (xdrproc_t)xdr_gfx_opendir_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4175,8 +4188,8 @@ client4_0_fsyncdir(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_FSYNCDIR, +- client4_0_fsyncdir_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_fsyncdir_req); ++ client4_0_fsyncdir_cbk, NULL, ++ (xdrproc_t)xdr_gfx_fsyncdir_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4219,8 +4232,8 @@ client4_0_statfs(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_STATFS, +- client4_0_statfs_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_statfs_req); ++ client4_0_statfs_cbk, NULL, ++ (xdrproc_t)xdr_gfx_statfs_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4263,8 +4276,8 @@ client4_0_setxattr(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_SETXATTR, +- client4_0_setxattr_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_setxattr_req); ++ client4_0_setxattr_cbk, NULL, ++ (xdrproc_t)xdr_gfx_setxattr_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4310,8 +4323,7 @@ client4_0_fsetxattr(call_frame_t *frame, xlator_t *this, void *data) + } + ret = client_submit_request(this, &req, frame, conf->fops, + GFS3_OP_FSETXATTR, client4_0_fsetxattr_cbk, +- NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_gfx_fsetxattr_req); ++ NULL, (xdrproc_t)xdr_gfx_fsetxattr_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4364,8 +4376,7 @@ client4_0_fgetxattr(call_frame_t *frame, xlator_t *this, void *data) + } + ret = client_submit_request(this, &req, frame, conf->fops, + GFS3_OP_FGETXATTR, client4_0_fgetxattr_cbk, +- NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_gfx_fgetxattr_req); ++ NULL, (xdrproc_t)xdr_gfx_fgetxattr_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4452,8 +4463,8 @@ client4_0_getxattr(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_GETXATTR, +- client4_0_getxattr_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_getxattr_req); ++ client4_0_getxattr_cbk, NULL, ++ (xdrproc_t)xdr_gfx_getxattr_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4514,8 +4525,8 @@ client4_0_xattrop(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_XATTROP, +- client4_0_xattrop_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_xattrop_req); ++ client4_0_xattrop_cbk, NULL, ++ (xdrproc_t)xdr_gfx_xattrop_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4566,8 +4577,8 @@ client4_0_fxattrop(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_FXATTROP, +- client4_0_fxattrop_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_fxattrop_req); ++ client4_0_fxattrop_cbk, NULL, ++ (xdrproc_t)xdr_gfx_fxattrop_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4613,8 +4624,7 @@ client4_0_removexattr(call_frame_t *frame, xlator_t *this, void *data) + } + ret = client_submit_request(this, &req, frame, conf->fops, + GFS3_OP_REMOVEXATTR, client4_0_removexattr_cbk, +- NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_gfx_removexattr_req); ++ NULL, (xdrproc_t)xdr_gfx_removexattr_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4656,10 +4666,9 @@ client4_0_fremovexattr(call_frame_t *frame, xlator_t *this, void *data) + op_errno = -ret; + goto unwind; + } +- ret = client_submit_request(this, &req, frame, conf->fops, +- GFS3_OP_FREMOVEXATTR, +- client4_0_fremovexattr_cbk, NULL, NULL, 0, NULL, +- 0, NULL, (xdrproc_t)xdr_gfx_fremovexattr_req); ++ ret = client_submit_request( ++ this, &req, frame, conf->fops, GFS3_OP_FREMOVEXATTR, ++ client4_0_fremovexattr_cbk, NULL, (xdrproc_t)xdr_gfx_fremovexattr_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4701,8 +4710,8 @@ client4_0_lease(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_LEASE, +- client4_0_lease_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_lease_req); ++ client4_0_lease_cbk, NULL, ++ (xdrproc_t)xdr_gfx_lease_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4764,7 +4773,7 @@ client4_0_lk(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_LK, +- client4_0_lk_cbk, NULL, NULL, 0, NULL, 0, NULL, ++ client4_0_lk_cbk, NULL, + (xdrproc_t)xdr_gfx_lk_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, +@@ -4807,8 +4816,8 @@ client4_0_inodelk(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_INODELK, +- client4_0_inodelk_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_inodelk_req); ++ client4_0_inodelk_cbk, NULL, ++ (xdrproc_t)xdr_gfx_inodelk_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4857,8 +4866,8 @@ client4_0_finodelk(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_FINODELK, +- client4_0_finodelk_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_finodelk_req); ++ client4_0_finodelk_cbk, NULL, ++ (xdrproc_t)xdr_gfx_finodelk_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4902,8 +4911,8 @@ client4_0_entrylk(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_ENTRYLK, +- client4_0_entrylk_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_entrylk_req); ++ client4_0_entrylk_cbk, NULL, ++ (xdrproc_t)xdr_gfx_entrylk_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4946,8 +4955,8 @@ client4_0_fentrylk(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_FENTRYLK, +- client4_0_fentrylk_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_fentrylk_req); ++ client4_0_fentrylk_cbk, NULL, ++ (xdrproc_t)xdr_gfx_fentrylk_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -4988,10 +4997,12 @@ client4_0_readdir(call_frame_t *frame, xlator_t *this, void *data) + {0}, + }; + int readdir_rsp_size = 0; ++ client_payload_t cp; + + if (!frame || !this || !data) + goto unwind; + ++ memset(&cp, 0, sizeof(client_payload_t)); + args = data; + conf = this->private; + +@@ -5041,9 +5052,11 @@ client4_0_readdir(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ++ cp.rsphdr = rsphdr; ++ cp.rsphdr_cnt = count; ++ cp.rsp_iobref = rsp_iobref; + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_READDIR, +- client4_0_readdir_cbk, NULL, rsphdr, count, +- NULL, 0, rsp_iobref, ++ client4_0_readdir_cbk, &cp, + (xdrproc_t)xdr_gfx_readdir_req); + + if (ret) { +@@ -5089,10 +5102,12 @@ client4_0_readdirp(call_frame_t *frame, xlator_t *this, void *data) + {0}, + }; + clnt_local_t *local = NULL; ++ client_payload_t cp; + + if (!frame || !this || !data) + goto unwind; + ++ memset(&cp, 0, sizeof(client_payload_t)); + args = data; + conf = this->private; + +@@ -5142,9 +5157,11 @@ client4_0_readdirp(call_frame_t *frame, xlator_t *this, void *data) + + local->fd = fd_ref(args->fd); + ++ cp.rsphdr = rsphdr; ++ cp.rsphdr_cnt = count; ++ cp.rsp_iobref = rsp_iobref; + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_READDIRP, +- client4_0_readdirp_cbk, NULL, rsphdr, count, +- NULL, 0, rsp_iobref, ++ client4_0_readdirp_cbk, &cp, + (xdrproc_t)xdr_gfx_readdirp_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, +@@ -5192,8 +5209,8 @@ client4_0_setattr(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_SETATTR, +- client4_0_setattr_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_setattr_req); ++ client4_0_setattr_cbk, NULL, ++ (xdrproc_t)xdr_gfx_setattr_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5235,8 +5252,7 @@ client4_0_fallocate(call_frame_t *frame, xlator_t *this, void *data) + + ret = client_submit_request(this, &req, frame, conf->fops, + GFS3_OP_FALLOCATE, client4_0_fallocate_cbk, +- NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_gfx_fallocate_req); ++ NULL, (xdrproc_t)xdr_gfx_fallocate_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5277,8 +5293,8 @@ client4_0_discard(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_DISCARD, +- client4_0_discard_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_discard_req); ++ client4_0_discard_cbk, NULL, ++ (xdrproc_t)xdr_gfx_discard_req); + if (ret) + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5320,8 +5336,8 @@ client4_0_zerofill(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_ZEROFILL, +- client4_0_zerofill_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_zerofill_req); ++ client4_0_zerofill_cbk, NULL, ++ (xdrproc_t)xdr_gfx_zerofill_req); + if (ret) + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5363,7 +5379,7 @@ client4_0_ipc(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_IPC, +- client4_0_ipc_cbk, NULL, NULL, 0, NULL, 0, NULL, ++ client4_0_ipc_cbk, NULL, + (xdrproc_t)xdr_gfx_ipc_req); + if (ret) + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, +@@ -5408,8 +5424,8 @@ client4_0_seek(call_frame_t *frame, xlator_t *this, void *data) + } + + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_SEEK, +- client4_0_seek_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_seek_req); ++ client4_0_seek_cbk, NULL, ++ (xdrproc_t)xdr_gfx_seek_req); + if (ret) + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5458,8 +5474,7 @@ client4_0_getactivelk(call_frame_t *frame, xlator_t *this, void *data) + + ret = client_submit_request(this, &req, frame, conf->fops, + GFS3_OP_GETACTIVELK, client4_0_getactivelk_cbk, +- NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_gfx_getactivelk_req); ++ NULL, (xdrproc_t)xdr_gfx_getactivelk_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5514,8 +5529,7 @@ client4_0_setactivelk(call_frame_t *frame, xlator_t *this, void *data) + + ret = client_submit_request(this, &req, frame, conf->fops, + GFS3_OP_SETACTIVELK, client4_0_setactivelk_cbk, +- NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_gfx_setactivelk_req); ++ NULL, (xdrproc_t)xdr_gfx_setactivelk_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5785,8 +5799,8 @@ client4_0_namelink(call_frame_t *frame, xlator_t *this, void *data) + + dict_to_xdr(args->xdata, &req.xdata); + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_NAMELINK, +- client4_namelink_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_namelink_req); ++ client4_namelink_cbk, NULL, ++ (xdrproc_t)xdr_gfx_namelink_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -5837,8 +5851,8 @@ client4_0_icreate(call_frame_t *frame, xlator_t *this, void *data) + op_errno = ESTALE; + dict_to_xdr(args->xdata, &req.xdata); + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_ICREATE, +- client4_icreate_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_icreate_req); ++ client4_icreate_cbk, NULL, ++ (xdrproc_t)xdr_gfx_icreate_req); + if (ret) + goto free_reqdata; + GF_FREE(req.xdata.pairs.pairs_val); +@@ -5864,10 +5878,12 @@ client4_0_put(call_frame_t *frame, xlator_t *this, void *data) + int op_errno = ESTALE; + int ret = 0; + clnt_local_t *local = NULL; ++ client_payload_t cp; + + if (!frame || !this || !data) + goto unwind; + ++ memset(&cp, 0, sizeof(client_payload_t)); + args = data; + conf = this->private; + +@@ -5890,9 +5906,11 @@ client4_0_put(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ++ cp.iobref = args->iobref; ++ cp.payload = args->vector; ++ cp.payload_cnt = args->count; + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_PUT, +- client4_0_put_cbk, args->iobref, args->vector, +- args->count, NULL, 0, NULL, ++ client4_0_put_cbk, &cp, + (xdrproc_t)xdr_gfx_put_req); + if (ret) { + /* +@@ -5959,10 +5977,10 @@ client4_0_copy_file_range(call_frame_t *frame, xlator_t *this, void *data) + local->attempt_reopen_out = client_is_reopen_needed(args->fd_out, this, + req.fd_out); + +- ret = client_submit_request( +- this, &req, frame, conf->fops, GFS3_OP_COPY_FILE_RANGE, +- client4_0_copy_file_range_cbk, NULL, NULL, 0, NULL, 0, NULL, +- (xdrproc_t)xdr_gfx_copy_file_range_req); ++ ret = client_submit_request(this, &req, frame, conf->fops, ++ GFS3_OP_COPY_FILE_RANGE, ++ client4_0_copy_file_range_cbk, NULL, ++ (xdrproc_t)xdr_gfx_copy_file_range_req); + if (ret) { + /* + * If the lower layers fail to submit a request, they'll also +@@ -6009,8 +6027,8 @@ client4_0_fsetattr(call_frame_t *frame, xlator_t *this, void *data) + goto unwind; + } + ret = client_submit_request(this, &req, frame, conf->fops, GFS3_OP_FSETATTR, +- client4_0_fsetattr_cbk, NULL, NULL, 0, NULL, 0, +- NULL, (xdrproc_t)xdr_gfx_fsetattr_req); ++ client4_0_fsetattr_cbk, NULL, ++ (xdrproc_t)xdr_gfx_fsetattr_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +@@ -6054,9 +6072,9 @@ client4_0_rchecksum(call_frame_t *frame, xlator_t *this, void *data) + + dict_to_xdr(args->xdata, &req.xdata); + +- ret = client_submit_request( +- this, &req, frame, conf->fops, GFS3_OP_RCHECKSUM, client4_rchecksum_cbk, +- NULL, NULL, 0, NULL, 0, NULL, (xdrproc_t)xdr_gfx_rchecksum_req); ++ ret = client_submit_request(this, &req, frame, conf->fops, ++ GFS3_OP_RCHECKSUM, client4_rchecksum_cbk, NULL, ++ (xdrproc_t)xdr_gfx_rchecksum_req); + if (ret) { + gf_msg(this->name, GF_LOG_WARNING, 0, PC_MSG_FOP_SEND_FAILED, + "failed to send the fop"); +diff --git a/xlators/protocol/client/src/client.c b/xlators/protocol/client/src/client.c +index dea6c28..2d75714 100644 +--- a/xlators/protocol/client/src/client.c ++++ b/xlators/protocol/client/src/client.c +@@ -131,10 +131,7 @@ client_type_to_gf_type(short l_type) + int + client_submit_request(xlator_t *this, void *req, call_frame_t *frame, + rpc_clnt_prog_t *prog, int procnum, fop_cbk_fn_t cbkfn, +- struct iobref *iobref, struct iovec *payload, +- int payloadcnt, struct iovec *rsp_payload, +- int rsp_payload_count, struct iobref *rsp_iobref, +- xdrproc_t xdrproc) ++ client_payload_t *cp, xdrproc_t xdrproc) + { + int ret = -1; + clnt_conf_t *conf = NULL; +@@ -180,8 +177,8 @@ client_submit_request(xlator_t *this, void *req, call_frame_t *frame, + goto out; + } + +- if (iobref != NULL) { +- ret = iobref_merge(new_iobref, iobref); ++ if (cp && cp->iobref != NULL) { ++ ret = iobref_merge(new_iobref, cp->iobref); + if (ret != 0) { + gf_msg(this->name, GF_LOG_WARNING, ENOMEM, PC_MSG_NO_MEMORY, + "cannot merge " +@@ -224,9 +221,16 @@ client_submit_request(xlator_t *this, void *req, call_frame_t *frame, + } + + /* Send the msg */ +- ret = rpc_clnt_submit(conf->rpc, prog, procnum, cbkfn, &iov, count, payload, +- payloadcnt, new_iobref, frame, payload, payloadcnt, +- rsp_payload, rsp_payload_count, rsp_iobref); ++ if (cp) { ++ ret = rpc_clnt_submit(conf->rpc, prog, procnum, cbkfn, &iov, count, ++ cp->payload, cp->payload_cnt, new_iobref, frame, ++ cp->rsphdr, cp->rsphdr_cnt, cp->rsp_payload, ++ cp->rsp_payload_cnt, cp->rsp_iobref); ++ } else { ++ ret = rpc_clnt_submit(conf->rpc, prog, procnum, cbkfn, &iov, count, ++ NULL, 0, new_iobref, frame, NULL, 0, NULL, 0, ++ NULL); ++ } + + if (ret < 0) { + gf_msg_debug(this->name, 0, "rpc_clnt_submit failed"); +diff --git a/xlators/protocol/client/src/client.h b/xlators/protocol/client/src/client.h +index 71f84f3..f12fa61 100644 +--- a/xlators/protocol/client/src/client.h ++++ b/xlators/protocol/client/src/client.h +@@ -345,6 +345,17 @@ typedef struct client_args { + lock_migration_info_t *locklist; + } clnt_args_t; + ++typedef struct client_payload { ++ struct iobref *iobref; ++ struct iovec *payload; ++ struct iovec *rsphdr; ++ struct iovec *rsp_payload; ++ struct iobref *rsp_iobref; ++ int payload_cnt; ++ int rsphdr_cnt; ++ int rsp_payload_cnt; ++} client_payload_t; ++ + typedef ssize_t (*gfs_serialize_t)(struct iovec outmsg, void *args); + + clnt_fd_ctx_t * +@@ -359,10 +370,7 @@ client_local_wipe(clnt_local_t *local); + int + client_submit_request(xlator_t *this, void *req, call_frame_t *frame, + rpc_clnt_prog_t *prog, int procnum, fop_cbk_fn_t cbk, +- struct iobref *iobref, struct iovec *rsphdr, +- int rsphdr_count, struct iovec *rsp_payload, +- int rsp_count, struct iobref *rsp_iobref, +- xdrproc_t xdrproc); ++ client_payload_t *cp, xdrproc_t xdrproc); + + int + client_submit_compound_request(xlator_t *this, void *req, call_frame_t *frame, +-- +1.8.3.1 + diff --git a/0048-gfapi-Unblock-epoll-thread-for-upcall-processing.patch b/0048-gfapi-Unblock-epoll-thread-for-upcall-processing.patch new file mode 100644 index 0000000..9f5f3bf --- /dev/null +++ b/0048-gfapi-Unblock-epoll-thread-for-upcall-processing.patch @@ -0,0 +1,115 @@ +From 2449a1824c6f7b57889335caaeb09f4c5cb3efce Mon Sep 17 00:00:00 2001 +From: Soumya Koduri +Date: Thu, 28 Mar 2019 14:59:00 +0530 +Subject: [PATCH 48/52] gfapi: Unblock epoll thread for upcall processing + +With commit#ad35193,we have made changes to offload +processing upcall notifications to synctask so as not +to block epoll threads. However seems like the issue wasnt +fully addressed. + +In "glfs_cbk_upcall_data" -> "synctask_new1" after creating synctask +if there is no callback defined, the thread waits on synctask_join +till the syncfn is finished. So that way even with those changes, +epoll threads are blocked till the upcalls are processed. + +Hence the right fix now is to define a callback function for that +synctask "glfs_cbk_upcall_syncop" so as to unblock epoll/notify threads +completely and the upcall processing can happen in parallel by synctask +threads. + +Upstream references- +mainline : https://review.gluster.org/22436 +release-6.0 : https://review.gluster.org/22459 + +Change-Id: I4d8645e3588fab2c3ca534e0112773aaab68a5dd +fixes: bz#1694565 +Signed-off-by: Soumya Koduri +Reviewed-on: https://code.engineering.redhat.com/gerrit/166586 +Tested-by: RHGS Build Bot +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +--- + api/src/glfs-fops.c | 42 ++++++++++++++++++++++++++++++++++-------- + 1 file changed, 34 insertions(+), 8 deletions(-) + +diff --git a/api/src/glfs-fops.c b/api/src/glfs-fops.c +index 88cd32b..01ba60b 100644 +--- a/api/src/glfs-fops.c ++++ b/api/src/glfs-fops.c +@@ -5714,6 +5714,16 @@ out: + } + + static int ++glfs_upcall_syncop_cbk(int ret, call_frame_t *frame, void *opaque) ++{ ++ struct upcall_syncop_args *args = opaque; ++ ++ GF_FREE(args->upcall_data); ++ GF_FREE(args); ++ return 0; ++} ++ ++static int + glfs_cbk_upcall_syncop(void *opaque) + { + struct upcall_syncop_args *args = opaque; +@@ -5770,15 +5780,13 @@ out: + GLFS_FREE(up_arg); + } + +- return ret; ++ return 0; + } + + static void + glfs_cbk_upcall_data(struct glfs *fs, struct gf_upcall *upcall_data) + { +- struct upcall_syncop_args args = { +- 0, +- }; ++ struct upcall_syncop_args *args = NULL; + int ret = -1; + + if (!fs || !upcall_data) +@@ -5789,16 +5797,34 @@ glfs_cbk_upcall_data(struct glfs *fs, struct gf_upcall *upcall_data) + goto out; + } + +- args.fs = fs; +- args.upcall_data = upcall_data; ++ args = GF_CALLOC(1, sizeof(struct upcall_syncop_args), ++ glfs_mt_upcall_entry_t); ++ if (!args) { ++ gf_msg(THIS->name, GF_LOG_ERROR, ENOMEM, API_MSG_ALLOC_FAILED, ++ "Upcall syncop args allocation failed."); ++ goto out; ++ } ++ ++ /* Note: we are not taking any ref on fs here. ++ * Ideally applications have to unregister for upcall events ++ * or stop polling for upcall events before performing ++ * glfs_fini. And as for outstanding synctasks created, we wait ++ * for all syncenv threads to finish tasks before cleaning up the ++ * fs->ctx. Hence it seems safe to process these callback ++ * notification without taking any lock/ref. ++ */ ++ args->fs = fs; ++ args->upcall_data = gf_memdup(upcall_data, sizeof(*upcall_data)); + +- ret = synctask_new(THIS->ctx->env, glfs_cbk_upcall_syncop, NULL, NULL, +- &args); ++ ret = synctask_new(THIS->ctx->env, glfs_cbk_upcall_syncop, ++ glfs_upcall_syncop_cbk, NULL, args); + /* should we retry incase of failure? */ + if (ret) { + gf_msg(THIS->name, GF_LOG_ERROR, errno, API_MSG_UPCALL_SYNCOP_FAILED, + "Synctak for Upcall event_type(%d) and gfid(%s) failed", + upcall_data->event_type, (char *)(upcall_data->gfid)); ++ GF_FREE(args->upcall_data); ++ GF_FREE(args); + } + + out: +-- +1.8.3.1 + diff --git a/0049-transport-socket-log-shutdown-msg-occasionally.patch b/0049-transport-socket-log-shutdown-msg-occasionally.patch new file mode 100644 index 0000000..7cee050 --- /dev/null +++ b/0049-transport-socket-log-shutdown-msg-occasionally.patch @@ -0,0 +1,49 @@ +From e205516ef874d617e4756856098bf10e17b0ea3d Mon Sep 17 00:00:00 2001 +From: Raghavendra G +Date: Fri, 22 Mar 2019 10:40:45 +0530 +Subject: [PATCH 49/52] transport/socket: log shutdown msg occasionally + +>Change-Id: If3fc0884e7e2f45de2d278b98693b7a473220a5f +>Signed-off-by: Raghavendra G +>Fixes: bz#1691616 + +BUG: 1691620 +Change-Id: If3fc0884e7e2f45de2d278b98693b7a473220a5f +Signed-off-by: Sunil Kumar Acharya +Reviewed-on: https://code.engineering.redhat.com/gerrit/167088 +Tested-by: RHGS Build Bot +--- + rpc/rpc-transport/socket/src/socket.c | 4 ++-- + rpc/rpc-transport/socket/src/socket.h | 1 + + 2 files changed, 3 insertions(+), 2 deletions(-) + +diff --git a/rpc/rpc-transport/socket/src/socket.c b/rpc/rpc-transport/socket/src/socket.c +index 121d46b..f6de1d3 100644 +--- a/rpc/rpc-transport/socket/src/socket.c ++++ b/rpc/rpc-transport/socket/src/socket.c +@@ -807,8 +807,8 @@ __socket_shutdown(rpc_transport_t *this) + gf_log(this->name, GF_LOG_DEBUG, "shutdown() returned %d. %s", ret, + strerror(errno)); + } else { +- gf_log(this->name, GF_LOG_INFO, "intentional socket shutdown(%d)", +- priv->sock); ++ GF_LOG_OCCASIONALLY(priv->shutdown_log_ctr, this->name, GF_LOG_INFO, ++ "intentional socket shutdown(%d)", priv->sock); + } + + return ret; +diff --git a/rpc/rpc-transport/socket/src/socket.h b/rpc/rpc-transport/socket/src/socket.h +index 32339d3..e1ccae2 100644 +--- a/rpc/rpc-transport/socket/src/socket.h ++++ b/rpc/rpc-transport/socket/src/socket.h +@@ -219,6 +219,7 @@ typedef struct { + int keepalivecnt; + int timeout; + int log_ctr; ++ int shutdown_log_ctr; + /* ssl_error_required is used only during the SSL connection setup + * phase. + * It holds the error code returned by SSL_get_error() and is used to +-- +1.8.3.1 + diff --git a/0050-geo-rep-Fix-syncing-multiple-rename-of-symlink.patch b/0050-geo-rep-Fix-syncing-multiple-rename-of-symlink.patch new file mode 100644 index 0000000..f7c0f65 --- /dev/null +++ b/0050-geo-rep-Fix-syncing-multiple-rename-of-symlink.patch @@ -0,0 +1,142 @@ +From 161a039f8088bf8ce7000d8175e3793219525179 Mon Sep 17 00:00:00 2001 +From: Kotresh HR +Date: Thu, 28 Mar 2019 07:17:16 -0400 +Subject: [PATCH 50/52] geo-rep: Fix syncing multiple rename of symlink + +Problem: +Geo-rep fails to sync rename of symlink if it's +renamed multiple times if creation and rename +happened successively + +Worker crash at slave: +Traceback (most recent call last): + File "/usr/libexec/glusterfs/python/syncdaemon/repce.py", in worker + res = getattr(self.obj, rmeth)(*in_data[2:]) + File "/usr/libexec/glusterfs/python/syncdaemon/resource.py", in entry_ops + [ESTALE, EINVAL, EBUSY]) + File "/usr/libexec/glusterfs/python/syncdaemon/syncdutils.py", in errno_wrap + return call(*arg) + File "/usr/libexec/glusterfs/python/syncdaemon/libcxattr.py", in lsetxattr + cls.raise_oserr() + File "/usr/libexec/glusterfs/python/syncdaemon/libcxattr.py", in raise_oserr + raise OSError(errn, os.strerror(errn)) +OSError: [Errno 12] Cannot allocate memory + +Geo-rep Behaviour: +1. SYMLINK doesn't record target path in changelog. + So while syncing SYMLINK, readlink is done on + master to get target path. + +2. Geo-rep will create destination if source is not + present while syncing RENAME. Hence while syncing + RENAME of SYMLINK, target path is collected from + destination. + +Cause: +If symlink is created and renamed multiple times, creation of +symlink is ignored, as it's no longer present on master at +that path. While symlink is renamed multiple times at master, +when syncing first RENAME of SYMLINK, both source and destination +is not present, hence target path is not known. In this case, +while creating destination directly at slave, regular file +attributes were encoded into blob instead of symlink, +causing failure in gfid-access translator while decoding +blob. + +Solution: +While syncing of RENAME of SYMLINK, when target is not known +and when src and destination is not present on the master, +don't create destination. Ignore the rename. It's ok to ignore. +If it's unliked, it's fine. If it's renamed to something else, +it will be synced then. + +Backport of: +> Patch: https://review.gluster.org/22438 +> Change-Id: Ibdfa495513b7c05b5370ab0b89c69a6802338d87 +> BUG: 1693648 +> Signed-off-by: Kotresh HR + +Change-Id: Ibdfa495513b7c05b5370ab0b89c69a6802338d87 +fixes: bz#1670429 +Signed-off-by: Kotresh HR +Reviewed-on: https://code.engineering.redhat.com/gerrit/167122 +Tested-by: RHGS Build Bot +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +--- + geo-replication/syncdaemon/resource.py | 23 ++++++++++++++--------- + tests/00-geo-rep/georep-basic-dr-rsync.t | 1 + + tests/geo-rep.rc | 12 ++++++++++++ + 3 files changed, 27 insertions(+), 9 deletions(-) + +diff --git a/geo-replication/syncdaemon/resource.py b/geo-replication/syncdaemon/resource.py +index a2d0b16..c290d86 100644 +--- a/geo-replication/syncdaemon/resource.py ++++ b/geo-replication/syncdaemon/resource.py +@@ -625,15 +625,20 @@ class Server(object): + # exist with different gfid. + if not matching_disk_gfid(gfid, entry): + if e['stat'] and not stat.S_ISDIR(e['stat']['mode']): +- if stat.S_ISLNK(e['stat']['mode']) and \ +- e['link'] is not None: +- st1 = lstat(en) +- if isinstance(st1, int): +- (pg, bname) = entry2pb(en) +- blob = entry_pack_symlink(cls, gfid, bname, +- e['link'], e['stat']) +- elif not matching_disk_gfid(gfid, en): +- collect_failure(e, EEXIST, uid, gid, True) ++ if stat.S_ISLNK(e['stat']['mode']): ++ # src is not present, so don't sync symlink as ++ # we don't know target. It's ok to ignore. If ++ # it's unliked, it's fine. If it's renamed to ++ # something else, it will be synced then. ++ if e['link'] is not None: ++ st1 = lstat(en) ++ if isinstance(st1, int): ++ (pg, bname) = entry2pb(en) ++ blob = entry_pack_symlink(cls, gfid, bname, ++ e['link'], ++ e['stat']) ++ elif not matching_disk_gfid(gfid, en): ++ collect_failure(e, EEXIST, uid, gid, True) + else: + slink = os.path.join(pfx, gfid) + st = lstat(slink) +diff --git a/tests/00-geo-rep/georep-basic-dr-rsync.t b/tests/00-geo-rep/georep-basic-dr-rsync.t +index 4a03930..8b64370 100644 +--- a/tests/00-geo-rep/georep-basic-dr-rsync.t ++++ b/tests/00-geo-rep/georep-basic-dr-rsync.t +@@ -110,6 +110,7 @@ EXPECT_WITHIN $GEO_REP_TIMEOUT 0 chown_file_ok ${slave_mnt}/hybrid_chown_f1 + #Check History Crawl. + TEST $GEOREP_CLI $master $slave stop + TEST create_data "history" ++TEST create_rename_symlink_case + TEST $GEOREP_CLI $master $slave start + EXPECT_WITHIN $GEO_REP_TIMEOUT 2 check_status_num_rows "Active" + EXPECT_WITHIN $GEO_REP_TIMEOUT 2 check_status_num_rows "Passive" +diff --git a/tests/geo-rep.rc b/tests/geo-rep.rc +index 396b4c4..d723129 100644 +--- a/tests/geo-rep.rc ++++ b/tests/geo-rep.rc +@@ -19,6 +19,18 @@ function check_common_secret_file() + echo $? + } + ++function create_rename_symlink_case() ++{ ++ mkdir ${mastermnt}/MUL_REN_SYMLINK ++ cd ${mastermnt}/MUL_REN_SYMLINK ++ mkdir sym_dir1 ++ ln -s "sym_dir1" sym1 ++ mv sym1 sym2 ++ mv sym2 sym3 ++ mv sym3 sym4 ++ cd - ++} ++ + function create_data() + { + prefix=$1 +-- +1.8.3.1 + diff --git a/0051-spec-update-rpm-install-condition.patch b/0051-spec-update-rpm-install-condition.patch new file mode 100644 index 0000000..8d5ce47 --- /dev/null +++ b/0051-spec-update-rpm-install-condition.patch @@ -0,0 +1,67 @@ +From 71f4d55770287288f39b31a0435916ac3d9f742b Mon Sep 17 00:00:00 2001 +From: Sunil Kumar Acharya +Date: Fri, 5 Apr 2019 22:27:52 +0530 +Subject: [PATCH 51/52] spec: update rpm install condition + +Update code to allow rpm install without gluster process shutdown. + +Label: DOWNSTREAM ONLY + +BUG: 1493284 +Change-Id: I308e7e4629a2428927a6df34536e3cd645a54f8c +Signed-off-by: Sunil Kumar Acharya +Reviewed-on: https://code.engineering.redhat.com/gerrit/167089 +Tested-by: RHGS Build Bot +Reviewed-by: Milind Changire +--- + glusterfs.spec.in | 34 ---------------------------------- + 1 file changed, 34 deletions(-) + +diff --git a/glusterfs.spec.in b/glusterfs.spec.in +index 7c7f7c0..0d57b49 100644 +--- a/glusterfs.spec.in ++++ b/glusterfs.spec.in +@@ -1629,40 +1629,6 @@ if not (ok == 0) then + end + + +-%pretrans devel -p +-if not posix.access("/bin/bash", "x") then +- -- initial installation, no shell, no running glusterfsd +- return 0 +-end +- +--- TODO: move this completely to a lua script +--- For now, we write a temporary bash script and execute that. +- +-script = [[#!/bin/sh +-pidof -c -o %PPID -x glusterfsd &>/dev/null +- +-if [ $? -eq 0 ]; then +- pushd . > /dev/null 2>&1 +- for volume in /var/lib/glusterd/vols/*; do cd $volume; +- vol_type=`grep '^type=' info | awk -F'=' '{print $2}'` +- volume_started=`grep '^status=' info | awk -F'=' '{print $2}'` +- if [ $vol_type -eq 0 ] && [ $volume_started -eq 1 ] ; then +- exit 1; +- fi +- done +- +- popd > /dev/null 2>&1 +- exit 1; +-fi +-]] +- +-ok, how, val = os.execute(script) +-if not (ok == 0) then +- error("Detected running glusterfs processes", ok) +-end +- +- +- + %pretrans fuse -p + if not posix.access("/bin/bash", "x") then + -- initial installation, no shell, no running glusterfsd +-- +1.8.3.1 + diff --git a/0052-geo-rep-IPv6-support.patch b/0052-geo-rep-IPv6-support.patch new file mode 100644 index 0000000..12c6e1b --- /dev/null +++ b/0052-geo-rep-IPv6-support.patch @@ -0,0 +1,299 @@ +From d7bb933742f4d9135621590bf13713633c549af1 Mon Sep 17 00:00:00 2001 +From: Aravinda VK +Date: Thu, 14 Mar 2019 20:06:54 +0530 +Subject: [PATCH 52/52] geo-rep: IPv6 support + +`address_family=inet6` needs to be added while mounting master and +slave volumes in gverify script. + +New option introduced to gluster cli(`--inet6`) which will be used +internally by geo-rep while calling `gluster volume info +--remote-host=`. + +Backport of https://review.gluster.org/22363 + +Fixes: bz#1688231 +Change-Id: I1e0d42cae07158df043e64a2f991882d8c897837 +Signed-off-by: Aravinda VK +Reviewed-on: https://code.engineering.redhat.com/gerrit/167120 +Tested-by: RHGS Build Bot +Reviewed-by: Sunil Kumar Heggodu Gopala Acharya +--- + cli/src/cli.c | 11 ++++++++++ + cli/src/cli.h | 1 + + geo-replication/src/gverify.sh | 22 ++++++++++++++++---- + geo-replication/syncdaemon/argsupgrade.py | 13 +++++++++++- + geo-replication/syncdaemon/gsyncd.py | 1 + + geo-replication/syncdaemon/subcmds.py | 9 +++++++-- + xlators/mgmt/glusterd/src/glusterd-geo-rep.c | 30 ++++++++++++++++++++++++++-- + 7 files changed, 78 insertions(+), 9 deletions(-) + +diff --git a/cli/src/cli.c b/cli/src/cli.c +index 08f117e..c33d152 100644 +--- a/cli/src/cli.c ++++ b/cli/src/cli.c +@@ -433,6 +433,12 @@ cli_opt_parse(char *opt, struct cli_state *state) + return 0; + } + ++ oarg = strtail(opt, "inet6"); ++ if (oarg) { ++ state->address_family = "inet6"; ++ return 0; ++ } ++ + oarg = strtail(opt, "log-file="); + if (oarg) { + state->log_file = oarg; +@@ -679,6 +685,11 @@ cli_rpc_init(struct cli_state *state) + this = THIS; + cli_rpc_prog = &cli_prog; + ++ /* If address family specified in CLI */ ++ if (state->address_family) { ++ addr_family = state->address_family; ++ } ++ + /* Connect to glusterd using the specified method, giving preference + * to a unix socket connection. If nothing is specified, connect to + * the default glusterd socket. +diff --git a/cli/src/cli.h b/cli/src/cli.h +index 5df86d5..b79a0a2 100644 +--- a/cli/src/cli.h ++++ b/cli/src/cli.h +@@ -136,6 +136,7 @@ struct cli_state { + gf_loglevel_t log_level; + + char *glusterd_sock; ++ char *address_family; + }; + + struct cli_local { +diff --git a/geo-replication/src/gverify.sh b/geo-replication/src/gverify.sh +index d048de0..7c88f9f 100755 +--- a/geo-replication/src/gverify.sh ++++ b/geo-replication/src/gverify.sh +@@ -94,6 +94,7 @@ echo $cmd_line; + function master_stats() + { + MASTERVOL=$1; ++ local inet6=$2; + local d; + local i; + local disk_size; +@@ -102,7 +103,12 @@ function master_stats() + local m_status; + + d=$(mktemp -d -t ${0##*/}.XXXXXX 2>/dev/null); +- glusterfs -s localhost --xlator-option="*dht.lookup-unhashed=off" --volfile-id $MASTERVOL -l $master_log_file $d; ++ if [ "$inet6" = "inet6" ]; then ++ glusterfs -s localhost --xlator-option="*dht.lookup-unhashed=off" --xlator-option="transport.address-family=inet6" --volfile-id $MASTERVOL -l $master_log_file $d; ++ else ++ glusterfs -s localhost --xlator-option="*dht.lookup-unhashed=off" --volfile-id $MASTERVOL -l $master_log_file $d; ++ fi ++ + i=$(get_inode_num $d); + if [[ "$i" -ne "1" ]]; then + echo 0:0; +@@ -124,12 +130,18 @@ function slave_stats() + SLAVEUSER=$1; + SLAVEHOST=$2; + SLAVEVOL=$3; ++ local inet6=$4; + local cmd_line; + local ver; + local status; + + d=$(mktemp -d -t ${0##*/}.XXXXXX 2>/dev/null); +- glusterfs --xlator-option="*dht.lookup-unhashed=off" --volfile-server $SLAVEHOST --volfile-id $SLAVEVOL -l $slave_log_file $d; ++ if [ "$inet6" = "inet6" ]; then ++ glusterfs --xlator-option="*dht.lookup-unhashed=off" --xlator-option="transport.address-family=inet6" --volfile-server $SLAVEHOST --volfile-id $SLAVEVOL -l $slave_log_file $d; ++ else ++ glusterfs --xlator-option="*dht.lookup-unhashed=off" --volfile-server $SLAVEHOST --volfile-id $SLAVEVOL -l $slave_log_file $d; ++ fi ++ + i=$(get_inode_num $d); + if [[ "$i" -ne "1" ]]; then + echo 0:0; +@@ -167,6 +179,8 @@ function main() + log_file=$6 + > $log_file + ++ inet6=$7 ++ + # Use FORCE_BLOCKER flag in the error message to differentiate + # between the errors which the force command should bypass + +@@ -204,8 +218,8 @@ function main() + fi; + + ERRORS=0; +- master_data=$(master_stats $1); +- slave_data=$(slave_stats $2 $3 $4); ++ master_data=$(master_stats $1 ${inet6}); ++ slave_data=$(slave_stats $2 $3 $4 ${inet6}); + master_disk_size=$(echo $master_data | cut -f1 -d':'); + slave_disk_size=$(echo $slave_data | cut -f1 -d':'); + master_used_size=$(echo $master_data | cut -f2 -d':'); +diff --git a/geo-replication/syncdaemon/argsupgrade.py b/geo-replication/syncdaemon/argsupgrade.py +index 4018143..7af4063 100644 +--- a/geo-replication/syncdaemon/argsupgrade.py ++++ b/geo-replication/syncdaemon/argsupgrade.py +@@ -84,6 +84,10 @@ def upgrade(): + # fail when it does stat to check the existence. + init_gsyncd_template_conf() + ++ inet6 = False ++ if "--inet6" in sys.argv: ++ inet6 = True ++ + if "--monitor" in sys.argv: + # python gsyncd.py --path=/bricks/b1 + # --monitor -c gsyncd.conf +@@ -147,8 +151,11 @@ def upgrade(): + + user, hname = remote_addr.split("@") + ++ if not inet6: ++ hname = gethostbyname(hname) ++ + print(("ssh://%s@%s:gluster://127.0.0.1:%s" % ( +- user, gethostbyname(hname), vol))) ++ user, hname, vol))) + + sys.exit(0) + elif "--normalize-url" in sys.argv: +@@ -346,3 +353,7 @@ def upgrade(): + + if pargs.reset_sync_time: + sys.argv.append("--reset-sync-time") ++ ++ if inet6: ++ # Add `--inet6` as first argument ++ sys.argv = [sys.argv[0], "--inet6"] + sys.argv[1:] +diff --git a/geo-replication/syncdaemon/gsyncd.py b/geo-replication/syncdaemon/gsyncd.py +index 037f351..effe0ce 100644 +--- a/geo-replication/syncdaemon/gsyncd.py ++++ b/geo-replication/syncdaemon/gsyncd.py +@@ -47,6 +47,7 @@ def main(): + sys.exit(0) + + parser = ArgumentParser() ++ parser.add_argument("--inet6", action="store_true") + sp = parser.add_subparsers(dest="subcmd") + + # Monitor Status File update +diff --git a/geo-replication/syncdaemon/subcmds.py b/geo-replication/syncdaemon/subcmds.py +index 30050ec..4ece7e0 100644 +--- a/geo-replication/syncdaemon/subcmds.py ++++ b/geo-replication/syncdaemon/subcmds.py +@@ -110,8 +110,13 @@ def subcmd_voluuidget(args): + + ParseError = XET.ParseError if hasattr(XET, 'ParseError') else SyntaxError + +- po = Popen(['gluster', '--xml', '--remote-host=' + args.host, +- 'volume', 'info', args.volname], bufsize=0, ++ cmd = ['gluster', '--xml', '--remote-host=' + args.host, ++ 'volume', 'info', args.volname] ++ ++ if args.inet6: ++ cmd.append("--inet6") ++ ++ po = Popen(cmd, bufsize=0, + stdin=None, stdout=PIPE, stderr=PIPE, + universal_newlines=True) + +diff --git a/xlators/mgmt/glusterd/src/glusterd-geo-rep.c b/xlators/mgmt/glusterd/src/glusterd-geo-rep.c +index 49baa58..0f40bea 100644 +--- a/xlators/mgmt/glusterd/src/glusterd-geo-rep.c ++++ b/xlators/mgmt/glusterd/src/glusterd-geo-rep.c +@@ -76,6 +76,19 @@ static char *gsync_reserved_opts[] = {"gluster-command", + static char *gsync_no_restart_opts[] = {"checkpoint", "log_rsync_performance", + "log-rsync-performance", NULL}; + ++void ++set_gsyncd_inet6_arg(runner_t *runner) ++{ ++ xlator_t *this = NULL; ++ char *af; ++ int ret; ++ ++ this = THIS; ++ ret = dict_get_str(this->options, "transport.address-family", &af); ++ if (ret == 0) ++ runner_argprintf(runner, "--%s", af); ++} ++ + int + __glusterd_handle_sys_exec(rpcsvc_request_t *req) + { +@@ -384,6 +397,7 @@ glusterd_urltransform_init(runner_t *runner, const char *transname) + { + runinit(runner); + runner_add_arg(runner, GSYNCD_PREFIX "/gsyncd"); ++ set_gsyncd_inet6_arg(runner); + runner_argprintf(runner, "--%s-url", transname); + } + +@@ -725,6 +739,7 @@ glusterd_get_slave_voluuid(char *slave_host, char *slave_vol, char *vol_uuid) + + runinit(&runner); + runner_add_arg(&runner, GSYNCD_PREFIX "/gsyncd"); ++ set_gsyncd_inet6_arg(&runner); + runner_add_arg(&runner, "--slavevoluuid-get"); + runner_argprintf(&runner, "%s::%s", slave_host, slave_vol); + +@@ -788,6 +803,7 @@ glusterd_gsync_get_config(char *master, char *slave, char *conf_path, + runinit(&runner); + runner_add_args(&runner, GSYNCD_PREFIX "/gsyncd", "-c", NULL); + runner_argprintf(&runner, "%s", conf_path); ++ set_gsyncd_inet6_arg(&runner); + runner_argprintf(&runner, "--iprefix=%s", DATADIR); + runner_argprintf(&runner, ":%s", master); + runner_add_args(&runner, slave, "--config-get-all", NULL); +@@ -917,6 +933,7 @@ glusterd_gsync_get_status(char *master, char *slave, char *conf_path, + runinit(&runner); + runner_add_args(&runner, GSYNCD_PREFIX "/gsyncd", "-c", NULL); + runner_argprintf(&runner, "%s", conf_path); ++ set_gsyncd_inet6_arg(&runner); + runner_argprintf(&runner, "--iprefix=%s", DATADIR); + runner_argprintf(&runner, ":%s", master); + runner_add_args(&runner, slave, "--status-get", NULL); +@@ -937,6 +954,7 @@ glusterd_gsync_get_param_file(char *prmfile, const char *param, char *master, + runinit(&runner); + runner_add_args(&runner, GSYNCD_PREFIX "/gsyncd", "-c", NULL); + runner_argprintf(&runner, "%s", conf_path); ++ set_gsyncd_inet6_arg(&runner); + runner_argprintf(&runner, "--iprefix=%s", DATADIR); + runner_argprintf(&runner, ":%s", master); + runner_add_args(&runner, slave, "--config-get", NULL); +@@ -2811,6 +2829,7 @@ glusterd_verify_slave(char *volname, char *slave_url, char *slave_vol, + char *slave_ip = NULL; + glusterd_conf_t *priv = NULL; + xlator_t *this = NULL; ++ char *af = NULL; + + this = THIS; + GF_ASSERT(this); +@@ -2852,9 +2871,16 @@ glusterd_verify_slave(char *volname, char *slave_url, char *slave_vol, + runner_argprintf(&runner, "%s", slave_vol); + runner_argprintf(&runner, "%d", ssh_port); + runner_argprintf(&runner, "%s", log_file_path); +- gf_msg_debug(this->name, 0, "gverify Args = %s %s %s %s %s %s %s", ++ ret = dict_get_str(this->options, "transport.address-family", &af); ++ if (ret) ++ af = "-"; ++ ++ runner_argprintf(&runner, "%s", af); ++ ++ gf_msg_debug(this->name, 0, "gverify Args = %s %s %s %s %s %s %s %s", + runner.argv[0], runner.argv[1], runner.argv[2], runner.argv[3], +- runner.argv[4], runner.argv[5], runner.argv[6]); ++ runner.argv[4], runner.argv[5], runner.argv[6], ++ runner.argv[7]); + runner_redir(&runner, STDOUT_FILENO, RUN_PIPE); + synclock_unlock(&priv->big_lock); + ret = runner_run(&runner); +-- +1.8.3.1 + diff --git a/glusterfs.spec b/glusterfs.spec index 7a79d4d..eaa9ebb 100644 --- a/glusterfs.spec +++ b/glusterfs.spec @@ -9,50 +9,104 @@ ## All argument definitions should be placed here and keep them sorted ## -# if you wish to compile an rpm with debugging... -# rpmbuild -ta glusterfs-3.12.2.tar.gz --with debug -%{?_with_debug:%global _with_debug --enable-debug} +# asan +# if you wish to compile an rpm with address sanitizer... +# rpmbuild -ta glusterfs-6.0.tar.gz --with asan +%{?_with_asan:%global _with_asan --enable-asan} -# if you wish to compile an rpm to run all processes under valgrind... -# rpmbuild -ta glusterfs-3.12.2.tar.gz --with valgrind -%{?_with_valgrind:%global _with_valgrind --enable-valgrind} +%if ( 0%{?rhel} && 0%{?rhel} < 7 ) +%global _with_asan %{nil} +%endif +# bd +# if you wish to compile an rpm without the BD map support... +# rpmbuild -ta glusterfs-6.0.tar.gz --without bd +%{?_without_bd:%global _without_bd --disable-bd-xlator} + +%if ( 0%{?rhel} && 0%{?rhel} > 7 ) +%global _without_bd --without-bd +%endif + +# cmocka # if you wish to compile an rpm with cmocka unit testing... -# rpmbuild -ta glusterfs-3.12.2.tar.gz --with cmocka +# rpmbuild -ta glusterfs-6.0.tar.gz --with cmocka %{?_with_cmocka:%global _with_cmocka --enable-cmocka} +# debug +# if you wish to compile an rpm with debugging... +# rpmbuild -ta glusterfs-6.0.tar.gz --with debug +%{?_with_debug:%global _with_debug --enable-debug} + +# epoll +# if you wish to compile an rpm without epoll... +# rpmbuild -ta glusterfs-6.0.tar.gz --without epoll +%{?_without_epoll:%global _without_epoll --disable-epoll} + +# fusermount +# if you wish to compile an rpm without fusermount... +# rpmbuild -ta glusterfs-6.0.tar.gz --without fusermount +%{?_without_fusermount:%global _without_fusermount --disable-fusermount} + +# geo-rep +# if you wish to compile an rpm without geo-replication support, compile like this... +# rpmbuild -ta glusterfs-6.0.tar.gz --without georeplication +%{?_without_georeplication:%global _without_georeplication --disable-georeplication} + +# gnfs +# if you wish to compile an rpm with the legacy gNFS server xlator +# rpmbuild -ta glusterfs-6.0.tar.gz --with gnfs +%{?_with_gnfs:%global _with_gnfs --enable-gnfs} + +# ipv6default +# if you wish to compile an rpm with IPv6 default... +# rpmbuild -ta glusterfs-6.0.tar.gz --with ipv6default +%{?_with_ipv6default:%global _with_ipv6default --with-ipv6-default} + +# libtirpc +# if you wish to compile an rpm without TIRPC (i.e. use legacy glibc rpc) +# rpmbuild -ta glusterfs-6.0.tar.gz --without libtirpc +%{?_without_libtirpc:%global _without_libtirpc --without-libtirpc} + +# Do not use libtirpc on EL6, it does not have xdr_uint64_t() and xdr_uint32_t +# Do not use libtirpc on EL7, it does not have xdr_sizeof() +%if ( 0%{?rhel} && 0%{?rhel} <= 7 ) +%global _without_libtirpc --without-libtirpc +%endif + + +# ocf +# if you wish to compile an rpm without the OCF resource agents... +# rpmbuild -ta glusterfs-6.0.tar.gz --without ocf +%{?_without_ocf:%global _without_ocf --without-ocf} + +# rdma # if you wish to compile an rpm without rdma support, compile like this... -# rpmbuild -ta glusterfs-3.12.2.tar.gz --without rdma +# rpmbuild -ta glusterfs-6.0.tar.gz --without rdma %{?_without_rdma:%global _without_rdma --disable-ibverbs} -# No RDMA Support on s390(x) -%ifarch s390 s390x armv7hl +# No RDMA Support on 32-bit ARM +%ifarch armv7hl %global _without_rdma --disable-ibverbs %endif -# if you wish to compile an rpm without epoll... -# rpmbuild -ta glusterfs-3.12.2.tar.gz --without epoll -%{?_without_epoll:%global _without_epoll --disable-epoll} +# server +# if you wish to build rpms without server components, compile like this +# rpmbuild -ta glusterfs-6.0.tar.gz --without server +%{?_without_server:%global _without_server --without-server} -# if you wish to compile an rpm without fusermount... -# rpmbuild -ta glusterfs-3.12.2.tar.gz --without fusermount -%{?_without_fusermount:%global _without_fusermount --disable-fusermount} - -# if you wish to compile an rpm without geo-replication support, compile like this... -# rpmbuild -ta glusterfs-3.12.2.tar.gz --without georeplication -%{?_without_georeplication:%global _without_georeplication --disable-georeplication} - -# Disable geo-replication on EL5, as its default Python is too old -%if ( 0%{?rhel} && 0%{?rhel} < 6 ) -%global _without_georeplication --disable-georeplication +# disable server components forcefully as rhel <= 6 +%if ( 0%{?rhel} ) +%if (!(( "%{?dist}" == ".el6rhs" ) || ( "%{?dist}" == ".el7rhs" ) || ( "%{?dist}" == ".el7rhgs" ))) +%global _without_server --without-server +%endif %endif -# if you wish to compile an rpm without the OCF resource agents... -# rpmbuild -ta glusterfs-3.12.2.tar.gz --without ocf -%{?_without_ocf:%global _without_ocf --without-ocf} +%global _without_extra_xlators 1 +%global _without_regression_tests 1 +# syslog # if you wish to build rpms without syslog logging, compile like this -# rpmbuild -ta glusterfs-3.12.2.tar.gz --without syslog +# rpmbuild -ta glusterfs-6.0.tar.gz --without syslog %{?_without_syslog:%global _without_syslog --disable-syslog} # disable syslog forcefully as rhel <= 6 doesn't have rsyslog or rsyslog-mmcount @@ -63,42 +117,25 @@ %global _without_syslog --disable-syslog %endif -# if you wish to compile an rpm without the BD map support... -# rpmbuild -ta glusterfs-3.12.2.tar.gz --without bd -%{?_without_bd:%global _without_bd --disable-bd-xlator} +# tsan +# if you wish to compile an rpm with thread sanitizer... +# rpmbuild -ta glusterfs-6.0.tar.gz --with tsan +%{?_with_tsan:%global _with_tsan --enable-tsan} -%if ( 0%{?rhel} && 0%{?rhel} < 6 || 0%{?sles_version} ) -%global _without_bd --disable-bd-xlator +%if ( 0%{?rhel} && 0%{?rhel} < 7 ) +%global _with_tsan %{nil} %endif -# Disable data-tiering on EL5, sqlite is too old -%if ( 0%{?rhel} && 0%{?rhel} < 6 ) -%global _without_tiering --disable-tiering -%endif - -# if you wish not to build server rpms, compile like this. -# rpmbuild -ta glusterfs-3.12.2.tar.gz --without server - -%global _build_server 1 -%if "%{?_without_server}" -%global _build_server 0 -%endif - -%if ( "%{?dist}" == ".el6rhs" ) || ( "%{?dist}" == ".el7rhs" ) || ( "%{?dist}" == ".el7rhgs" ) -%global _build_server 1 -%else -%global _build_server 0 -%global _without_georeplication --disable-georeplication -%endif - -%global _without_extra_xlators 1 -%global _without_regression_tests 1 +# valgrind +# if you wish to compile an rpm to run all processes under valgrind... +# rpmbuild -ta glusterfs-6.0.tar.gz --with valgrind +%{?_with_valgrind:%global _with_valgrind --enable-valgrind} ##----------------------------------------------------------------------------- ## All %%global definitions should be placed here and keep them sorted ## -%if ( 0%{?fedora} && 0%{?fedora} > 16 ) || ( 0%{?rhel} && 0%{?rhel} > 6 ) +%if ( 0%{?fedora} ) || ( 0%{?rhel} && 0%{?rhel} > 6 ) %global _with_systemd true %endif @@ -112,9 +149,20 @@ %global _with_tmpfilesdir --without-tmpfilesdir %endif -# Eventing -%if ( 0%{?rhel} && 0%{?rhel} < 6 ) +# without server should also disable some server-only components +%if 0%{?_without_server:1} %global _without_events --disable-events +%global _without_georeplication --disable-georeplication +%global _with_gnfs %{nil} +%global _without_ocf --without-ocf +%endif + +%if ( 0%{?fedora} ) || ( 0%{?rhel} && 0%{?rhel} > 7 ) +%global _usepython3 1 +%global _pythonver 3 +%else +%global _usepython3 0 +%global _pythonver 2 %endif # From https://fedoraproject.org/wiki/Packaging:Python#Macros @@ -125,45 +173,39 @@ %endif %if ( 0%{?_with_systemd:1} ) -%global _init_enable() /bin/systemctl enable %1.service ; -%global _init_disable() /bin/systemctl disable %1.service ; -%global _init_restart() /bin/systemctl try-restart %1.service ; -%global _init_start() /bin/systemctl start %1.service ; -%global _init_stop() /bin/systemctl stop %1.service ; -%global _init_install() install -D -p -m 0644 %1 %{buildroot}%{_unitdir}/%2.service ; +%global service_start() /bin/systemctl --quiet start %1.service || : \ +%{nil} +%global service_stop() /bin/systemctl --quiet stop %1.service || :\ +%{nil} +%global service_install() install -D -p -m 0644 %1.service %{buildroot}%2 \ +%{nil} # can't seem to make a generic macro that works -%global _init_glusterd %{_unitdir}/glusterd.service -%global _init_glusterfsd %{_unitdir}/glusterfsd.service -%global _init_glustereventsd %{_unitdir}/glustereventsd.service -%global _init_glusterfssharedstorage %{_unitdir}/glusterfssharedstorage.service +%global glusterd_svcfile %{_unitdir}/glusterd.service +%global glusterfsd_svcfile %{_unitdir}/glusterfsd.service +%global glusterta_svcfile %{_unitdir}/gluster-ta-volume.service +%global glustereventsd_svcfile %{_unitdir}/glustereventsd.service +%global glusterfssharedstorage_svcfile %{_unitdir}/glusterfssharedstorage.service %else -%global _init_enable() /sbin/chkconfig --add %1 ; -%global _init_disable() /sbin/chkconfig --del %1 ; -%global _init_restart() /sbin/service %1 condrestart &>/dev/null ; -%global _init_start() /sbin/service %1 start &>/dev/null ; -%global _init_stop() /sbin/service %1 stop &>/dev/null ; -%global _init_install() install -D -p -m 0755 %1 %{buildroot}%{_sysconfdir}/init.d/%2 ; +%global systemd_post() /sbin/chkconfig --add %1 >/dev/null 2>&1 || : \ +%{nil} +%global systemd_preun() /sbin/chkconfig --del %1 >/dev/null 2>&1 || : \ +%{nil} +%global systemd_postun_with_restart() /sbin/service %1 condrestart >/dev/null 2>&1 || : \ +%{nil} +%global service_start() /sbin/service %1 start >/dev/null 2>&1 || : \ +%{nil} +%global service_stop() /sbin/service %1 stop >/dev/null 2>&1 || : \ +%{nil} +%global service_install() install -D -p -m 0755 %1.init %{buildroot}%2 \ +%{nil} # can't seem to make a generic macro that works -%global _init_glusterd %{_sysconfdir}/init.d/glusterd -%global _init_glusterfsd %{_sysconfdir}/init.d/glusterfsd -%global _init_glustereventsd %{_sysconfdir}/init.d/glustereventsd -%endif - -%if ( 0%{_for_fedora_koji_builds} ) -%if ( 0%{?_with_systemd:1} ) -%global glusterfsd_service glusterfsd.service -%else -%global glusterfsd_service glusterfsd.init -%endif +%global glusterd_svcfile %{_sysconfdir}/init.d/glusterd +%global glusterfsd_svcfile %{_sysconfdir}/init.d/glusterfsd +%global glustereventsd_svcfile %{_sysconfdir}/init.d/glustereventsd %endif %{!?_pkgdocdir: %global _pkgdocdir %{_docdir}/%{name}-%{version}} -%if ( 0%{?rhel} && 0%{?rhel} < 6 ) -# _sharedstatedir is not provided by RHEL5 -%global _sharedstatedir /var/lib -%endif - # We do not want to generate useless provides and requires for xlator # .so files to be set for glusterfs packages. # Filter all generated: @@ -191,29 +233,23 @@ Version: 3.8.0 Release: 0.1%{?prereltag:.%{prereltag}}%{?dist} %else Name: glusterfs -Version: 3.12.2 -Release: 47%{?dist} +Version: 6.0 +Release: 1%{?dist} +ExcludeArch: i686 %endif License: GPLv2 or LGPLv3+ -Group: System Environment/Base -URL: http://gluster.readthedocs.io/en/latest/ +URL: http://docs.gluster.org/ %if ( 0%{_for_fedora_koji_builds} ) Source0: http://bits.gluster.org/pub/gluster/glusterfs/src/glusterfs-%{version}%{?prereltag}.tar.gz Source1: glusterd.sysconfig Source2: glusterfsd.sysconfig -Source6: rhel5-load-fuse-modules Source7: glusterfsd.service Source8: glusterfsd.init %else -Source0: glusterfs-3.12.2.tar.gz +Source0: glusterfs-6.0.tar.gz %endif -BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX) - Requires(pre): shadow-utils -%if ( 0%{?rhel} && 0%{?rhel} <= 5 ) -BuildRequires: python-simplejson -%endif %if ( 0%{?_with_systemd:1} ) BuildRequires: systemd %endif @@ -222,34 +258,36 @@ Requires: %{name}-libs%{?_isa} = %{version}-%{release} %if ( 0%{?_with_systemd:1} ) %{?systemd_requires} %endif +%if 0%{?_with_asan:1} && !( 0%{?rhel} && 0%{?rhel} < 7 ) +BuildRequires: libasan +%endif +%if 0%{?_with_tsan:1} && !( 0%{?rhel} && 0%{?rhel} < 7 ) +BuildRequires: libtsan +%endif BuildRequires: git BuildRequires: bison flex BuildRequires: gcc make libtool BuildRequires: ncurses-devel readline-devel BuildRequires: libxml2-devel openssl-devel BuildRequires: libaio-devel libacl-devel -BuildRequires: python2-devel -%if ( 0%{?fedora} && 0%{?fedora} < 26 ) || ( 0%{?rhel} ) +BuildRequires: python%{_pythonver}-devel +%if ( 0%{?rhel} && 0%{?rhel} < 8 ) BuildRequires: python-ctypes %endif +%if ( 0%{?_with_ipv6default:1} ) || ( 0%{!?_without_libtirpc:1} ) +BuildRequires: libtirpc-devel +%endif +%if ( 0%{?fedora} && 0%{?fedora} > 27 ) || ( 0%{?rhel} && 0%{?rhel} > 7 ) +BuildRequires: rpcgen +%endif BuildRequires: userspace-rcu-devel >= 0.7 %if ( 0%{?rhel} && 0%{?rhel} <= 6 ) BuildRequires: automake %endif -%if ( 0%{?rhel} && 0%{?rhel} <= 5 ) -BuildRequires: e2fsprogs-devel -%else BuildRequires: libuuid-devel -%endif %if ( 0%{?_with_cmocka:1} ) BuildRequires: libcmocka-devel >= 1.0.1 %endif -%if ( 0%{!?_without_tiering:1} ) -BuildRequires: sqlite-devel -%endif -%if ( 0%{!?_without_bd:1} ) -BuildRequires: lvm2-devel -%endif %if ( 0%{!?_without_georeplication:1} ) BuildRequires: libattr-devel %endif @@ -262,547 +300,65 @@ Obsoletes: hekafs Obsoletes: %{name}-common < %{version}-%{release} Obsoletes: %{name}-core < %{version}-%{release} Obsoletes: %{name}-ufo +Obsoletes: %{name}-ganesha +%if ( 0%{!?_with_gnfs:1} ) +Obsoletes: %{name}-gnfs +%endif Provides: %{name}-common = %{version}-%{release} Provides: %{name}-core = %{version}-%{release} -# Patch0001: 0001-Update-rfc.sh-to-rhgs-3.4.0.patch +# Patch0001: 0001-Update-rfc.sh-to-rhgs-3.5.0.patch Patch0002: 0002-glusterd-fix-op-versions-for-RHS-backwards-compatabi.patch -Patch0003: 0003-tier-ctr-sql-Dafault-values-for-sql-cache-and-wal-si.patch -Patch0004: 0004-rpc-set-bind-insecure-to-off-by-default.patch -Patch0005: 0005-glusterd-spec-fixing-autogen-issue.patch -Patch0006: 0006-libglusterfs-glusterd-Fix-compilation-errors.patch -Patch0007: 0007-build-remove-ghost-directory-entries.patch -Patch0008: 0008-build-add-RHGS-specific-changes.patch -Patch0009: 0009-secalert-remove-setuid-bit-for-fusermount-glusterfs.patch -Patch0010: 0010-build-packaging-corrections-for-RHEL-5.patch -Patch0011: 0011-build-introduce-security-hardening-flags-in-gluster.patch -Patch0012: 0012-spec-fix-add-pre-transaction-scripts-for-geo-rep-and.patch -Patch0013: 0013-rpm-glusterfs-devel-for-client-builds-should-not-dep.patch -Patch0014: 0014-build-add-pretrans-check.patch -Patch0015: 0015-build-exclude-libgfdb.pc-conditionally.patch -Patch0016: 0016-build-exclude-glusterfs.xml-on-rhel-7-client-build.patch -Patch0017: 0017-glusterd-fix-info-file-checksum-mismatch-during-upgr.patch -Patch0018: 0018-build-spec-file-conflict-resolution.patch -Patch0019: 0019-build-dependency-error-during-upgrade.patch -Patch0020: 0020-eventsapi-Fix-eventtypes.h-header-generation-with-Py.patch -Patch0021: 0021-syscall-remove-preadv-and-pwritev-sys-wrappers.patch -Patch0022: 0022-build-ignore-sbindir-conf.py-for-RHEL-5.patch -Patch0023: 0023-build-randomize-temp-file-names-in-pretrans-scriptle.patch -Patch0024: 0024-glusterd-gNFS-On-post-upgrade-to-3.2-disable-gNFS-fo.patch -Patch0025: 0025-build-Add-dependency-on-netstat-for-glusterfs-ganesh.patch -Patch0026: 0026-glusterd-gNFS-explicitly-set-nfs.disable-to-off-afte.patch -Patch0027: 0027-glusterd-spawn-nfs-daemon-in-op-version-bump-if-nfs..patch -Patch0028: 0028-glusterd-parallel-readdir-Change-the-op-version-of-p.patch -Patch0029: 0029-build-exclude-glusterfssharedstorage.service-and-mou.patch -Patch0030: 0030-build-make-gf_attach-available-in-glusterfs-server.patch -Patch0031: 0031-glusterd-Revert-op-version-for-cluster.max-brick-per.patch -Patch0032: 0032-cli-Add-message-for-user-before-modifying-brick-mult.patch -Patch0033: 0033-build-launch-glusterd-upgrade-after-all-new-bits-are.patch -Patch0034: 0034-build-remove-pretrans-script-for-python-gluster.patch -Patch0035: 0035-glusterd-regenerate-volfiles-on-op-version-bump-up.patch -Patch0036: 0036-mount-fuse-Fix-parsing-of-vol_id-for-snapshot-volume.patch -Patch0037: 0037-protocol-auth-use-the-proper-validation-method.patch -Patch0038: 0038-protocol-server-fix-the-comparision-logic-in-case-of.patch -Patch0039: 0039-protocol-client-handle-the-subdir-handshake-properly.patch -Patch0040: 0040-glusterd-delete-source-brick-only-once-in-reset-bric.patch -Patch0041: 0041-glusterd-persist-brickinfo-s-port-change-into-gluste.patch -Patch0042: 0042-glusterd-restart-the-brick-if-qorum-status-is-NOT_AP.patch -Patch0043: 0043-glusterd-clean-up-portmap-on-brick-disconnect.patch -Patch0044: 0044-glusterd-fix-brick-restart-parallelism.patch -Patch0045: 0045-glusterd-introduce-max-port-range.patch -Patch0046: 0046-Revert-build-conditionally-build-legacy-gNFS-server-.patch -Patch0047: 0047-Revert-glusterd-skip-nfs-svc-reconfigure-if-nfs-xlat.patch -Patch0048: 0048-glusterd-introduce-timer-in-mgmt_v3_lock.patch -Patch0049: 0049-Revert-packaging-ganesha-remove-glusterfs-ganesha-su.patch -Patch0050: 0050-Revert-glusterd-storhaug-remove-ganesha.patch -Patch0051: 0051-Revert-storhaug-HA-first-step-remove-resource-agents.patch -Patch0052: 0052-common-ha-fixes-for-Debian-based-systems.patch -Patch0053: 0053-ganesha-scripts-Remove-export-entries-from-ganesha.c.patch -Patch0054: 0054-glusterd-ganesha-During-volume-delete-remove-the-gan.patch -Patch0055: 0055-glusterd-ganesha-throw-proper-error-for-gluster-nfs-.patch -Patch0056: 0056-ganesha-scripts-Stop-ganesha-process-on-all-nodes-if.patch -Patch0057: 0057-ganesha-allow-refresh-config-and-volume-export-unexp.patch -Patch0058: 0058-glusterd-ganesha-perform-removal-of-ganesha.conf-on-.patch -Patch0059: 0059-glusterd-ganesha-update-cache-invalidation-properly-.patch -Patch0060: 0060-glusterd-ganesha-return-proper-value-in-pre_setup.patch -Patch0061: 0061-ganesha-scripts-remove-dependency-over-export-config.patch -Patch0062: 0062-glusterd-ganesha-add-proper-NULL-check-in-manage_exp.patch -Patch0063: 0063-ganesha-minor-improvments-for-commit-e91cdf4-17081.patch -Patch0064: 0064-common-ha-surviving-ganesha.nfsd-not-put-in-grace-on.patch -Patch0065: 0065-common-ha-enable-and-disable-selinux-ganesha_use_fus.patch -Patch0066: 0066-packaging-glusterfs-ganesha-update-sometimes-fails-s.patch -Patch0067: 0067-packaging-own-files-in-var-run-gluster-shared_storag.patch -Patch0068: 0068-common-ha-enable-and-disable-selinux-gluster_use_exe.patch -Patch0069: 0069-ganesha-ha-don-t-set-SELinux-booleans-if-SELinux-is-.patch -Patch0070: 0070-build-remove-ganesha-dependency-on-selinux-policy.patch -Patch0071: 0071-common-ha-enable-pacemaker-at-end-of-setup.patch -Patch0072: 0072-common-ha-Fix-an-incorrect-syntax-during-setup.patch -Patch0073: 0073-Fix-build-issues-related-to-nfs-ganesha-package.patch -Patch0074: 0074-build-make-var-run-available-on-RHEL-6.patch -Patch0075: 0075-cli-gluster-help-changes.patch -Patch0076: 0076-cluster-ec-Handle-parallel-get_size_version.patch -Patch0077: 0077-cluster-ec-add-functions-for-stripe-alignment.patch -Patch0078: 0078-cluster-afr-Honor-default-timeout-of-5min-for-analyz.patch -Patch0079: 0079-cluster-ec-Allow-parallel-writes-in-EC-if-possible.patch -Patch0080: 0080-heal-New-feature-heal-info-summary-to-list-the-statu.patch -Patch0081: 0081-cluster-dht-Don-t-set-ACLs-on-linkto-file.patch -Patch0082: 0082-cluster-afr-Print-heal-info-summary-output-in-stream.patch -Patch0083: 0083-cluster-afr-Print-heal-info-split-brain-output-in-st.patch -Patch0084: 0084-cluster-afr-Fix-for-arbiter-becoming-source.patch -Patch0085: 0085-snapshot-Issue-with-other-processes-accessing-the-mo.patch -Patch0086: 0086-snapshot-lvm-cleanup-during-snapshot-remove.patch -Patch0087: 0087-glusterd-Validate-changelog-on-geo-rep-volume.patch -Patch0088: 0088-cluster-ec-Implement-DISCARD-FOP-for-EC.patch -Patch0089: 0089-geo-rep-Filter-out-volume-mark-xattr.patch -Patch0090: 0090-Quota-Adding-man-page-for-quota.patch -Patch0091: 0091-extras-scripts-to-control-CPU-MEMORY-for-any-gluster.patch -Patch0092: 0092-posix-Needs-to-reserve-disk-space-to-prevent-the-bri.patch -Patch0093: 0093-posix-Ignore-disk-space-reserve-check-for-internal-F.patch -Patch0094: 0094-cluster-afr-Fail-open-on-split-brain.patch -Patch0095: 0095-extras-hooks-Fix-errors-reported-via-shellcheck-util.patch -Patch0096: 0096-extras-hooks-Honour-all-input-arguments-to-scripts.patch -Patch0097: 0097-extras-hooks-Fix-getopt-usage.patch -Patch0098: 0098-snapshot-snapshot-creation-failed-after-brick-reset-.patch -Patch0099: 0099-Tier-Stop-tierd-for-detach-start.patch -Patch0100: 0100-cluster-ec-Improve-heal-info-command-to-handle-obvio.patch -Patch0101: 0101-cluster-ec-Prevent-self-heal-to-work-after-PARENT_DO.patch -Patch0102: 0102-libglusterfs-fix-the-call_stack_set_group-function.patch -Patch0103: 0103-features-locks-Fix-memory-leaks.patch -Patch0104: 0104-cluster-dht-fix-crash-when-deleting-directories.patch -Patch0105: 0105-glusterd-Fix-glusterd-mem-leaks.patch -Patch0106: 0106-glusterd-Free-up-svc-conn-on-volume-delete.patch -Patch0107: 0107-feature-bitrot-remove-internal-xattrs-from-lookup-cb.patch -Patch0108: 0108-mount-fuse-use-fstat-in-getattr-implementation-if-an.patch -Patch0109: 0109-mount-fuse-never-fail-open-dir-with-ENOENT.patch -Patch0110: 0110-Revert-mount-fuse-report-ESTALE-as-ENOENT.patch -Patch0111: 0111-cluster-dht-don-t-overfill-the-buffer-in-readdir-p.patch -Patch0112: 0112-write-behind-Allow-trickling-writes-to-be-configurab.patch -Patch0113: 0113-gfapi-set-lkowner-in-glfd.patch -Patch0114: 0114-eventsapi-Add-JWT-signing-support.patch -Patch0115: 0115-eventsapi-JWT-signing-without-external-dependency.patch -Patch0116: 0116-eventsapi-HTTPS-support-for-Webhooks.patch -Patch0117: 0117-geo-rep-Log-message-improvements.patch -Patch0118: 0118-snapshot-after-brick-reset-replace-snapshot-creation.patch -Patch0119: 0119-geo-rep-Fix-data-sync-issue-during-hardlink-rename.patch -Patch0120: 0120-glusterd-connect-to-an-existing-brick-process-when-q.patch -Patch0121: 0121-cluster-ec-OpenFD-heal-implementation-for-EC.patch -Patch0122: 0122-tests-Use-dev-urandom-instead-of-dev-random-for-dd.patch -Patch0123: 0123-quota-fixes-issue-in-quota.conf-when-setting-large-n.patch -Patch0124: 0124-build-remove-ExclusiveArch-from-spec-file.patch -Patch0125: 0125-cluster-afr-Fixing-the-flaws-in-arbiter-becoming-sou.patch -Patch0126: 0126-spec-unpackaged-files-found-for-RHEL-7-client-build.patch -Patch0127: 0127-spec-unpackaged-files-found-for-RHEL-7-client-build.patch -Patch0128: 0128-build-remove-pretrans-script-for-ganesha.patch -Patch0129: 0129-posix-delete-stale-gfid-handles-in-nameless-lookup.patch -Patch0130: 0130-md-cache-avoid-checking-the-xattr-value-buffer-with-.patch -Patch0131: 0131-readdir-ahead-Add-parallel-readdir-option-in-readdir.patch -Patch0132: 0132-posix-In-getxattr-honor-the-wildcard.patch -Patch0133: 0133-upcall-Allow-md-cache-to-specify-invalidations-on-xa.patch -Patch0134: 0134-cli-Fixed-a-use_after_free.patch -Patch0135: 0135-cli-commands-are-missing-in-man-page.patch -Patch0136: 0136-glusterd-Nullify-pmap-entry-for-bricks-belonging-to-.patch -Patch0137: 0137-bitrot-improved-cli-report-after-bitrot-operatoin.patch -Patch0138: 0138-glusterd-enable-brick-multiplexing-by-default.patch -Patch0139: 0139-libglusterfs-Reset-errno-before-call.patch -Patch0140: 0140-md-cache-Add-additional-samba-and-macOS-specific-EAs.patch -Patch0141: 0141-rpc-Showing-some-unusual-timer-error-logs-during-bri.patch -Patch0142: 0142-cluster-dht-Add-migration-checks-to-dht_-f-xattrop.patch -Patch0143: 0143-glusterd-store-handle-the-case-of-fsid-being-set-to-.patch -Patch0144: 0144-cluster-dht-Unlink-linkto-files-as-root.patch -Patch0145: 0145-glusterd-optimize-glusterd-import-volumes-code-path.patch -Patch0146: 0146-cluster-dht-Cleanup-on-fallocate-failure.patch -Patch0147: 0147-glusterd-import-volumes-in-separate-synctask.patch -Patch0148: 0148-glusterd-tier-is_tier_enabled-inserted-causing-check.patch -Patch0149: 0149-cluster-ec-EC-DISCARD-doesn-t-punch-hole-properly.patch -Patch0150: 0150-dht-Fill-first_up_subvol-before-use-in-dht_opendir.patch -Patch0151: 0151-geo-rep-Improve-geo-rep-pre-validation-logs.patch -Patch0152: 0152-glusterfind-Speed-up-gfid-lookup-100x-by-using-an-SQ.patch -Patch0153: 0153-afr-add-quorum-checks-in-post-op.patch -Patch0154: 0154-afr-capture-the-correct-errno-in-post-op-quorum-chec.patch -Patch0155: 0155-afr-don-t-treat-all-cases-all-bricks-being-blamed-as.patch -Patch0156: 0156-performance-write-behind-fix-bug-while-handling-shor.patch -Patch0157: 0157-cluster-afr-remove-unnecessary-child_up-initializati.patch -Patch0158: 0158-cluster-ec-create-eager-lock-option-for-non-regular-.patch -Patch0159: 0159-extras-hooks-Fix-S10selinux-label-brick.sh-hook-scri.patch -Patch0160: 0160-common-ha-enable-and-disable-selinux-ganesha_use_fus.patch -Patch0161: 0161-cluster-dht-Fixed-a-typo.patch -Patch0162: 0162-cluster-dht-Handle-single-dht-child-in-dht_lookup.patch -Patch0163: 0163-glusterd-compare-uuid-instead-of-hostname-while-find.patch -Patch0164: 0164-geo-rep-Remove-lazy-umount-and-use-mount-namespaces.patch -Patch0165: 0165-cluster-dht-Ignore-ENODATA-from-getxattr-for-posix-a.patch -Patch0166: 0166-rpcsvc-scale-rpcsvc_request_handler-threads.patch -Patch0167: 0167-glusterd-ganesha-change-voltype-for-ganesha.enable-i.patch -Patch0168: 0168-features-shard-Pass-the-correct-block-num-to-store-i.patch -Patch0169: 0169-features-shard-Leverage-block_num-info-in-inode-ctx-.patch -Patch0170: 0170-features-shard-Fix-shard-inode-refcount-when-it-s-pa.patch -Patch0171: 0171-features-shard-Upon-FSYNC-from-upper-layers-wind-fsy.patch -Patch0172: 0172-glusterd-add-profile_enabled-flag-in-get-state.patch -Patch0173: 0173-packaging-adding-missed-part-from-5eed664-while-back.patch -Patch0174: 0174-hooks-add-a-script-to-stat-the-subdirs-in-add-brick.patch -Patch0175: 0175-rpc-make-actor-search-parallel.patch -Patch0176: 0176-glusterd-volume-get-fixes-for-client-io-threads-quor.patch -Patch0177: 0177-hooks-fix-workdir-in-S13create-subdir-mounts.sh.patch -Patch0178: 0178-cluster-ec-Do-lock-conflict-check-correctly-for-wait.patch -Patch0179: 0179-packaging-adding-missed-part-from-5eed664-while-back.patch -Patch0180: 0180-packaging-adding-missed-part-from-5eed664-while-back.patch -Patch0181: 0181-glusterd-get-state-memory-leak-fix.patch -Patch0182: 0182-glusterd-Fix-coverity-issues-in-glusterd-handler.c.patch -Patch0183: 0183-cluster-afr-Fix-dict-leak-in-pre-op.patch -Patch0184: 0184-cli-glusterfsd-remove-copyright-information.patch -Patch0185: 0185-rpcsvc-correct-event-thread-scaling.patch -Patch0186: 0186-cli-Remove-upstream-doc-reference.patch -Patch0187: 0187-features-shard-Do-list_del_init-while-list-memory-is.patch -Patch0188: 0188-georep-Pause-Resume-of-geo-replication-with-wrong-us.patch -Patch0189: 0189-fuse-enable-proper-fgetattr-like-semantics.patch -Patch0190: 0190-cluster-afr-Adding-option-to-take-full-file-lock.patch -Patch0191: 0191-cluster-afr-Make-afr_fsync-a-transaction.patch -Patch0192: 0192-cluster-afr-Remove-compound-fops-usage-in-afr.patch -Patch0193: 0193-cluster-afr-Remove-unused-code-paths.patch -Patch0194: 0194-cluster-afr-Make-AFR-eager-locking-similar-to-EC.patch -Patch0195: 0195-storage-posix-Add-active-fd-count-option-in-gluster.patch -Patch0196: 0196-cluster-afr-Switch-to-active-fd-count-for-open-fd-ch.patch -Patch0197: 0197-glusterd-ganesha-create-remove-export-file-only-from.patch -Patch0198: 0198-cluster-ec-Change-default-read-policy-to-gfid-hash.patch -Patch0199: 0199-cluster-ec-avoid-delays-in-self-heal.patch -Patch0200: 0200-quick-read-Discard-cache-for-fallocate-zerofill-and-.patch -Patch0201: 0201-posix-After-set-storage.reserve-limit-df-does-not-sh.patch -Patch0202: 0202-glusterd-TLS-verification-fails-while-using-intermed.patch -Patch0203: 0203-mgmt-glusterd-Adding-validation-for-setting-quorum-c.patch -Patch0204: 0204-glusterd-memory-leak-in-mgmt_v3-lock-functionality.patch -Patch0205: 0205-cluster-dht-User-xattrs-are-not-healed-after-brick-s.patch -Patch0206: 0206-glusterd-honour-localtime-logging-for-all-the-daemon.patch -Patch0207: 0207-glusterd-fix-txn_opinfo-memory-leak.patch -Patch0208: 0208-cluster-dht-enable-lookup-optimize-by-default.patch -Patch0209: 0209-cluster-dht-Update-layout-in-inode-only-on-success.patch -Patch0210: 0210-cluster-ec-send-list-node-uuids-request-to-all-subvo.patch -Patch0211: 0211-common-ha-scripts-pass-the-list-of-servers-properly-.patch -Patch0212: 0212-readdir-ahead-Cleanup-the-xattr-request-code.patch -Patch0213: 0213-glusterd-mark-port_registered-to-true-for-all-runnin.patch -Patch0214: 0214-cluster-dht-Serialize-mds-update-code-path-with-look.patch -Patch0215: 0215-cluster-dht-ENOSPC-will-not-fail-rebalance.patch -Patch0216: 0216-cluster-dht-Wind-open-to-all-subvols.patch -Patch0217: 0217-cluster-dht-Handle-file-migrations-when-brick-down.patch -Patch0218: 0218-posix-reserve-option-behavior-is-not-correct-while-u.patch -Patch0219: 0219-Quota-heal-directory-on-newly-added-bricks-when-quot.patch -Patch0220: 0220-glusterd-turn-off-selinux-feature-in-downstream.patch -Patch0221: 0221-cluster-dht-Skipped-files-are-not-treated-as-errors.patch -Patch0222: 0222-hooks-remove-selinux-hooks.patch -Patch0223: 0223-glusterd-Make-localtime-logging-option-invisible-in-.patch -Patch0224: 0224-protocol-server-Backport-patch-to-reduce-duplicate-c.patch -Patch0225: 0225-glusterfsd-Memleak-in-glusterfsd-process-while-brick.patch -Patch0226: 0226-gluster-Sometimes-Brick-process-is-crashed-at-the-ti.patch -Patch0227: 0227-afr-add-quorum-checks-in-pre-op.patch -Patch0228: 0228-afr-fixes-to-afr-eager-locking.patch -Patch0229: 0229-fuse-do-fd_resolve-in-fuse_getattr-if-fd-is-received.patch -Patch0230: 0230-glusterd-volume-inode-fd-status-broken-with-brick-mu.patch -Patch0231: 0231-fuse-retire-statvfs-tweak.patch -Patch0232: 0232-eventsapi-Handle-Unicode-string-during-signing.patch -Patch0233: 0233-libglusterfs-fix-comparison-of-a-NULL-dict-with-a-no.patch -Patch0234: 0234-ec-Use-tiebreaker_inodelk-where-necessary.patch -Patch0235: 0235-cluster-syncop-Implement-tiebreaker-inodelk-entrylk.patch -Patch0236: 0236-cluster-syncop-Address-comments-in-3ad68df725ac32f83.patch -Patch0237: 0237-cluster-dht-Fix-dht_rename-lock-order.patch -Patch0238: 0238-quota-Build-is-failed-due-to-access-rpc-refcount-in-.patch -Patch0239: 0239-geo-rep-Fix-syncing-of-symlink.patch -Patch0240: 0240-shared-storage-Prevent-mounting-shared-storage-from-.patch -Patch0241: 0241-server-auth-add-option-for-strict-authentication.patch -Patch0242: 0242-feature-changelog-remove-unused-variable.patch -Patch0243: 0243-timer-Fix-possible-race-during-cleanup.patch -Patch0244: 0244-common-ha-All-statd-related-files-need-to-be-owned-b.patch -Patch0245: 0245-build-make-RHGS-version-available-for-server.patch -Patch0246: 0246-glusterd-Fix-for-memory-leak-in-get-state-detail.patch -Patch0247: 0247-protocol-server-unwind-as-per-op-version.patch -Patch0248: 0248-performance-md-cache-purge-cache-on-ENOENT-ESTALE-er.patch -Patch0249: 0249-cluster-dht-unwind-if-dht_selfheal_dir_mkdir-returns.patch -Patch0250: 0250-cluster-dht-act-as-passthrough-for-renames-on-single.patch -Patch0251: 0251-dht-gf_defrag_settle_hash-should-ignore-ENOENT-and-E.patch -Patch0252: 0252-glusterd-ganesha-Skip-non-ganesha-nodes-properly-for.patch -Patch0253: 0253-geo-rep-Fix-upgrade-issue.patch -Patch0254: 0254-posix-Avoid-changelog-retries-for-geo-rep.patch -Patch0255: 0255-glusterd-update-listen-backlog-value-to-1024.patch -Patch0256: 0256-rpc-set-listen-backlog-to-high-value.patch -Patch0257: 0257-rpc-rearm-listener-socket-early.patch -Patch0258: 0258-cluster-dht-log-error-only-if-layout-healing-is-requ.patch -Patch0259: 0259-Quota-Turn-on-ssl-for-crawler-clients-if-needed.patch -Patch0260: 0260-dht-Avoid-dict-log-flooding-for-internal-MDS-xattr.patch -Patch0261: 0261-libglusterfs-syncop-Add-syncop_entrylk.patch -Patch0262: 0262-cluster-dht-store-the-reaction-on-failures-per-lock.patch -Patch0263: 0263-server-resolver-don-t-trust-inode-table-for-RESOLVE_.patch -Patch0264: 0264-cluster-dht-fixes-to-parallel-renames-to-same-destin.patch -Patch0265: 0265-Glusterfsd-brick-crash-during-get-state.patch -Patch0266: 0266-glusterd-geo-rep-Fix-glusterd-crash.patch -Patch0267: 0267-geo-rep-scheduler-Fix-crash.patch -Patch0268: 0268-dht-Excessive-dict-is-null-logs-in-dht_discover_comp.patch -Patch0269: 0269-extras-Disable-choose-local-in-groups-virt-and-glust.patch -Patch0270: 0270-glusterfs-Resolve-brick-crashes-at-the-time-of-inode.patch -Patch0271: 0271-cli-Fix-for-gluster-volume-info-xml.patch -Patch0272: 0272-readdir-ahead-Fix-an-issue-with-parallel-readdir-and.patch -Patch0273: 0273-rpcsvc-Turn-off-ownthreads-for-Glusterfs-program.patch -Patch0274: 0274-client-protocol-fix-the-log-level-for-removexattr_cb.patch -Patch0275: 0275-afr-fix-bug-1363721.t-failure.patch -Patch0276: 0276-tests-check-volume-status-for-shd-being-up.patch -Patch0277: 0277-Revert-rpcsvc-Turn-off-ownthreads-for-Glusterfs-prog.patch -Patch0278: 0278-Revert-rpcsvc-correct-event-thread-scaling.patch -Patch0279: 0279-Revert-rpc-make-actor-search-parallel.patch -Patch0280: 0280-Revert-rpcsvc-scale-rpcsvc_request_handler-threads.patch -Patch0281: 0281-Revert-program-GF-DUMP-Shield-ping-processing-from-t.patch -Patch0282: 0282-cluster-dht-Remove-EIO-from-dht_inode_missing.patch -Patch0283: 0283-cluster-ec-Fix-pre-op-xattrop-management.patch -Patch0284: 0284-glusterd-glusterd-is-releasing-the-locks-before-time.patch -Patch0285: 0285-gluster-Allow-only-read-only-CLI-commands-via-remote.patch -Patch0286: 0286-glusterd-memory-leak-in-geo-rep-status.patch -Patch0287: 0287-Revert-performance-write-behind-fix-flush-stuck-by-f.patch -Patch0288: 0288-feature-locks-Unwind-response-based-on-clinet-versio.patch -Patch0289: 0289-changelog-fix-br-state-check.t-failure-for-brick_mux.patch -Patch0290: 0290-performance-open-behind-open-pending-fds-before-perm.patch -Patch0291: 0291-Core-The-lock-contention-on-gf_client_dump_inodes_to.patch -Patch0292: 0292-geo-rep-Fix-rename-of-directory-in-hybrid-crawl.patch -Patch0293: 0293-rpcsvc-correct-event-thread-scaling.patch -Patch0294: 0294-features-shard-Fix-missing-unlock-in-shard_fsync_sha.patch -Patch0295: 0295-dht-Excessive-dict-is-null-logs-in-dht_revalidate_cb.patch -Patch0296: 0296-cluster-dht-Increase-failure-count-for-lookup-failur.patch -Patch0297: 0297-dht-Delete-MDS-internal-xattr-from-dict-in-dht_getxa.patch -Patch0298: 0298-glusterd-Fix-for-shd-not-coming-up.patch -Patch0299: 0299-afr-heal-gfids-when-file-is-not-present-on-all-brick.patch -Patch0300: 0300-protocol-client-Don-t-send-fops-till-SETVOLUME-is-co.patch -Patch0301: 0301-storage-posix-Fix-posix_symlinks_match.patch -Patch0302: 0302-storage-posix-Handle-ENOSPC-correctly-in-zero_fill.patch -Patch0303: 0303-block-profile-enable-cluster.eager-lock-in-block-pro.patch -Patch0304: 0304-cluster-dht-Fix-rename-journal-in-changelog.patch -Patch0305: 0305-geo-rep-Fix-geo-rep-for-older-versions-of-unshare.patch -Patch0306: 0306-glusterfsd-Do-not-process-GLUSTERD_BRICK_XLATOR_OP-i.patch -Patch0307: 0307-glusterd-Introduce-daemon-log-level-cluster-wide-opt.patch -Patch0308: 0308-glusterd-Fix-glusterd-crash.patch -Patch0309: 0309-extras-group-add-database-workload-profile.patch -Patch0310: 0310-cluster-afr-Make-sure-lk-owner-is-assigned-at-the-ti.patch -Patch0311: 0311-glusterd-show-brick-online-after-port-registration.patch -Patch0312: 0312-glusterd-show-brick-online-after-port-registration-e.patch -Patch0313: 0313-dht-Inconsistent-permission-for-directories-after-br.patch -Patch0314: 0314-cluster-afr-Prevent-execution-of-code-after-call_cou.patch -Patch0315: 0315-changelog-fix-br-state-check.t-crash-for-brick_mux.patch -Patch0316: 0316-snapshot-remove-stale-entry.patch -Patch0317: 0317-geo-rep-scheduler-Fix-EBUSY-trace-back.patch -Patch0318: 0318-Quota-Fix-crawling-of-files.patch -Patch0319: 0319-glusterd-_is_prefix-should-handle-0-length-paths.patch -Patch0320: 0320-glusterd-log-improvements-on-brick-creation-validati.patch -Patch0321: 0321-geo-rep-Fix-symlink-rename-syncing-issue.patch -Patch0322: 0322-geo-rep-Cleanup-stale-unprocessed-xsync-changelogs.patch -Patch0323: 0323-cluster-afr-Mark-dirty-for-entry-transactions-for-qu.patch -Patch0324: 0324-dht-delete-tier-related-internal-xattr-in-dht_getxat.patch -Patch0325: 0325-core-dereference-check-on-the-variables-in-glusterfs.patch -Patch0326: 0326-glusterd-memory-leak-in-get-state.patch -Patch0327: 0327-afr-switch-lk_owner-only-when-pre-op-succeeds.patch -Patch0328: 0328-geo-rep-Fix-issues-with-gfid-conflict-handling.patch -Patch0329: 0329-cluster-dht-Set-loc-gfid-before-healing-attr.patch -Patch0330: 0330-posix-check-before-removing-stale-symlink.patch -Patch0331: 0331-rpc-free-registered-callback-programs.patch -Patch0332: 0332-rpc-rpc_clnt_connection_cleanup-is-crashed-due-to-do.patch -Patch0333: 0333-glusterd-Add-multiple-checks-before-attach-start-a-b.patch -Patch0334: 0334-glusterd-Bricks-of-a-normal-volumes-should-not-attac.patch -Patch0335: 0335-cluster-ec-set-others.eager-lock-option-off-by-defau.patch -Patch0336: 0336-dict-handle-negative-key-value-length-while-unserial.patch -Patch0337: 0337-glusterfs-Brick-process-is-crash-at-the-time-of-call.patch -Patch0338: 0338-posix-prevent-crash-when-SEEK_DATA-HOLE-is-not-suppo.patch -Patch0339: 0339-posix-remove-not-supported-get-set-content.patch -Patch0340: 0340-protocol-don-t-use-alloca.patch -Patch0341: 0341-Revert-glusterd-enable-brick-multiplexing-by-default.patch -Patch0342: 0342-glusterd-more-stricter-checks-of-if-brick-is-running.patch -Patch0343: 0343-core-Update-condition-in-get_xlator_by_name_or_type.patch -Patch0344: 0344-glusterd-Compare-volume_id-before-start-attach-a-bri.patch -Patch0345: 0345-io-stats-allow-only-relative-path-for-dumping-io-sta.patch -Patch0346: 0346-gfapi-Handle-the-path-glfs_resolve_at.patch -Patch0347: 0347-posix-fix-unused-variable-warning.patch -Patch0348: 0348-posix-disable-block-and-character-files.patch -Patch0349: 0349-posix-don-t-allow-.-path-in-name.patch -Patch0350: 0350-cluster-dht-fix-inode-ref-management-in-dht_heal_pat.patch -Patch0351: 0351-cluster-dht-Fixed-rebalanced-files.patch -Patch0352: 0352-snapshot-Fail-snapshot-creation-if-an-empty-descript.patch -Patch0353: 0353-snapshot-handshake-store-description-after-strdup.patch -Patch0354: 0354-snapshot-Fix-wrong-dictionary-key-in-snapshot-cleanu.patch -Patch0355: 0355-server-protocol-resolve-memory-leak.patch -Patch0356: 0356-io-stats-sanitize-the-dump-path-further.patch -Patch0357: 0357-snapshot-fix-snapshot-status-failure-due-to-symlink-.patch -Patch0358: 0358-glusterd-glusterd_brick_start-shouldn-t-try-to-bring.patch -Patch0359: 0359-storage-posix-Increment-trusted.pgfid-in-posix_mknod.patch -Patch0360: 0360-geo-rep-Make-automatic-gfid-conflict-resolution-opti.patch -Patch0361: 0361-ctr-skip-ctr-xlator-init-if-ctr-is-not-enabled.patch -Patch0362: 0362-glusterd-glusterd_brick_start-shouldn-t-cleanup-pidf.patch -Patch0363: 0363-Update-rfc.sh-to-rhgs-3.4.1.patch -Patch0364: 0364-fips-Replace-md5sum-usage-to-enable-fips-support.patch -Patch0365: 0365-glusterd-ignore-importing-volume-which-is-undergoing.patch -Patch0366: 0366-glusterd-fail-volume-stop-operation-if-brick-detach-.patch -Patch0367: 0367-cluster-ec-Improve-logging-for-some-critical-error-m.patch -Patch0368: 0368-mount-fuse-convert-ENOENT-to-ESTALE-in-open-dir-_res.patch -Patch0369: 0369-geo-rep-Fix-deadlock-during-worker-start.patch -Patch0370: 0370-libgfchangelog-Fix-changelog-history-API.patch -Patch0371: 0371-performance-write-behind-remove-the-request-from-wip.patch -Patch0372: 0372-Revert-posix-disable-block-and-character-files.patch -Patch0373: 0373-posix-disable-open-read-write-on-special-files.patch -Patch0374: 0374-socket-set-42-as-default-tpc-user-timeout.patch -Patch0375: 0375-extras-Add-new-options-to-group-virt.patch -Patch0376: 0376-rchecksum-fips-Replace-MD5-usage-to-enable-fips-supp.patch -Patch0377: 0377-fips-geo-rep-Replace-MD5-with-SHA256.patch -Patch0378: 0378-posix-afr-handle-backward-compatibility-for-rchecksu.patch -Patch0379: 0379-glusterd-change-op-version-of-fips-mode-rchecksum.patch -Patch0380: 0380-cluster-afr-Batch-writes-in-same-lock-even-when-mult.patch -Patch0381: 0381-cluster-afr-Make-data-eager-lock-decision-based-on-n.patch -Patch0382: 0382-mount-fuse-make-fuse-dumping-available-as-mount-opti.patch -Patch0383: 0383-glusterd-bump-up-GD_OP_VERSION_MAX.patch -Patch0384: 0384-features-uss-Use-xxh64-to-generate-gfid-instead-of-m.patch -Patch0385: 0385-afr-fix-incorrect-reporting-of-directory-split-brain.patch -Patch0386: 0386-glusterd-make-sure-that-brickinfo-uuid-is-not-null.patch -Patch0387: 0387-georep-Fix-config-set-of-monitor-status.patch -Patch0388: 0388-glusterd-handshake-prevent-a-buffer-overflow.patch -Patch0389: 0389-server-don-t-allow-in-basename.patch -Patch0390: 0390-core-glusterfsd-keeping-fd-open-in-index-xlator.patch -Patch0391: 0391-glusterd-Use-GF_ATOMIC-to-update-blockers-counter-at.patch -Patch0392: 0392-glusterd-don-t-wait-for-blockers-flag-for-stop-volum.patch -Patch0393: 0393-core-Pass-xlator_name-in-server_call_xlator_mem_clea.patch -Patch0394: 0394-io-stats-prevent-taking-file-dump-on-server-side.patch -Patch0395: 0395-index-prevent-arbitrary-file-creation-outside-entry-.patch -Patch0396: 0396-protocol-remove-the-option-verify-volfile-checksum.patch -Patch0397: 0397-features-locks-add-buffer-overflow-checks-in-pl_getx.patch -Patch0398: 0398-lock-Do-not-allow-meta-lock-count-to-be-more-than-on.patch -Patch0399: 0399-all-fix-the-format-string-exceptions.patch -Patch0400: 0400-all-fix-the-format-warnings-due-to-strict-check.patch -Patch0401: 0401-client_t.c-fix-the-format-error.patch -Patch0402: 0402-core-glusterfsd-keeping-fd-open-in-index-xlator.patch -Patch0403: 0403-afr-prevent-winding-inodelks-twice-for-arbiter-volum.patch -Patch0404: 0404-core-Resolve-some-warnings-to-release-a-build.patch -Patch0405: 0405-glusterfsd-add-missing-UNLOCK.patch -Patch0406: 0406-glusterd-improve-logging-for-stage_deleted-flag.patch -Patch0407: 0407-spec-update-RHGS-version-for-RHGSWA.patch -# Patch0408: 0408-Update-rfc.sh-to-rhgs-3.4.2.patch -Patch0409: 0409-Update-database-profile-group.patch -Patch0410: 0410-cli-fix-glusterd-memory-leak-cause-by-gluster-v-stat.patch -Patch0411: 0411-glusterd-ensure-volinfo-caps-is-set-to-correct-value.patch -Patch0412: 0412-glusterd-set-fsid-while-performing-replace-brick.patch -Patch0413: 0413-glusterfind-add-logs-to-identify-parsing-phases.patch -Patch0414: 0414-logrotate-utilize-the-new-maxsize-option.patch -Patch0415: 0415-statedump-fix-clang-null-dereference-error.patch -Patch0416: 0416-glusterd-ignore-RPC-events-when-glusterd-is-shutting.patch -Patch0417: 0417-cli-Add-warning-message-while-converting-to-replica-.patch -Patch0418: 0418-cli-correct-rebalance-status-elapsed-check.patch -Patch0419: 0419-glusterfs-During-reconfigure-set-log-level-per-xlato.patch -Patch0420: 0420-Modify-log-message-DH-ciphers-are-disabled-from-ERRO.patch -Patch0421: 0421-rpc-handle-EAGAIN-when-SSL_ERROR_SYSCALL-is-returned.patch -Patch0422: 0422-glusterd-raise-default-transport.listen-backlog.patch -Patch0423: 0423-glusterd-acquire-lock-to-update-volinfo-structure.patch -Patch0424: 0424-cluster-afr-Delegate-metadata-heal-with-pending-xatt.patch -Patch0425: 0425-cluster-afr-Delegate-name-heal-when-possible.patch -Patch0426: 0426-features-shard-Make-operations-on-internal-directori.patch -Patch0427: 0427-features-shard-Add-option-to-barrier-parallel-lookup.patch -Patch0428: 0428-libglusterfs-syncop-Handle-barrier_-init-destroy-in-.patch -Patch0429: 0429-features-shard-Introducing-.shard-.remove_me-for-ato.patch -Patch0430: 0430-features-shard-Perform-shards-deletion-in-the-backgr.patch -Patch0431: 0431-glusterd-Reset-op-version-for-features.shard-deletio.patch -Patch0432: 0432-features-shard-Fix-crash-and-test-case-in-RENAME-fop.patch -Patch0433: 0433-mgmt-glusterd-use-proper-path-to-the-volfile.patch -Patch0434: 0434-cluster-afr-s-uuid_is_null-gf_uuid_is_null.patch -Patch0435: 0435-geo-rep-Fix-traceback-with-symlink-metadata-sync.patch -Patch0436: 0436-geo-rep-Fix-issue-in-gfid-conflict-resolution.patch -Patch0437: 0437-geo-rep-Add-more-intelligence-to-automatic-error-han.patch -Patch0438: 0438-cluster-dht-In-rename-unlink-after-creating-linkto-f.patch -Patch0439: 0439-cluster-dht-fixes-to-unlinking-invalid-linkto-file.patch -Patch0440: 0440-features-locks-Use-pthread_mutex_unlock-instead-of-p.patch -Patch0441: 0441-features-shard-Make-lru-limit-of-inode-list-configur.patch -Patch0442: 0442-glusterd-Reset-op-version-for-features.shard-lru-lim.patch -Patch0443: 0443-features-shard-Hold-a-ref-on-base-inode-when-adding-.patch -Patch0444: 0444-features-shard-fix-formatting-warning.patch -Patch0445: 0445-glusterd-don-t-call-svcs_reconfigure-for-all-volumes.patch -Patch0446: 0446-core-Portmap-entries-showing-stale-brick-entries-whe.patch -Patch0447: 0447-cluster-ec-Don-t-update-trusted.ec.version-if-fop-su.patch -Patch0448: 0448-core-Resolve-memory-leak-at-the-time-of-graph-init.patch -Patch0449: 0449-glusterd-mux-Optimize-brick-disconnect-handler-code.patch -Patch0450: 0450-glusterd-fix-Resource-leak-coverity-issue.patch -Patch0451: 0451-core-Resolve-memory-leak-at-the-time-of-graph-init.patch -Patch0452: 0452-glusterd-make-max-bricks-per-process-default-value-t.patch -Patch0453: 0453-server-Resolve-memory-leak-path-in-server_init.patch -Patch0454: 0454-glusterd-set-cluster.max-bricks-per-process-to-250.patch -Patch0455: 0455-glusterd-fix-get_mux_limit_per_process-to-read-defau.patch -# Patch0456: 0456-Update-rfc.sh-to-rhgs-3.4.3.patch -Patch0457: 0457-cluster-dht-sync-brick-root-perms-on-add-brick.patch -Patch0458: 0458-glusterd-fix-crash.patch -Patch0459: 0459-glfsheal-add-a-nolog-flag.patch -Patch0460: 0460-cli-add-a-warning-confirmation-message-in-peer-detac.patch -Patch0461: 0461-mount-fuse-Add-support-for-multi-threaded-fuse-reade.patch -Patch0462: 0462-posix-Do-not-log-ENXIO-errors-for-seek-fop.patch -Patch0463: 0463-build-glusterfs.spec-.in-firewalld-file-doesn-t-use-.patch -Patch0464: 0464-build-exclude-packaging-crypt.so.patch -Patch0465: 0465-build-add-missing-explicit-package-dependencies.patch -Patch0466: 0466-extras-Add-group-distributed-virt-for-single-brick-o.patch -Patch0467: 0467-glusterd-glusterd-to-regenerate-volfiles-when-GD_OP_.patch -Patch0468: 0468-core-move-invalid-port-logs-to-DEBUG-log-level.patch -Patch0469: 0469-nfs-set-ctx-for-every-inode-looked-up-nfs3_fh_resolv.patch -Patch0470: 0470-dht-fix-use-after-free-in-dht_rmdir_readdirp_cbk.patch -Patch0471: 0471-glusterd-migrating-profile-commands-to-mgmt_v3-frame.patch -Patch0472: 0472-glusterd-introduce-a-new-op-version-for-rhgs-3.4.3.patch -Patch0473: 0473-rpc-bump-up-server.event-threads.patch -Patch0474: 0474-afr-open_ftruncate_cbk-should-read-fd-from-local-con.patch -Patch0475: 0475-glusterd-perform-store-operation-in-cleanup-lock.patch -Patch0476: 0476-afr-add-checks-for-allowing-lookups.patch -Patch0477: 0477-glusterd-perform-rcu_read_lock-unlock-under-cleanup_.patch -Patch0478: 0478-libglusterfs-fix-memory-corruption-caused-by-per-thr.patch -Patch0479: 0479-ganesha-ha-ensure-pacemaker-is-enabled-after-setup.patch -Patch0480: 0480-geo-rep-Make-slave-volume-read-only-by-default.patch -Patch0481: 0481-extras-hooks-Do-not-blindly-remove-volume-share-from.patch -Patch0482: 0482-extras-hooks-General-improvements-to-S30samba-start..patch -Patch0483: 0483-Do-not-blindly-add-volume-share-section-to-smb.conf.patch -Patch0484: 0484-extras-New-group-volume-set-command-for-Samba-integr.patch -Patch0485: 0485-cluster-ec-Prevent-volume-create-without-redundant-b.patch -Patch0486: 0486-performance-rda-Fixed-dict_t-memory-leak.patch -Patch0487: 0487-mem-pool-add-tracking-of-mem_pool-that-requested-the.patch -Patch0488: 0488-cluster-afr-Allow-lookup-on-root-if-it-is-from-ADD_R.patch -Patch0489: 0489-cluster-afr-Do-not-update-read_subvol-in-inode_ctx-a.patch -Patch0490: 0490-glusterd-migrating-rebalance-commands-to-mgmt_v3-fra.patch -Patch0491: 0491-glusterd-tag-rebalance-mgmt_v3-command-to-op-version.patch -Patch0492: 0492-mem-pool-track-glusterfs_ctx_t-in-struct-mem_pool.patch -Patch0493: 0493-mem-pool-count-allocations-done-per-user-pool.patch -Patch0494: 0494-mem-pool-Resolve-crash-in-mem_pool_destroy.patch -Patch0495: 0495-build-add-conditional-dependency-on-server-for-devel.patch -Patch0496: 0496-glusterd-kill-the-process-without-releasing-the-clea.patch -Patch0497: 0497-cluster-dht-Use-percentages-for-space-check.patch -Patch0498: 0498-mem-pool-Code-refactor-in-mem_pool.c.patch -Patch0499: 0499-cluster-dht-Fix-incorrect-backport.patch -Patch0500: 0500-extras-Add-readdir-ahead-to-samba-group-command.patch -Patch0501: 0501-glusterd-aggregate-rsp-from-peers-for-profile-comman.patch -Patch0502: 0502-posix-posix_health_check_thread_proc-crash-due-to-pr.patch -Patch0503: 0503-core-brick-process-is-crashed-at-the-time-of-spawn-t.patch -Patch0504: 0504-dht-Add-NULL-check-for-stbuf-in-dht_rmdir_lookup_cbk.patch -Patch0505: 0505-features-shard-Fix-launch-of-multiple-synctasks-for-.patch -Patch0506: 0506-features-shard-Assign-fop-id-during-background-delet.patch -Patch0507: 0507-geo-rep-fix-rename-sync-on-hybrid-crawl.patch -Patch0508: 0508-glusterd-Resolve-multiple-leaks-in-glusterd-code-pat.patch -Patch0509: 0509-core-heketi-cli-is-throwing-error-target-is-busy.patch -Patch0510: 0510-features-shard-Ref-shard-inode-while-adding-to-fsync.patch -Patch0511: 0511-Update-rfc.sh-to-rhgs-3.4.4.patch -Patch0512: 0512-Test-fixes-for-rhgs-3.4-downstream.patch -Patch0513: 0513-core-heketi-cli-is-throwing-error-target-is-busy.patch -Patch0514: 0514-glusterd-display-gluster-volume-status-when-quorum-t.patch -Patch0515: 0515-cli-change-the-warning-message.patch -Patch0516: 0516-geo-rep-Fix-permissions-with-non-root-setup.patch -Patch0517: 0517-geo-rep-validate-the-config-checkpoint-date-format.patch -Patch0518: 0518-logging-create-parent-dir-if-not-available.patch -Patch0519: 0519-cluster-dht-Delete-invalid-linkto-files-in-rmdir.patch -Patch0520: 0520-spec-avoid-creation-of-temp-file-in-lua-script.patch -Patch0521: 0521-rpc-use-address-family-option-from-vol-file.patch -Patch0522: 0522-fuse-add-lru-limit-option.patch -Patch0523: 0523-libglusterfs-rename-macros-roof-and-floor-to-not-con.patch -Patch0524: 0524-program-GF-DUMP-Shield-ping-processing-from-traffic-.patch -Patch0525: 0525-rpcsvc-provide-each-request-handler-thread-its-own-q.patch -Patch0526: 0526-fuse-interrupt-handling-framework.patch -Patch0527: 0527-fuse-diagnostic-FLUSH-interrupt.patch -Patch0528: 0528-locks-handle-clear-locks-xattr-in-fgetxattr-too.patch -Patch0529: 0529-fuse-SETLKW-interrupt.patch -Patch0530: 0530-spec-fix-lua-script-execution-during-install.patch -Patch0531: 0531-fuse-remove-the-duplicate-FUSE_FOP-calls.patch -Patch0532: 0532-dht-fix-double-extra-unref-of-inode-at-heal-path.patch -Patch0533: 0533-glusterd-glusterd-memory-leak-while-running-gluster-.patch -Patch0534: 0534-fuse-make-sure-the-send-lookup-on-root-instead-of-ge.patch -Patch0535: 0535-posix-Deletion-of-block-hosting-volume-throwing-erro.patch -Patch0536: 0536-cluster-dht-Fix-lookup-selfheal-and-rmdir-race.patch -Patch0537: 0537-cluster-dht-Do-not-use-gfid-req-in-fresh-lookup.patch -Patch0538: 0538-cluster-afr-Send-truncate-on-arbiter-brick-from-SHD.patch +Patch0003: 0003-rpc-set-bind-insecure-to-off-by-default.patch +Patch0004: 0004-glusterd-spec-fixing-autogen-issue.patch +Patch0005: 0005-libglusterfs-glusterd-Fix-compilation-errors.patch +Patch0006: 0006-build-remove-ghost-directory-entries.patch +Patch0007: 0007-build-add-RHGS-specific-changes.patch +Patch0008: 0008-secalert-remove-setuid-bit-for-fusermount-glusterfs.patch +Patch0009: 0009-build-introduce-security-hardening-flags-in-gluster.patch +Patch0010: 0010-spec-fix-add-pre-transaction-scripts-for-geo-rep-and.patch +Patch0011: 0011-rpm-glusterfs-devel-for-client-builds-should-not-dep.patch +Patch0012: 0012-build-add-pretrans-check.patch +Patch0013: 0013-glusterd-fix-info-file-checksum-mismatch-during-upgr.patch +Patch0014: 0014-build-spec-file-conflict-resolution.patch +Patch0015: 0015-build-randomize-temp-file-names-in-pretrans-scriptle.patch +Patch0016: 0016-glusterd-parallel-readdir-Change-the-op-version-of-p.patch +Patch0017: 0017-glusterd-Revert-op-version-for-cluster.max-brick-per.patch +Patch0018: 0018-cli-Add-message-for-user-before-modifying-brick-mult.patch +Patch0019: 0019-build-launch-glusterd-upgrade-after-all-new-bits-are.patch +Patch0020: 0020-spec-unpackaged-files-found-for-RHEL-7-client-build.patch +Patch0021: 0021-cli-glusterfsd-remove-copyright-information.patch +Patch0022: 0022-cli-Remove-upstream-doc-reference.patch +Patch0023: 0023-hooks-remove-selinux-hooks.patch +Patch0024: 0024-glusterd-Make-localtime-logging-option-invisible-in-.patch +Patch0025: 0025-build-make-RHGS-version-available-for-server.patch +Patch0026: 0026-glusterd-Introduce-daemon-log-level-cluster-wide-opt.patch +Patch0027: 0027-glusterd-change-op-version-of-fips-mode-rchecksum.patch +Patch0028: 0028-glusterd-Reset-op-version-for-features.shard-deletio.patch +Patch0029: 0029-glusterd-Reset-op-version-for-features.shard-lru-lim.patch +Patch0030: 0030-selinux-glusterd-add-features.selinux-to-glusterd-vo.patch +Patch0031: 0031-glusterd-turn-off-selinux-feature-in-downstream.patch +Patch0032: 0032-glusterd-update-gd-op-version-to-3_7_0.patch +Patch0033: 0033-build-add-missing-explicit-package-dependencies.patch +Patch0034: 0034-glusterd-introduce-a-new-op-version-for-rhgs-3.4.3.patch +Patch0035: 0035-glusterd-tag-rebalance-mgmt_v3-command-to-op-version.patch +Patch0036: 0036-build-add-conditional-dependency-on-server-for-devel.patch +Patch0037: 0037-cli-change-the-warning-message.patch +Patch0038: 0038-spec-avoid-creation-of-temp-file-in-lua-script.patch +Patch0039: 0039-cli-fix-query-to-user-during-brick-mux-selection.patch +Patch0040: 0040-build-Remove-unsupported-test-cases-failing-consiste.patch +Patch0041: 0041-tests-geo-rep-Build-failed-in-Jenkins-for-test-bug-1.patch +Patch0042: 0042-spec-client-server-Builds-are-failing-on-rhel-6.patch +Patch0043: 0043-inode-don-t-dump-the-whole-table-to-CLI.patch +Patch0044: 0044-cluster-ec-Don-t-enqueue-an-entry-if-it-is-already-h.patch +Patch0045: 0045-glusterd-fix-txn-id-mem-leak.patch +Patch0046: 0046-protocol-client-Do-not-fallback-to-anon-fd-if-fd-is-.patch +Patch0047: 0047-client-rpc-Fix-the-payload-being-sent-on-the-wire.patch +Patch0048: 0048-gfapi-Unblock-epoll-thread-for-upcall-processing.patch +Patch0049: 0049-transport-socket-log-shutdown-msg-occasionally.patch +Patch0050: 0050-geo-rep-Fix-syncing-multiple-rename-of-symlink.patch +Patch0051: 0051-spec-update-rpm-install-condition.patch +Patch0052: 0052-geo-rep-IPv6-support.patch %description GlusterFS is a distributed file-system capable of scaling to several @@ -819,7 +375,6 @@ and client framework. %package api Summary: GlusterFS api library -Group: System Environment/Daemons Requires: %{name}%{?_isa} = %{version}-%{release} Requires: %{name}-client-xlators%{?_isa} = %{version}-%{release} Requires: %{name}-libs%{?_isa} = %{version}-%{release} @@ -837,7 +392,6 @@ This package provides the glusterfs libgfapi library. %package api-devel Summary: Development Libraries -Group: Development/Libraries Requires: %{name}%{?_isa} = %{version}-%{release} Requires: %{name}-devel%{?_isa} = %{version}-%{release} Requires: libacl-devel @@ -854,9 +408,9 @@ is in user space and easily manageable. This package provides the api include files. +%if ( 0%{!?_without_server:1} ) %package cli Summary: GlusterFS CLI -Group: Applications/File Requires: %{name}-libs%{?_isa} = %{version}-%{release} %description cli @@ -869,17 +423,32 @@ called Translators from GNU Hurd kernel. Much of the code in GlusterFS is in user space and easily manageable. This package provides the GlusterFS CLI application and its man page +%endif + +%package cloudsync-plugins +Summary: Cloudsync Plugins +BuildRequires: libcurl-devel + +%description cloudsync-plugins +GlusterFS is a distributed file-system capable of scaling to several +petabytes. It aggregates various storage bricks over Infiniband RDMA +or TCP/IP interconnect into one large parallel network file +system. GlusterFS is one of the most sophisticated file systems in +terms of features and extensibility. It borrows a powerful concept +called Translators from GNU Hurd kernel. Much of the code in GlusterFS +is in user space and easily manageable. + +This package provides cloudsync plugins for archival feature. %package devel Summary: Development Libraries -Group: Development/Libraries Requires: %{name}%{?_isa} = %{version}-%{release} # Needed for the Glupy examples to work %if ( 0%{!?_without_extra_xlators:1} ) -Requires: %{name}-extra-xlators = %{version}-%{release} +Requires: %{name}-extra-xlators%{?_isa} = %{version}-%{release} %endif Requires: %{name}-libs%{?_isa} = %{version}-%{release} -%if ( 0%{?_build_server} ) +%if ( 0%{!?_without_server:1} ) Requires: %{name}-server%{?_isa} = %{version}-%{release} %endif @@ -897,14 +466,10 @@ This package provides the development libraries and include files. %if ( 0%{!?_without_extra_xlators:1} ) %package extra-xlators Summary: Extra Gluster filesystem Translators -Group: Applications/File # We need python-gluster rpm for gluster module's __init__.py in Python # site-packages area -Requires: python2-gluster = %{version}-%{release} -Requires: python2 -%if ( 0%{?fedora} && 0%{?fedora} < 26 ) || ( 0%{?rhel} ) -BuildRequires: python-ctypes -%endif +Requires: python%{_pythonver}-gluster = %{version}-%{release} +Requires: python%{_pythonver} %description extra-xlators GlusterFS is a distributed file-system capable of scaling to several @@ -921,7 +486,6 @@ for GlusterFS. %package fuse Summary: Fuse client -Group: Applications/File BuildRequires: fuse-devel Requires: attr Requires: psmisc @@ -945,60 +509,15 @@ is in user space and easily manageable. This package provides support to FUSE based clients and inlcudes the glusterfs(d) binary. -%if ( 0%{?_build_server} ) -%package ganesha -Summary: NFS-Ganesha configuration -Group: Applications/File - -Requires: %{name}-server%{?_isa} = %{version}-%{release} -Requires: nfs-ganesha-gluster >= 2.4.1 -Requires: pcs, dbus -%if ( 0%{?rhel} && 0%{?rhel} == 6 ) -Requires: cman, pacemaker, corosync -%endif -%if ( ( 0%{?fedora} && 0%{?fedora} > 25 ) || ( 0%{?rhel} && 0%{?rhel} > 6 ) ) -%if ( 0%{?rhel} ) -Requires: selinux-policy >= 3.13.1-160 -Requires(post): policycoreutils-python -Requires(postun): policycoreutils-python -%else -Requires(post): policycoreutils-python-utils -Requires(postun): policycoreutils-python-utils -%endif -%endif - -%if ( 0%{?fedora} ) || ( 0%{?rhel} && 0%{?rhel} > 5 ) -# we need portblock resource-agent in 3.9.5 and later. -Requires: resource-agents >= 3.9.5 -Requires: net-tools -%endif - -%description ganesha -GlusterFS is a distributed file-system capable of scaling to several -petabytes. It aggregates various storage bricks over Infiniband RDMA -or TCP/IP interconnect into one large parallel network file -system. GlusterFS is one of the most sophisticated file systems in -terms of features and extensibility. It borrows a powerful concept -called Translators from GNU Hurd kernel. Much of the code in GlusterFS -is in user space and easily manageable. - -This package provides the configuration and related files for using -NFS-Ganesha as the NFS server using GlusterFS -%endif - -%if ( 0%{?_build_server} ) %if ( 0%{!?_without_georeplication:1} ) %package geo-replication Summary: GlusterFS Geo-replication -Group: Applications/File Requires: %{name}%{?_isa} = %{version}-%{release} Requires: %{name}-server%{?_isa} = %{version}-%{release} -Requires: python2 -Requires: python-prettytable -%if ( 0%{?fedora} && 0%{?fedora} < 26 ) || ( 0%{?rhel} ) -BuildRequires: python-ctypes -%endif -Requires: python2-gluster = %{version}-%{release} +Requires: python%{_pythonver} +Requires: python%{_pythonver}-prettytable +Requires: python%{_pythonver}-gluster = %{version}-%{release} + Requires: rsync Requires: util-linux Requires: %{name}-libs%{?_isa} = %{version}-%{release} @@ -1014,11 +533,28 @@ is in userspace and easily manageable. This package provides support to geo-replication. %endif + +%if ( 0%{?_with_gnfs:1} ) +%package gnfs +Summary: GlusterFS gNFS server +Requires: %{name}%{?_isa} = %{version}-%{release} +Requires: %{name}-client-xlators%{?_isa} = %{version}-%{release} +Requires: nfs-utils + +%description gnfs +GlusterFS is a distributed file-system capable of scaling to several +petabytes. It aggregates various storage bricks over Infiniband RDMA +or TCP/IP interconnect into one large parallel network file +system. GlusterFS is one of the most sophisticated file systems in +terms of features and extensibility. It borrows a powerful concept +called Translators from GNU Hurd kernel. Much of the code in GlusterFS +is in user space and easily manageable. + +This package provides the glusterfs legacy gNFS server xlator %endif %package libs Summary: GlusterFS common libraries -Group: Applications/File %description libs GlusterFS is a distributed file-system capable of scaling to several @@ -1031,42 +567,30 @@ is in user space and easily manageable. This package provides the base GlusterFS libraries -%package -n python-gluster +%package -n python%{_pythonver}-gluster Summary: GlusterFS python library -Group: Development/Tools -%if ( ! ( 0%{?rhel} && 0%{?rhel} < 6 || 0%{?sles_version} ) ) -# EL5 does not support noarch sub-packages -BuildArch: noarch -%endif - -%global _python_gluster_description \ -GlusterFS is a distributed file-system capable of scaling to several\ -petabytes. It aggregates various storage bricks over Infiniband RDMA\ -or TCP/IP interconnect into one large parallel network file\ -system. GlusterFS is one of the most sophisticated file systems in\ -terms of features and extensibility. It borrows a powerful concept\ -called Translators from GNU Hurd kernel. Much of the code in GlusterFS\ -is in user space and easily manageable.\ -\ -This package contains the python modules of GlusterFS and own gluster\ -namespace. - -%description -n python-gluster %{_python_gluster_description} - -%package -n python2-gluster -Summary: GlusterFS python library -Group: Development/Tools -%{?python_provide:%python_provide python2-gluster} -Requires: python2 +Requires: python%{_pythonver} +%if ( ! %{_usepython3} ) +%{?python_provide:%python_provide python-gluster} Provides: python-gluster = %{version}-%{release} Obsoletes: python-gluster < 3.10 +%endif -%description -n python2-gluster %{_python_gluster_description} +%description -n python%{_pythonver}-gluster +GlusterFS is a distributed file-system capable of scaling to several +petabytes. It aggregates various storage bricks over Infiniband RDMA +or TCP/IP interconnect into one large parallel network file +system. GlusterFS is one of the most sophisticated file systems in +terms of features and extensibility. It borrows a powerful concept +called Translators from GNU Hurd kernel. Much of the code in GlusterFS +is in user space and easily manageable. + +This package contains the python modules of GlusterFS and own gluster +namespace. %if ( 0%{!?_without_rdma:1} ) %package rdma Summary: GlusterFS rdma support for ib-verbs -Group: Applications/File %if ( 0%{?fedora} && 0%{?fedora} > 26 ) BuildRequires: rdma-core-devel %else @@ -1088,41 +612,30 @@ is in user space and easily manageable. This package provides support to ib-verbs library. %endif -%if ( 0%{?_build_server} ) %if ( 0%{!?_without_regression_tests:1} ) %package regression-tests Summary: Development Tools -Group: Development/Tools Requires: %{name}%{?_isa} = %{version}-%{release} Requires: %{name}-fuse%{?_isa} = %{version}-%{release} Requires: %{name}-server%{?_isa} = %{version}-%{release} ## thin provisioning support Requires: lvm2 >= 2.02.89 Requires: perl(App::Prove) perl(Test::Harness) gcc util-linux-ng -Requires: python2 attr dbench file git libacl-devel net-tools +Requires: python%{_pythonver} +Requires: attr dbench file git libacl-devel net-tools Requires: nfs-utils xfsprogs yajl psmisc bc %description regression-tests The Gluster Test Framework, is a suite of scripts used for regression testing of Gluster. %endif -%endif -%if ( 0%{?_build_server} ) %if ( 0%{!?_without_ocf:1} ) %package resource-agents Summary: OCF Resource Agents for GlusterFS License: GPLv3+ -%if ( ! ( 0%{?rhel} && 0%{?rhel} < 6 || 0%{?sles_version} ) ) -# EL5 does not support noarch sub-packages BuildArch: noarch -%endif # this Group handling comes from the Fedora resource-agents package -%if ( 0%{?fedora} || 0%{?centos_version} || 0%{?rhel} ) -Group: System Environment/Base -%else -Group: Productivity/Clustering/HA -%endif # for glusterd Requires: %{name}-server = %{version}-%{release} # depending on the distribution, we need pacemaker or resource-agents @@ -1141,12 +654,10 @@ This package provides the resource agents which plug glusterd into Open Cluster Framework (OCF) compliant cluster resource managers, like Pacemaker. %endif -%endif -%if ( 0%{?_build_server} ) +%if ( 0%{!?_without_server:1} ) %package server Summary: Clustered file-system server -Group: System Environment/Daemons Requires: %{name}%{?_isa} = %{version}-%{release} Requires: %{name}-cli%{?_isa} = %{version}-%{release} Requires: %{name}-libs%{?_isa} = %{version}-%{release} @@ -1157,7 +668,6 @@ Requires: %{name}-api%{?_isa} = %{version}-%{release} Requires: %{name}-client-xlators%{?_isa} = %{version}-%{release} # lvm2 for snapshot, and nfs-utils and rpcbind/portmap for gnfs server Requires: lvm2 -Requires: nfs-utils %if ( 0%{?_with_systemd:1} ) %{?systemd_requires} %else @@ -1179,13 +689,14 @@ Requires: rpcbind %else Requires: portmap %endif -%if ( 0%{?rhel} && 0%{?rhel} < 6 ) -Obsoletes: %{name}-geo-replication = %{version}-%{release} -%endif %if ( 0%{?rhel} && 0%{?rhel} <= 6 ) Requires: python-argparse %endif +%if ( 0%{?fedora} && 0%{?fedora} > 27 ) || ( 0%{?rhel} && 0%{?rhel} > 7 ) +Requires: python%{_pythonver}-pyxattr +%else Requires: pyxattr +%endif %if (0%{?_with_valgrind:1}) Requires: valgrind %endif @@ -1202,9 +713,20 @@ is in user space and easily manageable. This package provides the glusterfs server daemon. %endif +%package thin-arbiter +Summary: GlusterFS thin-arbiter module +Requires: %{name}%{?_isa} = %{version}-%{release} +Requires: %{name}-server%{?_isa} = %{version}-%{release} + +%description thin-arbiter +This package provides a tie-breaker functionality to GlusterFS +replicate volume. It includes translators required to provide the +functionality, and also few other scripts required for getting the setup done. + +This package provides the glusterfs thin-arbiter translator. + %package client-xlators Summary: GlusterFS client-side translators -Group: Applications/File Requires: %{name}-libs%{?_isa} = %{version}-%{release} %description client-xlators @@ -1218,18 +740,16 @@ is in user space and easily manageable. This package provides the translators needed on any GlusterFS client. -%if ( 0%{?_build_server} ) %if ( 0%{!?_without_events:1} ) %package events Summary: GlusterFS Events -Group: Applications/File Requires: %{name}-server%{?_isa} = %{version}-%{release} -Requires: python2 python-prettytable -Requires: python2-gluster = %{version}-%{release} -%if ( 0%{?rhel} ) +Requires: python%{_pythonver} python%{_pythonver}-prettytable +Requires: python%{_pythonver}-gluster = %{version}-%{release} +%if ( 0%{?rhel} && 0%{?rhel} < 8 ) Requires: python-requests %else -Requires: python2-requests +Requires: python%{_pythonver}-requests %endif %if ( 0%{?rhel} && 0%{?rhel} < 7 ) Requires: python-argparse @@ -1241,7 +761,6 @@ Requires: python-argparse %description events GlusterFS Events -%endif %endif %prep @@ -1296,12 +815,15 @@ do $p done +%if ( ! %{_usepython3} ) +echo "fixing python shebangs..." +for f in api events extras geo-replication libglusterfs tools xlators; do +find $f -type f -exec sed -i 's|/usr/bin/python3|/usr/bin/python2|' {} \; +done +%endif %build -%if ( 0%{?rhel} && 0%{?rhel} < 6 ) -CFLAGS=-DUSE_INSECURE_OPENSSL -export CFLAGS -%endif + # In RHEL7 few hardening flags are available by default, however the RELRO # default behaviour is partial, convert to full %if ( 0%{?rhel} && 0%{?rhel} >= 7 ) @@ -1322,20 +844,24 @@ export LDFLAGS %endif ./autogen.sh && %configure \ + %{?_with_asan} \ %{?_with_cmocka} \ %{?_with_debug} \ - %{?_with_valgrind} \ + %{?_with_firewalld} \ + %{?_with_gnfs} \ %{?_with_tmpfilesdir} \ - %{?_without_bd} \ + %{?_with_tsan} \ + %{?_with_valgrind} \ %{?_without_epoll} \ + %{?_without_events} \ %{?_without_fusermount} \ %{?_without_georeplication} \ - %{?_with_firewalld} \ %{?_without_ocf} \ %{?_without_rdma} \ + %{?_without_server} \ %{?_without_syslog} \ - %{?_without_tiering} \ - %{?_without_events} + %{?_with_ipv6default} \ + %{?_without_libtirpc} # fix hardening and remove rpath in shlibs %if ( 0%{?fedora} && 0%{?fedora} > 17 ) || ( 0%{?rhel} && 0%{?rhel} > 6 ) @@ -1352,9 +878,7 @@ make check %install rm -rf %{buildroot} make install DESTDIR=%{buildroot} -# Install include directory -install -p -m 0644 contrib/uuid/*.h \ - %{buildroot}%{_includedir}/glusterfs/ +%if ( 0%{!?_without_server:1} ) %if ( 0%{_for_fedora_koji_builds} ) install -D -p -m 0644 %{SOURCE1} \ %{buildroot}%{_sysconfdir}/sysconfig/glusterd @@ -1364,12 +888,6 @@ install -D -p -m 0644 %{SOURCE2} \ install -D -p -m 0644 extras/glusterd-sysconfig \ %{buildroot}%{_sysconfdir}/sysconfig/glusterd %endif - -%if ( 0%{_for_fedora_koji_builds} ) -%if ( 0%{?rhel} && 0%{?rhel} <= 5 ) -install -D -p -m 0755 %{SOURCE6} \ - %{buildroot}%{_sysconfdir}/sysconfig/modules/glusterfs-fuse.modules -%endif %endif mkdir -p %{buildroot}%{_localstatedir}/log/glusterd @@ -1398,42 +916,31 @@ https://forge.gluster.org/glusterfs-core/glusterfs/commits/v%{version}%{?prerelt EOM # Remove benchmarking and other unpackaged files -%if ( 0%{?rhel} && 0%{?rhel} < 6 ) -rm -rf %{buildroot}/benchmarking -rm -f %{buildroot}/glusterfs-mode.el -rm -f %{buildroot}/glusterfs.vim -%else # make install always puts these in %%{_defaultdocdir}/%%{name} so don't # use %%{_pkgdocdir}; that will be wrong on later Fedora distributions rm -rf %{buildroot}%{_defaultdocdir}/%{name}/benchmarking rm -f %{buildroot}%{_defaultdocdir}/%{name}/glusterfs-mode.el rm -f %{buildroot}%{_defaultdocdir}/%{name}/glusterfs.vim -%endif +%if ( 0%{!?_without_server:1} ) # Create working directory mkdir -p %{buildroot}%{_sharedstatedir}/glusterd # Update configuration file to /var/lib working directory sed -i 's|option working-directory /etc/glusterd|option working-directory %{_sharedstatedir}/glusterd|g' \ %{buildroot}%{_sysconfdir}/glusterfs/glusterd.vol +%endif # Install glusterfsd .service or init.d file +%if ( 0%{!?_without_server:1} ) %if ( 0%{_for_fedora_koji_builds} ) -%_init_install %{glusterfsd_service} glusterfsd +%service_install glusterfsd %{glusterfsd_svcfile} +%endif %endif install -D -p -m 0644 extras/glusterfs-logrotate \ %{buildroot}%{_sysconfdir}/logrotate.d/glusterfs -# ganesha ghosts -%if ( 0%{?_build_server} ) -mkdir -p %{buildroot}%{_sysconfdir}/ganesha -touch %{buildroot}%{_sysconfdir}/ganesha/ganesha-ha.conf -mkdir -p %{buildroot}%{_localstatedir}/run/gluster/shared_storage/nfs-ganesha/exports -touch %{buildroot}%{_localstatedir}/run/gluster/shared_storage/nfs-ganesha/ganesha.conf -touch %{buildroot}%{_localstatedir}/run/gluster/shared_storage/nfs-ganesha/ganesha-ha.conf -%endif - %if ( 0%{!?_without_georeplication:1} ) mkdir -p %{buildroot}%{_sharedstatedir}/glusterd/geo-replication touch %{buildroot}%{_sharedstatedir}/glusterd/geo-replication/gsyncd_template.conf @@ -1441,6 +948,7 @@ install -D -p -m 0644 extras/glusterfs-georep-logrotate \ %{buildroot}%{_sysconfdir}/logrotate.d/glusterfs-georep %endif +%if ( 0%{!?_without_server:1} ) touch %{buildroot}%{_sharedstatedir}/glusterd/glusterd.info touch %{buildroot}%{_sharedstatedir}/glusterd/options subdirs=(add-brick create copy-file delete gsync-create remove-brick reset set start stop) @@ -1458,15 +966,18 @@ mkdir -p %{buildroot}%{_sharedstatedir}/glusterd/snaps mkdir -p %{buildroot}%{_sharedstatedir}/glusterd/ss_brick touch %{buildroot}%{_sharedstatedir}/glusterd/nfs/nfs-server.vol touch %{buildroot}%{_sharedstatedir}/glusterd/nfs/run/nfs.pid +%endif find ./tests ./run-tests.sh -type f | cpio -pd %{buildroot}%{_prefix}/share/glusterfs ## Install bash completion for cli +%if ( 0%{!?_without_server:1} ) install -p -m 0744 -D extras/command-completion/gluster.bash \ %{buildroot}%{_sysconfdir}/bash_completion.d/gluster +%endif -%if ( 0%{?_build_server} ) -echo "RHGS 3.4" > %{buildroot}%{_datadir}/glusterfs/release +%if ( 0%{!?_without_server:1} ) +echo "RHGS 3.5" > %{buildroot}%{_datadir}/glusterfs/release %endif %clean @@ -1479,7 +990,7 @@ rm -rf %{buildroot} /sbin/ldconfig %if ( 0%{!?_without_syslog:1} ) %if ( 0%{?fedora} ) || ( 0%{?rhel} && 0%{?rhel} >= 6 ) -%_init_restart rsyslog +%systemd_postun_with_restart rsyslog %endif %endif exit 0 @@ -1487,46 +998,28 @@ exit 0 %post api /sbin/ldconfig -%if ( 0%{?_build_server} ) %if ( 0%{!?_without_events:1} ) %post events -%_init_restart glustereventsd -%endif +%systemd_post glustereventsd %endif -%if ( 0%{?rhel} == 5 ) -%post fuse -modprobe fuse -exit 0 -%endif - -%if ( 0%{?_build_server} ) -%if ( 0%{?fedora} && 0%{?fedora} > 25 || ( 0%{?rhel} && 0%{?rhel} > 6 ) ) -%post ganesha -semanage boolean -m ganesha_use_fusefs --on -exit 0 -%endif -%endif - -%if ( 0%{?_build_server} ) %if ( 0%{!?_without_georeplication:1} ) %post geo-replication if [ $1 -ge 1 ]; then - %_init_restart glusterd + %systemd_postun_with_restart glusterd fi exit 0 %endif -%endif %post libs /sbin/ldconfig -%if ( 0%{?_build_server} ) +%if ( 0%{!?_without_server:1} ) %post server # Legacy server -%_init_enable glusterd +%systemd_post glusterd %if ( 0%{_for_fedora_koji_builds} ) -%_init_enable glusterfsd +%systemd_post glusterfsd %endif # ".cmd_log_history" is renamed to "cmd_history.log" in GlusterFS-3.7 . # While upgrading glusterfs-server package form GlusterFS version <= 3.6 to @@ -1581,207 +1074,86 @@ getent group gluster > /dev/null || groupadd -r gluster getent passwd gluster > /dev/null || useradd -r -g gluster -d %{_rundir}/gluster -s /sbin/nologin -c "GlusterFS daemons" gluster exit 0 - ##----------------------------------------------------------------------------- ## All %%preun should be placed here and keep them sorted ## -%if ( 0%{?_build_server} ) %if ( 0%{!?_without_events:1} ) %preun events if [ $1 -eq 0 ]; then - if [ -f %_init_glustereventsd ]; then - %_init_stop glustereventsd - %_init_disable glustereventsd + if [ -f %glustereventsd_svcfile ]; then + %service_stop glustereventsd + %systemd_preun glustereventsd fi fi exit 0 %endif +%if ( 0%{!?_without_server:1} ) %preun server if [ $1 -eq 0 ]; then - if [ -f %_init_glusterfsd ]; then - %_init_stop glusterfsd + if [ -f %glusterfsd_svcfile ]; then + %service_stop glusterfsd fi - %_init_stop glusterd - if [ -f %_init_glusterfsd ]; then - %_init_disable glusterfsd + %service_stop glusterd + if [ -f %glusterfsd_svcfile ]; then + %systemd_preun glusterfsd fi - %_init_disable glusterd + %systemd_preun glusterd fi if [ $1 -ge 1 ]; then - if [ -f %_init_glusterfsd ]; then - %_init_restart glusterfsd + if [ -f %glusterfsd_svcfile ]; then + %systemd_postun_with_restart glusterfsd fi - %_init_restart glusterd + %systemd_postun_with_restart glusterd fi +exit 0 %endif +%preun thin-arbiter +if [ $1 -eq 0 ]; then + if [ -f %glusterta_svcfile ]; then + %service_stop gluster-ta-volume + %systemd_preun gluster-ta-volume + fi +fi + ##----------------------------------------------------------------------------- ## All %%postun should be placed here and keep them sorted ## %postun -/sbin/ldconfig %if ( 0%{!?_without_syslog:1} ) %if ( 0%{?fedora} ) || ( 0%{?rhel} && 0%{?rhel} >= 6 ) -%_init_restart rsyslog +%systemd_postun_with_restart rsyslog %endif %endif -%postun api -/sbin/ldconfig - -%if ( 0%{?_build_server} ) -%if ( 0%{?fedora} && 0%{?fedora} > 25 || ( 0%{?rhel} && 0%{?rhel} > 6 ) ) -%postun ganesha -semanage boolean -m ganesha_use_fusefs --off -exit 0 -%endif -%endif - -%postun libs -/sbin/ldconfig - -%if ( 0%{?_build_server} ) +%if ( 0%{!?_without_server:1} ) %postun server -/sbin/ldconfig %if (0%{?_with_firewalld:1}) %firewalld_reload %endif exit 0 %endif -##----------------------------------------------------------------------------- -## All %%trigger should be placed here and keep them sorted -## -%if ( 0%{?_build_server} ) -%if ( 0%{?fedora} && 0%{?fedora} > 25 || ( 0%{?rhel} && 0%{?rhel} > 6 ) ) -%trigger ganesha -- selinux-policy-targeted -semanage boolean -m ganesha_use_fusefs --on -exit 0 -%endif -%endif - -##----------------------------------------------------------------------------- -## All %%triggerun should be placed here and keep them sorted -## -%if ( 0%{?_build_server} ) -%if ( 0%{?fedora} && 0%{?fedora} > 25 || ( 0%{?rhel} && 0%{?rhel} > 6 ) ) -%triggerun ganesha -- selinux-policy-targeted -semanage boolean -m ganesha_use_fusefs --off -exit 0 -%endif -%endif - ##----------------------------------------------------------------------------- ## All %%files should be placed here and keep them grouped ## %files -# exclude extra-xlators files -%if ( ! 0%{!?_without_extra_xlators:1} ) -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/encryption/rot-13.so -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/glupy.so -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/quiesce.so -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/selinux.so -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/testing/features/template.so -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/testing/performance/symlink-cache.so -%exclude %{python_sitelib}/* -%endif -# exclude regression-tests files -%if ( ! 0%{!?_without_regression_tests:1} ) -%exclude %{_prefix}/share/glusterfs/run-tests.sh -%exclude %{_prefix}/share/glusterfs/tests/* -%endif -%if ( ! 0%{?_build_server} ) -# exclude ganesha files -%exclude %{_prefix}/lib/ocf/* -%exclude %{_libexecdir}/ganesha/* -%exclude %{_prefix}/lib/ocf/resource.d/heartbeat/* -%exclude %{_sysconfdir}/ganesha/ganesha-ha.conf.sample - -# exclude incrementalapi -%exclude %{_libexecdir}/glusterfs/* -%exclude %{_sbindir}/gfind_missing_files -%exclude %{_libexecdir}/glusterfs/glusterfind -%exclude %{_bindir}/glusterfind -%exclude %{_libexecdir}/glusterfs/peer_add_secret_pub -# exclude eventsapi files -%exclude %{_sysconfdir}/glusterfs/eventsconfig.json -%exclude %{_sharedstatedir}/glusterd/events -%exclude %{_libexecdir}/glusterfs/events -%exclude %{_libexecdir}/glusterfs/peer_eventsapi.py* -%exclude %{_sbindir}/glustereventsd -%exclude %{_sbindir}/gluster-eventsapi -%exclude %{_datadir}/glusterfs/scripts/eventsdash.py* -%if ( 0%{?_with_systemd:1} ) -%exclude %{_unitdir}/glustereventsd.service -%exclude %_init_glusterfssharedstorage -%else -%exclude %{_sysconfdir}/init.d/glustereventsd -%endif -# exclude server files -%exclude %{_sharedstatedir}/glusterd/* -%exclude %{_sysconfdir}/glusterfs -%exclude %{_sysconfdir}/glusterfs/glusterd.vol -%exclude %{_sysconfdir}/glusterfs/glusterfs-georep-logrotate -%exclude %{_sysconfdir}/glusterfs/glusterfs-logrotate -%exclude %{_sysconfdir}/glusterfs/gluster-rsyslog-5.8.conf -%exclude %{_sysconfdir}/glusterfs/gluster-rsyslog-7.2.conf -%exclude %{_sysconfdir}/glusterfs/group-virt.example -%exclude %{_sysconfdir}/glusterfs/logger.conf.example -%exclude %_init_glusterd -%exclude %{_sysconfdir}/sysconfig/glusterd -%exclude %{_bindir}/glusterfind -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/arbiter.so -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/bit-rot.so -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/bitrot-stub.so -%if ( 0%{!?_without_tiering:1} ) -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/changetimerecorder.so -%endif -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/index.so -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/leases.so -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/locks.so -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/posix* -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/snapview-server.so -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/marker.so -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/quota* -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/trash.so -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/upcall.so -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/mgmt* -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/nfs* -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/performance/decompounder.so -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/protocol/server* -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/storage* -%if ( 0%{!?_without_tiering:1} ) -%exclude %{_libdir}/libgfdb.so.* -%endif -%exclude %{_sbindir}/gcron.py -%exclude %{_sbindir}/glfsheal -%exclude %{_sbindir}/glusterd -%exclude %{_sbindir}/gf_attach -%exclude %{_sbindir}/snap_scheduler.py -%exclude %{_datadir}/glusterfs/scripts/stop-all-gluster-processes.sh -%if ( 0%{?_with_systemd:1} ) -%exclude %{_libexecdir}/glusterfs/mount-shared-storage.sh -%endif -%exclude %{_sbindir}/conf.py* -%if 0%{?_tmpfilesdir:1} -%exclude %{_tmpfilesdir}/gluster.conf -%endif -%if ( 0%{?_with_firewalld:1} ) -%exclude %{_prefix}/lib/firewalld/services/glusterfs.xml -%endif -%endif -%doc ChangeLog COPYING-GPLV2 COPYING-LGPLV3 INSTALL README.md THANKS +%doc ChangeLog COPYING-GPLV2 COPYING-LGPLV3 INSTALL README.md THANKS COMMITMENT %{_mandir}/man8/*gluster*.8* +%if ( 0%{!?_without_server:1} ) %exclude %{_mandir}/man8/gluster.8* +%endif %dir %{_localstatedir}/log/glusterfs %if ( 0%{!?_without_rdma:1} ) %exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/rpc-transport/rdma* %endif +%if 0%{?!_without_server:1} %dir %{_datadir}/glusterfs %dir %{_datadir}/glusterfs/scripts %{_datadir}/glusterfs/scripts/post-upgrade-script-for-quota.sh %{_datadir}/glusterfs/scripts/pre-upgrade-script-for-quota.sh +%endif # xlators that are needed on the client- and on the server-side %dir %{_libdir}/glusterfs %dir %{_libdir}/glusterfs/%{version}%{?prereltag} @@ -1793,24 +1165,23 @@ exit 0 %dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator %dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/debug %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/debug/error-gen.so + %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/debug/delay-gen.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/debug/io-stats.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/debug/sink.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/debug/trace.so -%if ( ! ( 0%{?rhel} && 0%{?rhel} < 6 ) ) -# RHEL-5 based distributions have a too old openssl -%exclude %dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/encryption -%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/encryption/crypt.so -%endif %dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/access-control.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/barrier.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/cdc.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/changelog.so + %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/utime.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/gfid-access.so + %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/namespace.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/read-only.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/shard.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/snapview-client.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/worm.so + %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/cloudsync.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/meta.so %dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/performance %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/performance/io-cache.so @@ -1826,14 +1197,18 @@ exit 0 %dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/system %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/system/posix-acl.so %dir %attr(0775,gluster,gluster) %{_rundir}/gluster -%if 0%{?_tmpfilesdir:1} +%if 0%{?_tmpfilesdir:1} && 0%{!?_without_server:1} %{_tmpfilesdir}/gluster.conf %endif -%if ( ! 0%{?_build_server} ) -%exclude %{_libdir}/pkgconfig/libgfchangelog.pc -%exclude %{_libdir}/pkgconfig/libgfdb.pc -%exclude %{_sbindir}/gluster-setgfid2path -%exclude %{_mandir}/man8/gluster-setgfid2path.8* +%if ( 0%{?_without_extra_xlators:1} ) +%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/quiesce.so +%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/playground/template.so +%endif +%if ( 0%{?_without_regression_tests:1} ) +%exclude %{_datadir}/glusterfs/run-tests.sh +%exclude %{_datadir}/glusterfs/tests +%endif +%if 0%{?_without_server:1} %if ( 0%{?_with_systemd:1} ) %exclude %{_datadir}/glusterfs/scripts/control-cpu-load.sh %exclude %{_datadir}/glusterfs/scripts/control-mem.sh @@ -1855,44 +1230,29 @@ exit 0 %dir %{_includedir}/glusterfs/api %{_includedir}/glusterfs/api/* +%if ( 0%{!?_without_server:1} ) %files cli %{_sbindir}/gluster %{_mandir}/man8/gluster.8* %{_sysconfdir}/bash_completion.d/gluster +%endif + +%files cloudsync-plugins +%dir %{_libdir}/glusterfs/%{version}%{?prereltag}/cloudsync-plugins + %{_libdir}/glusterfs/%{version}%{?prereltag}/cloudsync-plugins/cloudsyncs3.so %files devel %dir %{_includedir}/glusterfs %{_includedir}/glusterfs/* %exclude %{_includedir}/glusterfs/api %exclude %{_libdir}/libgfapi.so -%if ( ! 0%{?_build_server} ) -%exclude %{_libdir}/libgfchangelog.so -%endif -%if ( 0%{!?_without_tiering:1} && ! 0%{?_build_server}) -%exclude %{_libdir}/libgfdb.so -%endif %{_libdir}/*.so -# Glupy Translator examples -%dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator -%dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features -%dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/glupy - %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/glupy/debug-trace.* - %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/glupy/helloworld.* - %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/glupy/negative.* -%if ( 0%{?_build_server} ) -%{_libdir}/pkgconfig/libgfchangelog.pc -%else +%if ( 0%{?_without_server:1} ) %exclude %{_libdir}/pkgconfig/libgfchangelog.pc -%endif -%if ( 0%{!?_without_tiering:1} && ! 0%{?_build_server}) -%exclude %{_libdir}/libgfdb.so -%endif -%if ( 0%{!?_without_tiering:1} && 0%{?_build_server}) -%{_libdir}/pkgconfig/libgfdb.pc +%exclude %{_libdir}/libgfchangelog.so %else -%if ( 0%{?rhel} && 0%{?rhel} >= 6 ) -%exclude %{_libdir}/pkgconfig/libgfdb.pc -%endif +%{_libdir}/pkgconfig/libgfchangelog.pc +%{_libdir}/libgfchangelog.so %endif %files client-xlators @@ -1905,24 +1265,10 @@ exit 0 %if ( 0%{!?_without_extra_xlators:1} ) %files extra-xlators %dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator -%dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/encryption - %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/encryption/rot-13.so %dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features - %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/glupy.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/quiesce.so -%dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/testing -%dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/testing/features - %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/testing/features/template.so -%dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/testing/performance - %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/testing/performance/symlink-cache.so -# Glupy Python files -%dir %{python2_sitelib}/gluster -%dir %{python2_sitelib}/gluster/glupy - %{python2_sitelib}/gluster/glupy/* -# Don't expect a .egg-info file on EL5 -%if ( ! ( 0%{?rhel} && 0%{?rhel} < 6 ) ) -%{python_sitelib}/glusterfs_glupy*.egg-info -%endif +%dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/playground + %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/playground/template.so %endif %files fuse @@ -1937,27 +1283,31 @@ exit 0 %if ( 0%{!?_without_fusermount:1} ) %{_bindir}/fusermount-glusterfs %endif -%if ( 0%{_for_fedora_koji_builds} ) -%if ( 0%{?rhel} && 0%{?rhel} <= 5 ) -%{_sysconfdir}/sysconfig/modules/glusterfs-fuse.modules -%endif + +%if ( 0%{?_with_gnfs:1} && 0%{!?_without_server:1} ) +%files gnfs +%dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator +%dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/nfs + %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/nfs/server.so +%ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/nfs +%ghost %attr(0600,-,-) %{_sharedstatedir}/glusterd/nfs/nfs-server.vol +%ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/nfs/run +%ghost %attr(0600,-,-) %{_sharedstatedir}/glusterd/nfs/run/nfs.pid %endif -%if ( 0%{?_build_server} ) -%files ganesha -%dir %{_libexecdir}/ganesha -%{_libexecdir}/ganesha/* -%{_prefix}/lib/ocf/resource.d/heartbeat/* -%{_sharedstatedir}/glusterd/hooks/1/start/post/S31ganesha-start.sh -%{_sysconfdir}/ganesha/ganesha-ha.conf.sample -%ghost %attr(0644,-,-) %config(noreplace) %{_sysconfdir}/ganesha/ganesha-ha.conf -%ghost %dir %attr(0755,-,-) %{_localstatedir}/run/gluster/shared_storage/nfs-ganesha -%ghost %dir %attr(0755,-,-) %{_localstatedir}/run/gluster/shared_storage/nfs-ganesha/exports -%ghost %attr(0644,-,-) %config(noreplace) %{_localstatedir}/run/gluster/shared_storage/nfs-ganesha/ganesha.conf -%ghost %attr(0644,-,-) %config(noreplace) %{_localstatedir}/run/gluster/shared_storage/nfs-ganesha/ganesha-ha.conf +%files thin-arbiter +%dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator +%dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features + %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/thin-arbiter.so +%dir %{_datadir}/glusterfs/scripts + %{_datadir}/glusterfs/scripts/setup-thin-arbiter.sh +%config %{_sysconfdir}/glusterfs/thin-arbiter.vol + +%if ( 0%{?_with_systemd:1} ) +%{_unitdir}/gluster-ta-volume.service %endif -%if ( 0%{?_build_server} ) + %if ( 0%{!?_without_georeplication:1} ) %files geo-replication %config(noreplace) %{_sysconfdir}/logrotate.d/glusterfs-georep @@ -1994,22 +1344,24 @@ exit 0 %{_datadir}/glusterfs/scripts/gsync-sync-gfid %{_datadir}/glusterfs/scripts/schedule_georep.py* %endif -%endif %files libs %{_libdir}/*.so.* %exclude %{_libdir}/libgfapi.* -%if ( 0%{!?_without_tiering:1} ) -# libgfdb is only needed server-side -%exclude %{_libdir}/libgfdb.* -%endif -%files -n python2-gluster +%files -n python%{_pythonver}-gluster # introducing glusterfs module in site packages. # so that all other gluster submodules can reside in the same namespace. +%if ( %{_usepython3} ) +%dir %{python3_sitelib}/gluster + %{python3_sitelib}/gluster/__init__.* + %{python3_sitelib}/gluster/__pycache__ + %{python3_sitelib}/gluster/cliutils +%else %dir %{python2_sitelib}/gluster %{python2_sitelib}/gluster/__init__.* %{python2_sitelib}/gluster/cliutils +%endif %if ( 0%{!?_without_rdma:1} ) %files rdma @@ -2017,44 +1369,44 @@ exit 0 %{_libdir}/glusterfs/%{version}%{?prereltag}/rpc-transport/rdma* %endif -%if ( 0%{?_build_server} ) %if ( 0%{!?_without_regression_tests:1} ) %files regression-tests %dir %{_datadir}/glusterfs %{_datadir}/glusterfs/run-tests.sh %{_datadir}/glusterfs/tests %exclude %{_datadir}/glusterfs/tests/vagrant -%exclude %{_datadir}/share/glusterfs/tests/basic/rpm.t -%endif %endif -%if ( 0%{?_build_server} ) %if ( 0%{!?_without_ocf:1} ) %files resource-agents # /usr/lib is the standard for OCF, also on x86_64 %{_prefix}/lib/ocf/resource.d/glusterfs %endif -%endif -%if ( 0%{?_build_server} ) +%if ( 0%{!?_without_server:1} ) %files server -%exclude %{_sharedstatedir}/glusterd/hooks/1/gsync-create/post/S56glusterd-geo-rep-create-post.sh %doc extras/clear_xattrs.sh # sysconf %config(noreplace) %{_sysconfdir}/glusterfs +%exclude %{_sysconfdir}/glusterfs/thin-arbiter.vol %exclude %{_sysconfdir}/glusterfs/eventsconfig.json +%exclude %{_sharedstatedir}/glusterd/nfs/nfs-server.vol +%exclude %{_sharedstatedir}/glusterd/nfs/run/nfs.pid +%if ( 0%{?_with_gnfs:1} ) +%exclude %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/nfs/* +%endif %config(noreplace) %{_sysconfdir}/sysconfig/glusterd %if ( 0%{_for_fedora_koji_builds} ) %config(noreplace) %{_sysconfdir}/sysconfig/glusterfsd %endif # init files -%_init_glusterd +%glusterd_svcfile %if ( 0%{_for_fedora_koji_builds} ) -%_init_glusterfsd +%glusterfsd_svcfile %endif %if ( 0%{?_with_systemd:1} ) -%_init_glusterfssharedstorage +%glusterfssharedstorage_svcfile %endif # binaries @@ -2075,10 +1427,7 @@ exit 0 %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/arbiter.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/bit-rot.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/bitrot-stub.so -%if ( 0%{!?_without_tiering:1} ) - %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/changetimerecorder.so - %{_libdir}/libgfdb.so.* -%endif + %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/sdfs.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/index.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/locks.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/posix* @@ -2089,13 +1438,11 @@ exit 0 %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/trash.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/upcall.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/features/leases.so - %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/nfs* %dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/mgmt %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/mgmt/glusterd.so %dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/protocol %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/protocol/server.so %dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/storage - %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/storage/bd.so %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/storage/posix.so %dir %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/performance %{_libdir}/glusterfs/%{version}%{?prereltag}/xlator/performance/decompounder.so @@ -2113,9 +1460,9 @@ exit 0 %attr(0644,-,-) %{_sharedstatedir}/glusterd/groups/virt %attr(0644,-,-) %{_sharedstatedir}/glusterd/groups/metadata-cache %attr(0644,-,-) %{_sharedstatedir}/glusterd/groups/gluster-block + %attr(0644,-,-) %{_sharedstatedir}/glusterd/groups/nl-cache %attr(0644,-,-) %{_sharedstatedir}/glusterd/groups/db-workload %attr(0644,-,-) %{_sharedstatedir}/glusterd/groups/distributed-virt - %attr(0644,-,-) %{_sharedstatedir}/glusterd/groups/nl-cache %attr(0644,-,-) %{_sharedstatedir}/glusterd/groups/samba %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/glusterfind %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/glusterfind/.keys @@ -2159,11 +1506,7 @@ exit 0 %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/stop/pre %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/stop/pre/S30samba-stop.sh %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/stop/pre/S29CTDB-teardown.sh -%ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/nfs -%ghost %attr(0600,-,-) %{_sharedstatedir}/glusterd/nfs/nfs-server.vol -%ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/nfs/run -%ghost %attr(0600,-,-) %{_sharedstatedir}/glusterd/nfs/run/nfs.pid -%ghost %attr(0600,-,-) %{_sharedstatedir}/glusterd/options +%config(noreplace) %ghost %attr(0600,-,-) %{_sharedstatedir}/glusterd/options %ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/peers %ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/quotad %ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/scrub @@ -2190,13 +1533,32 @@ exit 0 %if ( 0%{?_with_firewalld:1} ) %{_prefix}/lib/firewalld/services/glusterfs.xml %endif +# end of server files %endif +# Events +%if ( 0%{!?_without_events:1} ) +%files events +%config(noreplace) %{_sysconfdir}/glusterfs/eventsconfig.json +%dir %{_sharedstatedir}/glusterd +%dir %{_sharedstatedir}/glusterd/events +%dir %{_libexecdir}/glusterfs + %{_libexecdir}/glusterfs/gfevents + %{_libexecdir}/glusterfs/peer_eventsapi.py* +%{_sbindir}/glustereventsd +%{_sbindir}/gluster-eventsapi +%{_datadir}/glusterfs/scripts/eventsdash.py* +%if ( 0%{?_with_systemd:1} ) +%{_unitdir}/glustereventsd.service +%else +%{_sysconfdir}/init.d/glustereventsd +%endif +%endif ##----------------------------------------------------------------------------- ## All %pretrans should be placed here and keep them sorted ## -%if 0%{?_build_server} +%if 0%{!?_without_server:1} %pretrans -p if not posix.access("/bin/bash", "x") then -- initial installation, no shell, no running glusterfsd @@ -2338,7 +1700,6 @@ if not (ok == 0) then end - %pretrans client-xlators -p if not posix.access("/bin/bash", "x") then -- initial installation, no shell, no running glusterfsd @@ -2372,41 +1733,6 @@ if not (ok == 0) then end - -%pretrans devel -p -if not posix.access("/bin/bash", "x") then - -- initial installation, no shell, no running glusterfsd - return 0 -end - --- TODO: move this completely to a lua script --- For now, we write a temporary bash script and execute that. - -script = [[#!/bin/sh -pidof -c -o %PPID -x glusterfsd &>/dev/null - -if [ $? -eq 0 ]; then - pushd . > /dev/null 2>&1 - for volume in /var/lib/glusterd/vols/*; do cd $volume; - vol_type=`grep '^type=' info | awk -F'=' '{print $2}'` - volume_started=`grep '^status=' info | awk -F'=' '{print $2}'` - if [ $vol_type -eq 0 ] && [ $volume_started -eq 1 ] ; then - exit 1; - fi - done - - popd > /dev/null 2>&1 - exit 1; -fi -]] - -ok, how, val = os.execute(script) -if not (ok == 0) then - error("Detected running glusterfs processes", ok) -end - - - %pretrans fuse -p if not posix.access("/bin/bash", "x") then -- initial installation, no shell, no running glusterfsd @@ -2634,7 +1960,7 @@ if [ $? -eq 0 ]; then # glusterd _was_ running, we killed it, it exited after *.upgrade=on, # so start it again - %_init_start glusterd + %service_start glusterd else glusterd --xlator-option *.upgrade=on -N @@ -2645,199 +1971,9 @@ fi %endif -# Events -%if ( 0%{?_build_server} ) -%if ( 0%{!?_without_events:1} ) -%files events -%config(noreplace) %{_sysconfdir}/glusterfs/eventsconfig.json -%dir %{_sharedstatedir}/glusterd -%dir %{_sharedstatedir}/glusterd/events -%dir %{_libexecdir}/glusterfs - %{_libexecdir}/glusterfs/events - %{_libexecdir}/glusterfs/peer_eventsapi.py* -%{_sbindir}/glustereventsd -%{_sbindir}/gluster-eventsapi -%{_datadir}/glusterfs/scripts/eventsdash.py* -%if ( 0%{?_with_systemd:1} ) -%{_unitdir}/glustereventsd.service -%else -%{_sysconfdir}/init.d/glustereventsd -%endif -%endif -%endif - %changelog -* Wed Mar 13 2019 Milind Changire - 3.12.2-47 -- fixes bugs bz#1458215 bz#1661258 bz#1669020 bz#1683893 - -* Thu Mar 07 2019 Milind Changire - 3.12.2-46 -- fixes bugs bz#1668327 bz#1684648 - -* Thu Feb 21 2019 Milind Changire - 3.12.2-45 -- fixes bugs bz#1678232 - -* Thu Feb 14 2019 Milind Changire - 3.12.2-43 -- fixes bugs bz#1676904 - -* Tue Feb 12 2019 Milind Changire - 3.12.2-42 -- fixes bugs bz#1410145 - -* Tue Feb 12 2019 Milind Changire - 3.12.2-41 -- fixes bugs bz#1390151 bz#1410145 bz#1429190 bz#1510752 bz#1511779 - bz#1570958 bz#1574490 bz#1595246 bz#1618669 bz#1661393 bz#1668989 bz#1669020 - -* Fri Jan 25 2019 Milind Changire - 3.12.2-40 -- fixes bugs bz#1668304 bz#1669020 - -* Mon Jan 21 2019 Milind Changire - 3.12.2-39 -- fixes bugs bz#1667169 - -* Fri Jan 18 2019 Milind Changire - 3.12.2-38 -- fixes bugs bz#1664235 - -* Mon Jan 14 2019 Milind Changire - 3.12.2-37 -- fixes bugs bz#1662059 bz#1662828 bz#1664529 - -* Fri Jan 04 2019 Milind Changire - 3.12.2-36 -- fixes bugs bz#1290124 bz#1655385 bz#1663232 - -* Wed Jan 02 2019 Milind Changire - 3.12.2-35 -- fixes bugs bz#1654161 - -* Wed Dec 19 2018 Milind Changire - 3.12.2-34 -- fixes bugs bz#1648893 bz#1656357 - -* Tue Dec 18 2018 Milind Changire - 3.12.2-33 -- fixes bugs bz#1350745 bz#1362129 bz#1541568 bz#1597252 bz#1599220 - bz#1633177 bz#1637564 bz#1639476 bz#1639568 bz#1643370 bz#1645480 bz#1648296 - bz#1648893 bz#1651040 bz#1651460 bz#1652466 bz#1652537 bz#1653224 bz#1653613 - bz#1654103 bz#1654161 bz#1655385 bz#1655578 bz#1656357 bz#1659439 - -* Fri Dec 07 2018 Milind Changire - 3.12.2-32 -- fixes bugs bz#1656924 - -* Wed Dec 05 2018 Milind Changire - 3.12.2-31 -- fixes bugs bz#1653073 - -* Tue Dec 04 2018 Milind Changire - 3.12.2-30 -- fixes bugs bz#1650138 bz#1653073 - -* Thu Nov 22 2018 Milind Changire - 3.12.2-29 -- fixes bugs bz#1650138 - -* Tue Nov 20 2018 Milind Changire - 3.12.2-28 -- fixes bugs bz#1626350 bz#1648210 bz#1649651 bz#1650138 - -* Fri Nov 09 2018 Milind Changire - 3.12.2-27 -- respin - -* Fri Nov 09 2018 Milind Changire - 3.12.2-26 -- fixes bugs bz#1479446 bz#1520882 bz#1579758 bz#1598407 bz#1599808 - bz#1603118 bz#1619357 bz#1622001 bz#1622308 bz#1631166 bz#1631418 bz#1632563 - bz#1634649 bz#1635071 bz#1635100 bz#1635136 bz#1636291 bz#1638069 bz#1640347 - bz#1642854 bz#1643035 bz#1644120 bz#1644279 bz#1645916 bz#1647675 - -* Thu Oct 25 2018 Milind Changire - 3.12.2-25 -- fixes bugs bz#1641586 - -* Tue Oct 23 2018 Milind Changire - 3.12.2-24 -- fixes bugs bz#1618221 bz#1641489 - -* Tue Oct 16 2018 Sunil Kumar Acharya - 3.12.2-23 -- fixes bugs bz#1631372 bz#1636902 - -* Tue Oct 09 2018 Milind Changire - 3.12.2-22 -- fixes bugs bz#1631329 bz#1631372 - -* Wed Oct 03 2018 Milind Changire - 3.12.2-21 -- fixes bugs bz#1623749 bz#1630997 - -* Sat Sep 22 2018 Sunil Kumar Acharya - 3.12.2-20 -- Build respin with appropriate target version. - -* Sat Sep 22 2018 Sunil Kumar Acharya - 3.12.2-19 -- fixes bugs bz#1459709 bz#1610743 bz#1618221 bz#1619627 bz#1622649 - bz#1623749 bz#1623874 bz#1624444 bz#1625622 bz#1626780 bz#1627098 bz#1627617 - bz#1627639 bz#1630688 - -* Mon Aug 27 2018 Milind Changire - 3.12.2-18 -- fixes bugs bz#1524336 bz#1622029 bz#1622452 - -* Thu Aug 23 2018 Milind Changire - 3.12.2-17 -- fixes bugs bz#1615578 bz#1619416 bz#1619538 bz#1620469 bz#1620765 - -* Tue Aug 14 2018 Milind Changire - 3.12.2-16 -- fixes bugs bz#1569657 bz#1608352 bz#1609163 bz#1609724 bz#1610825 - bz#1611151 bz#1612098 bz#1615338 bz#1615440 - -* Fri Jul 27 2018 Milind Changire - 3.12.2-15 -- fixes bugs bz#1589279 bz#1598384 bz#1599362 bz#1599998 bz#1600790 - bz#1601331 bz#1603103 - -* Wed Jul 18 2018 Milind Changire - 3.12.2-14 -- fixes bugs bz#1547903 bz#1566336 bz#1568896 bz#1578716 bz#1581047 - bz#1581231 bz#1582066 bz#1593865 bz#1597506 bz#1597511 bz#1597654 bz#1597768 - bz#1598105 bz#1598356 bz#1599037 bz#1599823 bz#1600057 bz#1601314 - -* Thu Jun 28 2018 Milind Changire - 3.12.2-13 -- fixes bugs bz#1493085 bz#1518710 bz#1554255 bz#1558948 bz#1558989 - bz#1559452 bz#1567001 bz#1569312 bz#1569951 bz#1575539 bz#1575557 bz#1577051 - bz#1580120 bz#1581184 bz#1581553 bz#1581647 bz#1582119 bz#1582129 bz#1582417 - bz#1583047 bz#1588408 bz#1592666 bz#1594658 - -* Thu May 24 2018 Milind Changire - 3.12.2-12 -- fixes bugs bz#1558989 bz#1580344 bz#1581057 bz#1581219 - -* Thu May 17 2018 Milind Changire - 3.12.2-11 -- fixes bugs bz#1558989 bz#1575555 bz#1578647 - -* Tue May 15 2018 Milind Changire - 3.12.2-10 -- fixes bugs bz#1488120 bz#1565577 bz#1568297 bz#1570586 bz#1572043 - bz#1572075 bz#1575840 bz#1575877 - -* Wed May 09 2018 Milind Changire - 3.12.2-9 -- fixes bugs bz#1546717 bz#1557551 bz#1558948 bz#1561999 bz#1563804 - bz#1565015 bz#1565119 bz#1565399 bz#1565577 bz#1567100 bz#1567899 bz#1568374 - bz#1568969 bz#1569490 bz#1570514 bz#1570541 bz#1570582 bz#1571645 bz#1572087 - bz#1572585 bz#1575895 - -* Fri Apr 20 2018 Milind Changire - 3.12.2-8 -- fixes bugs bz#1466129 bz#1475779 bz#1523216 bz#1535281 bz#1546941 - bz#1550315 bz#1550991 bz#1553677 bz#1554291 bz#1559452 bz#1560955 bz#1562744 - bz#1563692 bz#1565962 bz#1567110 bz#1569457 - -* Wed Apr 04 2018 Milind Changire - 3.12.2-7 -- fixes bugs bz#958062 bz#1186664 bz#1226874 bz#1446046 bz#1529451 bz#1550315 - bz#1557365 bz#1559884 bz#1561733 - -* Mon Mar 26 2018 Milind Changire - 3.12.2-6 -- fixes bugs bz#1491785 bz#1518710 bz#1523599 bz#1528733 bz#1550474 - bz#1550982 bz#1551186 bz#1552360 bz#1552414 bz#1552425 bz#1554255 bz#1554905 - bz#1555261 bz#1556895 bz#1557297 bz#1559084 bz#1559788 - -* Wed Mar 07 2018 Milind Changire - 3.12.2-5 -- fixes bugs bz#1378371 bz#1384983 bz#1472445 bz#1493085 bz#1508999 - bz#1516638 bz#1518260 bz#1529072 bz#1530519 bz#1537357 bz#1540908 bz#1541122 - bz#1541932 bz#1543068 bz#1544382 bz#1544852 bz#1545570 bz#1546075 bz#1546945 - bz#1546960 bz#1547012 bz#1549497 - -* Mon Feb 12 2018 Milind Changire - 3.12.2-4 -- fixes bugs bz#1446125 bz#1467536 bz#1530146 bz#1540600 bz#1540664 - bz#1540961 bz#1541830 bz#1543296 - -* Mon Feb 05 2018 Milind Changire - 3.12.2-3 -- fixes bugs bz#1446125 bz#1463592 bz#1516249 bz#1517463 bz#1527309 - bz#1530325 bz#1531041 bz#1539699 bz#1540011 - -* Wed Jan 17 2018 Milind Changire - 3.12.2-2 -- fixes bugs bz#1264911 bz#1277924 bz#1286820 bz#1360331 bz#1401969 - bz#1410719 bz#1419438 bz#1426042 bz#1444820 bz#1459101 bz#1464150 bz#1464350 - bz#1466122 bz#1466129 bz#1467903 bz#1468972 bz#1476876 bz#1484446 bz#1492591 - bz#1498391 bz#1498730 bz#1499865 bz#1500704 bz#1501345 bz#1505570 bz#1507361 - bz#1507394 bz#1509102 bz#1509191 bz#1509810 bz#1509833 bz#1511766 bz#1512470 - bz#1512496 bz#1512963 bz#1515051 bz#1519076 bz#1519740 bz#1534253 bz#1534530 - -* Wed Nov 15 2017 Milind Changire - 3.12.2-1 -- rebase to upstream glusterfs at v3.12.2 -- fixes bugs bz#1442983 bz#1474745 bz#1503244 bz#1505363 bz#1509102 +* Mon Apr 08 2019 Milind Changire - 6.0-1 +- rebase to upstream glusterfs at v6.0 +- fixes bugs bz#1493284 bz#1578703 bz#1600918 bz#1670415 bz#1691620 + bz#1693935 bz#1695057 diff --git a/sources b/sources index 9e28f93..91cad7c 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -5119d330c92f155af7f161a8fa40a942 glusterfs-3.12.2.tar.gz +a313e3e38e9476b2ebb21bbdbabb2190 glusterfs-6.0.tar.gz