From d758bfbecd7097183a5178dc818999371574835a Mon Sep 17 00:00:00 2001 From: H Plato Date: Thu, 6 Jul 2017 18:48:37 -0600 Subject: [PATCH] update uptime regex --- lib/json_server.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/json_server.pl b/lib/json_server.pl index b61badb6b..b41cfb005 100755 --- a/lib/json_server.pl +++ b/lib/json_server.pl @@ -689,7 +689,7 @@ sub json_get { } else { $uptime = `uptime`; } - my ($time,$upt,$users,$load) = $uptime =~ /^(\S+)\s+up\s(.*),\s(\d+)\susers,\s+load\saverages?:\s(.*)/; + my ($time,$upt,$users,$load) = $uptime =~ /(\S+)\s+up\s(.*),\s+(\d+)\susers,\s+load\saverages?:\s(.*)/; $json_data{stats}{time} = $time; $json_data{stats}{uptime} = $upt; $json_data{stats}{users} = $users;