def logic():
- plc.nodeBootState(host, 'rins')
+ plc.nodeBootState(host, 'reinstall')
node_end_record(host)
def main(hostnames, sitenames):
changed_lessthan(nodehist.last_changed, 1.0) and \
found_within(recent_actions, 'down_notice', 7.0) and \
not found_within(recent_actions, 'online_notice', 0.5):
+ # NOTE: chronicly flapping nodes will not get 'online' notices
+ # since, they are never up long enough to be 'good'.
# NOTE: searching for down_notice proves that the node has
# gone through a 'down' state first, rather than just
# flapping through: good, offline, online, ...
# if a node is offline and doesn't have a PCU, remind the user that they should have one.
- if not nodehist.haspcu and nodehist.status in ['offline', 'down'] and \
- changed_greaterthan(nodehist.last_changed,1.0) and \
- not found_within(recent_actions, 'pcumissing_notice', 7.0):
-
- sitehist.sendMessage('pcumissing_notice', hostname=host)
- print "send message for host %s pcumissing_notice" % host
+ #if not nodehist.haspcu and nodehist.status in ['offline', 'down'] and \
+ # changed_greaterthan(nodehist.last_changed,1.0) and \
+ # not found_within(recent_actions, 'pcumissing_notice', 7.0):
+ #
+ # sitehist.sendMessage('pcumissing_notice', hostname=host)
+ # print "send message for host %s pcumissing_notice" % host
# if it is offline and HAS a PCU, then try to use it.
if nodehist.haspcu and nodehist.status in ['offline', 'down'] and \