diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2006-12-09 01:35:25 +0000 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2006-12-09 01:35:25 +0000 |
commit | e4819259c8490b3f4d9fd0e50519a5159ea8e520 (patch) | |
tree | 96c169a8f71f001b61ff05c1ff75e0555a60f492 /packages/tinydns | |
parent | 59d65a4615cda970ba0ce08368deaab537b0e59e (diff) | |
download | pfsense-packages-e4819259c8490b3f4d9fd0e50519a5159ea8e520.tar.gz pfsense-packages-e4819259c8490b3f4d9fd0e50519a5159ea8e520.tar.bz2 pfsense-packages-e4819259c8490b3f4d9fd0e50519a5159ea8e520.zip |
Correct failover logic
Diffstat (limited to 'packages/tinydns')
-rw-r--r-- | packages/tinydns/tinydns.inc | 4 | ||||
-rw-r--r-- | packages/tinydns/tinydns_status.php | 1 |
2 files changed, 3 insertions, 2 deletions
diff --git a/packages/tinydns/tinydns.inc b/packages/tinydns/tinydns.inc index 4dc131e8..10a05670 100644 --- a/packages/tinydns/tinydns.inc +++ b/packages/tinydns/tinydns.inc @@ -164,7 +164,7 @@ function tinydns_get_record_status($record, $pingthreshold = "", $wanpingthresho global $g, $config; if(file_exists("/var/db/pingstatus/{$record}")) { $status = file_get_contents("/var/db/pingstatus/{$record}"); - if($status == "DOWN") + if(stristr($status,"DOWN")) return false; } if($pingthreshold) { @@ -189,7 +189,7 @@ function tinydns_get_backup_record($record) { if(!$domain['row']) return $record; foreach($domain['row'] as $row) { - $status = tinydns_get_record_status($record); + $status = tinydns_get_record_status($row['failoverip']); if($status) return $row['failoverip']; } diff --git a/packages/tinydns/tinydns_status.php b/packages/tinydns/tinydns_status.php index 007793a8..13ac4e8c 100644 --- a/packages/tinydns/tinydns_status.php +++ b/packages/tinydns/tinydns_status.php @@ -96,5 +96,6 @@ foreach($pingdir as $ping) { </table> </div> <?php include("fend.inc"); ?> +<meta http-equiv="refresh" content="60;url=<?php print $_SERVER['SCRIPT_NAME']; ?>"> </body> </html> |