summaryrefslogtreecommitdiffstats
path: root/modules-available/rebootcontrol
diff options
context:
space:
mode:
authorSimon Rettberg2022-05-24 14:10:27 +0200
committerSimon Rettberg2022-05-24 14:10:27 +0200
commit4e33296deef9f4d51d3ce6670aaa6e8ee2bb8172 (patch)
treec4acd1a8e016e7187472a7ab0c92a252da8785e2 /modules-available/rebootcontrol
parent[rebootcontrol] Change WakeOnLan task call struct to new format (diff)
downloadslx-admin-4e33296deef9f4d51d3ce6670aaa6e8ee2bb8172.tar.gz
slx-admin-4e33296deef9f4d51d3ce6670aaa6e8ee2bb8172.tar.xz
slx-admin-4e33296deef9f4d51d3ce6670aaa6e8ee2bb8172.zip
[rebootcontrol] Run reachability checks a little more often
Diffstat (limited to 'modules-available/rebootcontrol')
-rw-r--r--modules-available/rebootcontrol/hooks/cron.inc.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules-available/rebootcontrol/hooks/cron.inc.php b/modules-available/rebootcontrol/hooks/cron.inc.php
index c10e8626..0d7ff6ab 100644
--- a/modules-available/rebootcontrol/hooks/cron.inc.php
+++ b/modules-available/rebootcontrol/hooks/cron.inc.php
@@ -16,7 +16,7 @@ Scheduler::cron();
/*
* Client reachability test -- can be disabled
*/
-if (mt_rand(1, 2) !== 1 || Property::get(RebootControl::KEY_AUTOSCAN_DISABLED))
+if (Property::get(RebootControl::KEY_AUTOSCAN_DISABLED))
return;
class Stuff
@@ -140,7 +140,7 @@ function resultToTime($result)
$next = 86400 * 7; // a week
} else {
// Test finished, reachable
- $next = 86400 * 30; // a month
+ $next = 86400 * 14; // two weeks
}
return time() + round($next * mt_rand(90, 133) / 100);
}