summaryrefslogtreecommitdiffstats
path: root/Assemble.c
diff options
context:
space:
mode:
authorGuoqing Jiang <gqjiang@suse.com>2015-06-10 07:42:11 +0200
committerNeilBrown <neilb@suse.de>2015-06-17 01:33:39 +0200
commit0aa2f15b207c46ccaf4aa7a082ef7fdd186c7609 (patch)
treee1ad41f2584f562a240ad993b181dc604f3a6dfa /Assemble.c
parentSkip clustered devices in incremental (diff)
downloadmdadm-0aa2f15b207c46ccaf4aa7a082ef7fdd186c7609.tar.xz
mdadm-0aa2f15b207c46ccaf4aa7a082ef7fdd186c7609.zip
mdadm: add the ability to change cluster name
To support change the cluster name, the commit do the followings: 1. extend original write_bitmap function for new scenario. 2. add the scenarion to handle the modification of cluster's name in write_bitmap1. 3. let the cluster name also show in examine_super1 and detail_super1 Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'Assemble.c')
-rw-r--r--Assemble.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/Assemble.c b/Assemble.c
index 42710a8a..12ac299f 100644
--- a/Assemble.c
+++ b/Assemble.c
@@ -626,7 +626,10 @@ static int load_devices(struct devs *devices, char *devmap,
if (strcmp(c->update, "byteorder") == 0)
err = 0;
- else
+ else if (strcmp(c->update, "home-cluster") == 0) {
+ tst->cluster_name = c->homecluster;
+ tst->ss->write_bitmap(tst, dfd, NameUpdate);
+ } else
err = tst->ss->update_super(tst, content, c->update,
devname, c->verbose,
ident->uuid_set,