Clean up some poller debug + added updated version and last git commit

This commit is contained in:
laf
2015-08-24 20:54:19 +00:00
parent 065ad345c6
commit 59de0d1478
4 changed files with 7 additions and 5 deletions

View File

@@ -23,11 +23,11 @@ require 'includes/discovery/functions.inc.php';
$start = utime();
$runtime_stats = array();
// Observium Device Discovery
$options = getopt('h:m:i:n:d::a::q');
if (!isset($options['q'])) {
echo $config['project_name_version']." Discovery\n\n";
echo $config['project_name_version']." Discovery\n";
echo `git log -n 1|grep 'commit '`."\n";
}
if (isset($options['h'])) {

View File

@@ -1633,7 +1633,7 @@ if (isset($config['enable_printers']) && $config['enable_printers']) {
//
// No changes below this line #
//
$config['version'] = '2014.master';
$config['version'] = '2015.master';
$config['project_name_version'] = $config['project_name'].' '.$config['version'];
if (isset($config['rrdgraph_def_text'])) {

View File

@@ -278,7 +278,8 @@ function poll_device($device, $options) {
// echo("$device_end - $device_start; $device_time $device_run");
echo "Polled in $device_time seconds\n";
d_echo('Updating '.$device['hostname'].' - '.print_r($update_array)." \n");
d_echo('Updating '.$device['hostname']."\n");
d_echo($update_array);
$updated = dbUpdate($update_array, 'devices', '`device_id` = ?', array($device['device_id']));
if ($updated) {

View File

@@ -22,7 +22,8 @@ require 'includes/polling/functions.inc.php';
require 'includes/alerts.inc.php';
$poller_start = utime();
echo $config['project_name_version']." Poller\n\n";
echo $config['project_name_version']." Poller\n";
echo `git log -n 1|grep 'commit '`."\n";
$options = getopt('h:m:i:n:r::d::a::');