Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 1 | /** |
| 2 | * |
| 3 | * Upgrade Ceph mon/mgr/osd/rgw/client |
| 4 | * |
| 5 | * Requred parameters: |
| 6 | * SALT_MASTER_URL URL of Salt master |
| 7 | * SALT_MASTER_CREDENTIALS Credentials to the Salt API |
| 8 | * |
| 9 | * ADMIN_HOST Host (minion id) with admin keyring and /etc/crushmap file present |
| 10 | * CLUSTER_FLAGS Comma separated list of tags to apply to cluster |
| 11 | * WAIT_FOR_HEALTHY Wait for cluster rebalance before stoping daemons |
| 12 | * ORIGIN_RELEASE Ceph release version before upgrade |
| 13 | * TARGET_RELEASE Ceph release version after upgrade |
| 14 | * STAGE_UPGRADE_MON Set to True if Ceph mon nodes upgrade is desired |
| 15 | * STAGE_UPGRADE_MGR Set to True if Ceph mgr nodes upgrade or new deploy is desired |
| 16 | * STAGE_UPGRADE_OSD Set to True if Ceph osd nodes upgrade is desired |
| 17 | * STAGE_UPGRADE_RGW Set to True if Ceph rgw nodes upgrade is desired |
| 18 | * STAGE_UPGRADE_CLIENT Set to True if Ceph client nodes upgrade is desired (includes for example ctl/cmp nodes) |
Michael Vollman | afe9152 | 2019-05-07 08:10:00 -0400 | [diff] [blame] | 19 | * STAGE_FINALIZE Set to True if configs recommended for TARGET_RELEASE should be set after upgrade is done |
| 20 | * BACKUP_ENABLED Select to copy the disks of Ceph VMs before upgrade and backup Ceph directories on OSD nodes |
| 21 | * BACKUP_DIR Select the target dir to backup to when BACKUP_ENABLED |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 22 | * |
| 23 | */ |
| 24 | |
| 25 | common = new com.mirantis.mk.Common() |
| 26 | salt = new com.mirantis.mk.Salt() |
| 27 | def python = new com.mirantis.mk.Python() |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 28 | ceph = new com.mirantis.mk.Ceph() |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 29 | |
Tomek Jaroszyk | b7c88d5 | 2020-08-18 10:21:54 +0200 | [diff] [blame^] | 30 | pepperEnv = "pepperEnv" |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 31 | flags = CLUSTER_FLAGS.tokenize(',') |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 32 | |
Mateusz Los | c5de5c8 | 2020-05-11 10:37:23 +0200 | [diff] [blame] | 33 | def runHighState = RUNHIGHSTATE |
| 34 | |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 35 | def backup(master, target) { |
Jiri Broulik | 96c867a | 2017-11-07 16:14:10 +0100 | [diff] [blame] | 36 | stage("backup ${target}") { |
| 37 | |
Jiri Broulik | fd2dcaf | 2017-12-08 15:19:51 +0100 | [diff] [blame] | 38 | if (target == 'osd') { |
Jiri Broulik | 96c867a | 2017-11-07 16:14:10 +0100 | [diff] [blame] | 39 | try { |
Jiri Broulik | fd2dcaf | 2017-12-08 15:19:51 +0100 | [diff] [blame] | 40 | salt.enforceState(master, "I@ceph:${target}", "ceph.backup", true) |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 41 | salt.cmdRun(master, "I@ceph:${target}", "su root -c '/usr/local/bin/ceph-backup-runner-call.sh'") |
Jiri Broulik | 96c867a | 2017-11-07 16:14:10 +0100 | [diff] [blame] | 42 | } catch (Exception e) { |
Jiri Broulik | fd2dcaf | 2017-12-08 15:19:51 +0100 | [diff] [blame] | 43 | common.errorMsg(e) |
| 44 | common.errorMsg("Make sure Ceph backup on OSD nodes is enabled") |
| 45 | throw new InterruptedException() |
Jiri Broulik | 96c867a | 2017-11-07 16:14:10 +0100 | [diff] [blame] | 46 | } |
Jiri Broulik | fd2dcaf | 2017-12-08 15:19:51 +0100 | [diff] [blame] | 47 | } else { |
| 48 | def _pillar = salt.getGrain(master, 'I@salt:master', 'domain') |
| 49 | def domain = _pillar['return'][0].values()[0].values()[0] |
| 50 | |
| 51 | def kvm_pillar = salt.getGrain(master, 'I@salt:control', 'id') |
| 52 | def kvm01 = kvm_pillar['return'][0].values()[0].values()[0] |
| 53 | |
| 54 | def target_pillar = salt.getGrain(master, "I@ceph:${target}", 'host') |
| 55 | def minions = target_pillar['return'][0].values() |
| 56 | for (minion in minions) { |
| 57 | def minion_name = minion.values()[0] |
| 58 | def provider_pillar = salt.getPillar(master, "${kvm01}", "salt:control:cluster:internal:node:${minion_name}:provider") |
| 59 | def minionProvider = provider_pillar['return'][0].values()[0] |
| 60 | |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 61 | ceph.waitForHealthy(master, ADMIN_HOST, flags) |
Jiri Broulik | fd2dcaf | 2017-12-08 15:19:51 +0100 | [diff] [blame] | 62 | try { |
Michael Vollman | afe9152 | 2019-05-07 08:10:00 -0400 | [diff] [blame] | 63 | salt.cmdRun(master, "${minionProvider}", "[ ! -f ${BACKUP_DIR}/${minion_name}.${domain}.qcow2.bak ] && virsh destroy ${minion_name}.${domain}") |
Jiri Broulik | fd2dcaf | 2017-12-08 15:19:51 +0100 | [diff] [blame] | 64 | } catch (Exception e) { |
| 65 | common.warningMsg('Backup already exists') |
| 66 | } |
| 67 | try { |
Michael Vollman | afe9152 | 2019-05-07 08:10:00 -0400 | [diff] [blame] | 68 | salt.cmdRun(master, "${minionProvider}", "[ ! -f ${BACKUP_DIR}/${minion_name}.${domain}.qcow2.bak ] && cp /var/lib/libvirt/images/${minion_name}.${domain}/system.qcow2 ${BACKUP_DIR}/${minion_name}.${domain}.qcow2.bak") |
Jiri Broulik | fd2dcaf | 2017-12-08 15:19:51 +0100 | [diff] [blame] | 69 | } catch (Exception e) { |
| 70 | common.warningMsg('Backup already exists') |
| 71 | } |
| 72 | try { |
| 73 | salt.cmdRun(master, "${minionProvider}", "virsh start ${minion_name}.${domain}") |
| 74 | } catch (Exception e) { |
| 75 | common.warningMsg(e) |
| 76 | } |
| 77 | salt.minionsReachable(master, 'I@salt:master', "${minion_name}*") |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 78 | ceph.waitForHealthy(master, ADMIN_HOST, flags) |
Jiri Broulik | 96c867a | 2017-11-07 16:14:10 +0100 | [diff] [blame] | 79 | } |
Jiri Broulik | 96c867a | 2017-11-07 16:14:10 +0100 | [diff] [blame] | 80 | } |
| 81 | } |
| 82 | return |
| 83 | } |
| 84 | |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 85 | def upgrade(master, target) { |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 86 | |
| 87 | stage("Change ${target} repos") { |
| 88 | salt.runSaltProcessStep(master, "I@ceph:${target}", 'saltutil.refresh_pillar', [], null, true, 5) |
| 89 | salt.enforceState(master, "I@ceph:${target}", 'linux.system.repo', true) |
| 90 | } |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 91 | if (target == 'mgr') { |
| 92 | stage('Run ceph mgr state') { |
Tomek Jaroszyk | 933011a | 2020-04-07 11:20:31 +0200 | [diff] [blame] | 93 | salt.enforceState(master, "I@ceph:mgr", "ceph.mgr", true, failOnError=false, retries=3, retries_wait=10) |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 94 | } |
| 95 | } |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 96 | if (target == 'common') { |
| 97 | stage('Upgrade ceph-common pkgs') { |
Tomek Jaroszyk | 933011a | 2020-04-07 11:20:31 +0200 | [diff] [blame] | 98 | salt.runSaltProcessStep(master, "I@ceph:${target}", 'pkg.install', ["ceph-common"], 'only_upgrade=True') |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 99 | } |
| 100 | } else { |
Jiri Broulik | 96c867a | 2017-11-07 16:14:10 +0100 | [diff] [blame] | 101 | minions = salt.getMinions(master, "I@ceph:${target}") |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 102 | |
Jiri Broulik | 96c867a | 2017-11-07 16:14:10 +0100 | [diff] [blame] | 103 | for (minion in minions) { |
| 104 | // upgrade pkgs |
| 105 | if (target == 'radosgw') { |
| 106 | stage('Upgrade radosgw pkgs') { |
Tomek Jaroszyk | 933011a | 2020-04-07 11:20:31 +0200 | [diff] [blame] | 107 | salt.runSaltProcessStep(master, "I@ceph:${target}", 'pkg.install', [target], 'only_upgrade=True') |
Jiri Broulik | 96c867a | 2017-11-07 16:14:10 +0100 | [diff] [blame] | 108 | } |
| 109 | } else { |
| 110 | stage("Upgrade ${target} pkgs on ${minion}") { |
Tomek Jaroszyk | 933011a | 2020-04-07 11:20:31 +0200 | [diff] [blame] | 111 | salt.runSaltProcessStep(master, "${minion}", 'pkg.install', ["ceph-${target}"], 'only_upgrade=True') |
Jiri Broulik | 96c867a | 2017-11-07 16:14:10 +0100 | [diff] [blame] | 112 | } |
| 113 | } |
| 114 | // restart services |
| 115 | stage("Restart ${target} services on ${minion}") { |
Mateusz Los | c5de5c8 | 2020-05-11 10:37:23 +0200 | [diff] [blame] | 116 | if(target == 'osd') { |
Tomek Jaroszyk | 933011a | 2020-04-07 11:20:31 +0200 | [diff] [blame] | 117 | def ceph_disks = salt.getGrain(master, minion, 'ceph')['return'][0].values()[0].values()[0]['ceph_disk'] |
Mateusz Los | 80bb925 | 2020-02-06 13:33:42 +0100 | [diff] [blame] | 118 | ceph_disks.each { osd, param -> |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 119 | salt.cmdRun(master, "${minion}", "systemctl restart ceph-${target}@${osd}") |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 120 | } |
Mateusz Los | c5de5c8 | 2020-05-11 10:37:23 +0200 | [diff] [blame] | 121 | } |
| 122 | else { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 123 | salt.cmdRun(master, "${minion}", "systemctl restart ceph-${target}.target") |
Mateusz Los | c5de5c8 | 2020-05-11 10:37:23 +0200 | [diff] [blame] | 124 | } |
| 125 | |
| 126 | ceph.waitForHealthy(master, ADMIN_HOST, flags) |
| 127 | if(runHighState) { |
Tomek Jaroszyk | b7c88d5 | 2020-08-18 10:21:54 +0200 | [diff] [blame^] | 128 | salt.enforceHighstate(master, "I@ceph:${target}") |
Mateusz Los | a4b024f | 2019-09-18 21:58:54 +0200 | [diff] [blame] | 129 | } |
Jiri Broulik | 96c867a | 2017-11-07 16:14:10 +0100 | [diff] [blame] | 130 | } |
| 131 | |
| 132 | stage("Verify services for ${minion}") { |
| 133 | sleep(10) |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 134 | salt.cmdRun(master, "${minion}", "systemctl status ceph-${target}.target") |
Jiri Broulik | 96c867a | 2017-11-07 16:14:10 +0100 | [diff] [blame] | 135 | } |
| 136 | |
| 137 | stage('Ask for manual confirmation') { |
Mateusz Los | e1ae600 | 2019-05-08 11:55:39 +0200 | [diff] [blame] | 138 | runCephCommand(master, ADMIN_HOST, "ceph -s") |
Jiri Broulik | 96c867a | 2017-11-07 16:14:10 +0100 | [diff] [blame] | 139 | input message: "From the verification command above, please check Ceph ${target} joined the cluster correctly. If so, Do you want to continue to upgrade next node?" |
| 140 | } |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 141 | } |
| 142 | } |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 143 | salt.cmdRun(master, ADMIN_HOST, "ceph versions") |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 144 | sleep(5) |
| 145 | return |
| 146 | } |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 147 | |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 148 | timeout(time: 12, unit: 'HOURS') { |
| 149 | node("python") { |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 150 | |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 151 | // create connection to salt master |
| 152 | python.setupPepperVirtualenv(pepperEnv, SALT_MASTER_URL, SALT_MASTER_CREDENTIALS) |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 153 | |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 154 | stage('Check user choices') { |
Alena Kiseleva | 30f780c | 2019-01-22 17:09:33 +0300 | [diff] [blame] | 155 | if (STAGE_UPGRADE_RGW.toBoolean() == true) { |
| 156 | // if rgw, check if other stuff has required version |
| 157 | def mon_ok = true |
| 158 | if (STAGE_UPGRADE_MON.toBoolean() == false) { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 159 | def mon_v = salt.cmdRun(pepperEnv, ADMIN_HOST, "ceph mon versions")['return'][0].values()[0] |
Alena Kiseleva | 30f780c | 2019-01-22 17:09:33 +0300 | [diff] [blame] | 160 | mon_ok = mon_v.contains("${TARGET_RELEASE}") && !mon_v.contains("${ORIGIN_RELEASE}") |
| 161 | } |
| 162 | def mgr_ok = true |
| 163 | if (STAGE_UPGRADE_MGR.toBoolean() == false) { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 164 | def mgr_v = salt.cmdRun(pepperEnv, ADMIN_HOST, "ceph mgr versions")['return'][0].values()[0] |
Alena Kiseleva | 30f780c | 2019-01-22 17:09:33 +0300 | [diff] [blame] | 165 | mgr_ok = mgr_v.contains("${TARGET_RELEASE}") && !mgr_v.contains("${ORIGIN_RELEASE}") |
| 166 | } |
| 167 | def osd_ok = true |
| 168 | if (STAGE_UPGRADE_OSD.toBoolean() == false) { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 169 | def osd_v = salt.cmdRun(pepperEnv, ADMIN_HOST, "ceph osd versions")['return'][0].values()[0] |
Alena Kiseleva | 30f780c | 2019-01-22 17:09:33 +0300 | [diff] [blame] | 170 | osd_ok = osd_v.contains("${TARGET_RELEASE}") && !osd_v.contains("${ORIGIN_RELEASE}") |
| 171 | } |
| 172 | if (!mon_ok || !osd_ok || !mgr_ok) { |
| 173 | common.errorMsg('You may choose stages in any order, but RGW should be upgraded last') |
| 174 | throw new InterruptedException() |
| 175 | } |
| 176 | } |
| 177 | } |
| 178 | |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 179 | if (BACKUP_ENABLED.toBoolean() == true) { |
| 180 | if (STAGE_UPGRADE_MON.toBoolean() == true) { |
| 181 | backup(pepperEnv, 'mon') |
| 182 | } |
| 183 | if (STAGE_UPGRADE_RGW.toBoolean() == true) { |
| 184 | backup(pepperEnv, 'radosgw') |
| 185 | } |
| 186 | if (STAGE_UPGRADE_OSD.toBoolean() == true) { |
| 187 | backup(pepperEnv, 'osd') |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 188 | } |
| 189 | } |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 190 | |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 191 | if (flags.size() > 0) { |
| 192 | stage('Set cluster flags') { |
| 193 | for (flag in flags) { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 194 | salt.cmdRun(pepperEnv, ADMIN_HOST, 'ceph osd set ' + flag) |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 195 | } |
PGlazov | 9085e84 | 2020-02-12 18:07:04 +0400 | [diff] [blame] | 196 | if (ORIGIN_RELEASE == 'jewel') { |
| 197 | salt.cmdRun(pepperEnv, ADMIN_HOST, 'ceph osd set sortbitwise') |
| 198 | } |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 199 | } |
| 200 | } |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 201 | |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 202 | if (STAGE_UPGRADE_MON.toBoolean() == true) { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 203 | upgrade(pepperEnv, 'mon') |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 204 | } |
| 205 | |
| 206 | if (STAGE_UPGRADE_MGR.toBoolean() == true) { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 207 | upgrade(pepperEnv, 'mgr') |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 208 | } |
| 209 | |
| 210 | if (STAGE_UPGRADE_OSD.toBoolean() == true) { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 211 | upgrade(pepperEnv, 'osd') |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 212 | } |
| 213 | |
| 214 | if (STAGE_UPGRADE_RGW.toBoolean() == true) { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 215 | upgrade(pepperEnv, 'radosgw') |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 216 | } |
| 217 | |
| 218 | if (STAGE_UPGRADE_CLIENT.toBoolean() == true) { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 219 | upgrade(pepperEnv, 'common') |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 220 | } |
| 221 | |
| 222 | // remove cluster flags |
| 223 | if (flags.size() > 0) { |
| 224 | stage('Unset cluster flags') { |
| 225 | for (flag in flags) { |
| 226 | if (!flag.contains('sortbitwise')) { |
| 227 | common.infoMsg('Removing flag ' + flag) |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 228 | salt.cmdRun(pepperEnv, ADMIN_HOST, 'ceph osd unset ' + flag) |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 229 | } |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 230 | } |
Jiri Broulik | 96c867a | 2017-11-07 16:14:10 +0100 | [diff] [blame] | 231 | } |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 232 | } |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 233 | |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 234 | if (STAGE_FINALIZE.toBoolean() == true) { |
| 235 | stage("Finalize ceph version upgrade") { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 236 | salt.cmdRun(pepperEnv, ADMIN_HOST, "ceph osd require-osd-release ${TARGET_RELEASE}") |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 237 | try { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 238 | salt.cmdRun(pepperEnv, ADMIN_HOST, "ceph osd set-require-min-compat-client ${ORIGIN_RELEASE}") |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 239 | } catch (Exception e) { |
| 240 | common.warningMsg(e) |
| 241 | } |
| 242 | try { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 243 | salt.cmdRun(pepperEnv, ADMIN_HOST, "ceph osd crush tunables optimal") |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 244 | } catch (Exception e) { |
| 245 | common.warningMsg(e) |
| 246 | } |
Tomek Jaroszyk | 933011a | 2020-04-07 11:20:31 +0200 | [diff] [blame] | 247 | if (TARGET_RELEASE == 'nautilus' ) { |
| 248 | salt.cmdRun(pepperEnv, ADMIN_HOST, "ceph mon enable-msgr2") |
| 249 | } |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 250 | } |
| 251 | } |
| 252 | |
| 253 | // wait for healthy cluster |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 254 | if (WAIT_FOR_HEALTHY.toBoolean()) { |
| 255 | ceph.waitForHealthy(pepperEnv, ADMIN_HOST, flags) |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 256 | } |
Jiri Broulik | dc87d72 | 2017-11-03 15:43:22 +0100 | [diff] [blame] | 257 | } |
| 258 | } |