mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
git-svn-id: http://www.observium.org/svn/observer/trunk@241 61d68cd4-352d-0410-923a-c4978735b2b8
17 lines
297 B
PHP
17 lines
297 B
PHP
<?php
|
|
|
|
if($service[service_port]) { $port = $service[service_port]; } else { $port = '23'; }
|
|
|
|
|
|
$check = `scripts/services/check_tcp -H $service[hostname] -p $port`;
|
|
|
|
list($check, $time) = split("\|", $check);
|
|
|
|
if(strstr($check, "TCP OK - ")) {
|
|
$status = '1';
|
|
} else {
|
|
$status = '0';
|
|
}
|
|
|
|
?>
|