@@ -141,7 +141,7 @@ def handleArguments(argv):
141141
142142# Check cloudstack IDs
143143if DEBUG == 1 :
144- print "Note: Checking CloudStack IDs of provided input.."
144+ print "Note: Checking IDs of provided input.."
145145clusterID = c .checkCloudStackName (
146146 {'csname' : clustername , 'csApiCall' : 'listClusters' })
147147if clusterID == 1 :
@@ -196,7 +196,7 @@ def handleArguments(argv):
196196 print "Warning: We are running in DRYRUN mode."
197197 print
198198 print "This script will: "
199- print " - Set cluster " + clustername + " to unmanage in CloudStack "
199+ print " - Set cluster " + clustername + " to Unmanage "
200200 print " - Turn OFF XenServer poolHA for " + clustername
201201 print " - For any hypervisor it will do this (poolmaster " + poolmaster .name + " first):"
202202 print " - put it to Disabled aka Maintenance in XenServer"
@@ -206,8 +206,8 @@ def handleArguments(argv):
206206 print " - set the hypervisor to Enabled in XenServer"
207207 print " - continues to the next hypervisor"
208208 print " - When the rebooting is done, it enables XenServer poolHA again for " + clustername
209- print " - Finally, it sets the " + clustername + " to Managed again in CloudStack "
210- print " - CloudStack will update its admin according to the new situation"
209+ print " - Finally, it sets the " + clustername + " to Managed again"
210+ print " - Database will be updated according to the new situation"
211211 print "Then the reboot cyclus for " + clustername + " is done!"
212212 print
213213 print "To kick it off, run with the --exec flag."
@@ -240,7 +240,7 @@ def handleArguments(argv):
240240if poolmaster .name not in ignoreHosts :
241241
242242 # BEFORE: Set to Unmanage
243- print "Note: Setting cluster " + clustername + " to Unmanaged in CloudStack "
243+ print "Note: Setting cluster " + clustername + " to Unmanaged"
244244 clusterUpdateReturn = c .updateCluster (
245245 {'clusterid' : clusterID , 'managedstate' : 'Unmanaged' })
246246
@@ -265,7 +265,7 @@ def handleArguments(argv):
265265 sys .exit (1 )
266266
267267 # AFTER: Set to Manage
268- print "Note: Setting cluster " + clustername + " back to Managed in CloudStack "
268+ print "Note: Setting cluster " + clustername + " back to Managed"
269269 clusterUpdateReturn = c .updateCluster (
270270 {'clusterid' : clusterID , 'managedstate' : 'Managed' })
271271
@@ -274,6 +274,9 @@ def handleArguments(argv):
274274 disconnect_all ()
275275 sys .exit (1 )
276276
277+ print "Note: Waiting 30s to allow all hosts connect.."
278+ time .sleep (30 )
279+
277280else :
278281 print "Warning: Skipping " + poolmaster .name + " due to --ignore-hosts setting"
279282
0 commit comments