add php, net-snmp and rrdtool versions to callback stats (#5153)

This commit is contained in:
Neil Lathwood
2016-12-12 19:03:54 +00:00
committed by Tony Murray
parent 432f6e5276
commit 047c96d454
2 changed files with 5 additions and 0 deletions

View File

@@ -12,6 +12,7 @@ Now onto the bit you're interested in, what is submitted and what we do with tha
#### What is submitted ####
- All data is anonymous.
- Generic statistics are taken from the database, these include things like device total, type and os, port types, speeds and total, total bgp peers. Take a look at the code for full details.
- We record version numbers of php, mysql, net-snmp and rrdtool
- A random UUID is generated on your own install.
- That's it!
- Your IP isn't logged, even via our web service accepting the data. We don't need to know who you are so don't ask.

View File

@@ -20,6 +20,7 @@ if ($enabled == 1) {
$uuid = dbFetchCell("SELECT `value` FROM `callback` WHERE `name` = 'uuid'");
$version = version_info(false);
$queries = array(
'alert_rules' => 'SELECT COUNT(`severity`) AS `total`,`severity` FROM `alert_rules` WHERE `disabled`=0 GROUP BY `severity`',
'alert_templates' => 'SELECT COUNT(`id`) AS `total` FROM `alert_templates`',
@@ -69,6 +70,9 @@ if ($enabled == 1) {
$data = dbFetchRows($query);
$response[$name] = $data;
}
$response['php_version'][] = array('total' => 1, 'version' => $version['php_ver']);
$response['rrdtool_version'][] = array('total' => 1, 'version' => $version['rrdtool_ver']);
$response['netsnmp_version'][] = array('total' => 1, 'version' => $version['netsnmp_ver']);
$output = array(
'uuid' => $uuid,