X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=reboot.py;fp=reboot.py;h=ba641c4724c7cea4f6670f2ef883a42949a1ef49;hb=a048ec7065ad812c5dfbe23efa8a4d67b04724af;hp=34b9b00ded6f6492e850b4f63dd147dfd3c4edd3;hpb=41a2478ff37888bcafc2ef18d85fb83438c9394f;p=monitor.git diff --git a/reboot.py b/reboot.py index 34b9b00..ba641c4 100755 --- a/reboot.py +++ b/reboot.py @@ -296,11 +296,12 @@ class IPAL(PCUControl): try: # TODO: make sleep backoff, before stopping. - time.sleep(4) + time.sleep(8) ret = s.recv(count, socket.MSG_DONTWAIT) except socket.error, e: if e[0] == errno.EAGAIN: - raise Exception(e[1]) + #raise Exception(e[1]) + raise ExceptionNotFound(e[1]) else: # TODO: not other exceptions. raise Exception(e) @@ -321,6 +322,8 @@ class IPAL(PCUControl): if e[0] == errno.ECONNREFUSED: # cannot connect to remote host raise Exception(e[1]) + elif e[0] == errno.ETIMEDOUT: + raise ExceptionTimeout(e[1]) else: # TODO: what other conditions are there? raise Exception(e)