From bdf279a1b6aa71c776f4b5c8c36ff30cfea53abe Mon Sep 17 00:00:00 2001 From: Erich Eckner Date: Fri, 22 Jun 2018 14:12:29 +0200 Subject: Revert "lib/mysql.php: do not print warning if last ssh_log is less than a minute ago" This reverts commit 857d7d193c454ff18c4c15089bc465178415a5a8. --- lib/mysql.php | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) (limited to 'lib') diff --git a/lib/mysql.php b/lib/mysql.php index 6d575ad..60bfa3a 100644 --- a/lib/mysql.php +++ b/lib/mysql.php @@ -20,18 +20,9 @@ function mysql_run_query($query) { } function show_warning_on_offline_slave() { - $result = mysql_run_query( - "SHOW STATUS LIKE \"Slave_running\"" - ); + $result = mysql_run_query("SHOW STATUS LIKE \"Slave_running\""); if (($result -> num_rows == 0) || ($result -> fetch_assoc() ["Value"] != "ON")) { - $result = mysql_run_query( - "SELECT 1 FROM `ssh_log`" . - " WHERE ADDTIME(`ssh_log`.`date`,\"1:00\")>NOW()" . - " LIMIT 1" - ); - if ($result -> num_rows == 0) { - print "
The replication slave is currently not running. The database might be outdated.
\n"; - } + print "
The replication slave is currently not running. The database might be outdated.
\n"; } } -- cgit v1.2.3-70-g09d2