This is a better module for dealing with SSH logins using 'expect' like
[monitor.git] / reboot.py
index fb30ace..49db556 100755 (executable)
--- a/reboot.py
+++ b/reboot.py
@@ -1096,9 +1096,13 @@ def reboot_test(nodename, values, continue_probe, verbose, dryrun):
 
                # iLO
                elif continue_probe and values['model'].find("HP iLO") >= 0:
-                       hpilo = HPiLO(values, verbose, ['22'])
-                       rb_ret = hpilo.reboot(0, dryrun)
-                       if rb_ret != 0:
+                       try:
+                               hpilo = HPiLO(values, verbose, ['22'])
+                               rb_ret = hpilo.reboot(0, dryrun)
+                               if rb_ret != 0:
+                                       hpilo = HPiLOHttps(values, verbose, ['443'])
+                                       rb_ret = hpilo.reboot(0, dryrun)
+                       except:
                                hpilo = HPiLOHttps(values, verbose, ['443'])
                                rb_ret = hpilo.reboot(0, dryrun)