summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt
diff options
context:
space:
mode:
authorHari Gowtham <hgowtham@redhat.com>2015-11-03 18:23:56 +0530
committerDan Lambright <dlambrig@redhat.com>2015-11-04 04:51:25 -0800
commit698038f67c00bd528a7be89a0fccdd52914e01ce (patch)
treea8a6032229f2a17575696701ad069d223e449480 /xlators/mgmt
parentee0b1a3bf11a4d05696212d91c932ddb7c7091ee (diff)
v info for disperse count fails while upgrading
The upgrade from 3.7.5-3 to 3.7.5-5 causes the type and number of bricks for the cold tier to be printed wrong. Change-Id: Ia45b97c35fef88f9c66e15e5bdb93fd30cb342af BUG: 1277481 Signed-off-by: Hari Gowtham <hgowtham@redhat.com> Reviewed-on: http://review.gluster.org/12495 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
Diffstat (limited to 'xlators/mgmt')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-store.c16
1 files changed, 12 insertions, 4 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-store.c b/xlators/mgmt/glusterd/src/glusterd-store.c
index 6d4fce23463..66cc51f5242 100644
--- a/xlators/mgmt/glusterd/src/glusterd-store.c
+++ b/xlators/mgmt/glusterd/src/glusterd-store.c
@@ -2763,10 +2763,18 @@ glusterd_store_update_volinfo (glusterd_volinfo_t *volinfo)
break;
case GF_CLUSTER_TYPE_TIER:
- volinfo->tier_info.cold_dist_leaf_count =
- glusterd_calc_dist_leaf_count (
- volinfo->tier_info.cold_replica_count, 1);
- break;
+ if (volinfo->tier_info.cold_type ==
+ GF_CLUSTER_TYPE_DISPERSE)
+ volinfo->tier_info.cold_dist_leaf_count
+ = volinfo->disperse_count;
+ else
+ volinfo->tier_info.cold_dist_leaf_count
+ = glusterd_calc_dist_leaf_count (
+ volinfo->tier_info.
+ cold_replica_count,
+ 1);
+
+ break;
default:
GF_ASSERT (0);