From ced039efb62b13a1ebaf72c1393510eccac02d2c Mon Sep 17 00:00:00 2001 From: bergware Date: Sat, 9 Nov 2024 19:19:37 +0100 Subject: [PATCH] Dashboard: fix active NTP server count --- emhttp/plugins/dynamix/include/DashboardApps.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/emhttp/plugins/dynamix/include/DashboardApps.php b/emhttp/plugins/dynamix/include/DashboardApps.php index c466acb46..a932ca9d4 100644 --- a/emhttp/plugins/dynamix/include/DashboardApps.php +++ b/emhttp/plugins/dynamix/include/DashboardApps.php @@ -21,7 +21,7 @@ require_once "$docroot/plugins/dynamix.docker.manager/include/DockerClient.php"; require_once "$docroot/plugins/dynamix.vm.manager/include/libvirt_helpers.php"; if (isset($_POST['ntp'])) { - $ntp = exec("ntpq -pn|awk '{if (NR>3 && $2!~/\.(DENY|INIT|RATE|TIME|STEP|DNS[46]?|NTS[46]?)\./) c++} END {print c}'"); + $ntp = exec("ntpq -pn|awk '{if (NR>3 && $2!~/\.(POOL|DENY|INIT|RATE|TIME|STEP|DNS[46]?|NTS[46]?)\./) c++} END {print c}'"); die($ntp ? sprintf(_('Clock synchronized with %s NTP server'.($ntp==1?'':'s')),$ntp) : _('Clock is unsynchronized with no NTP servers')); }