';
echo "
Apps » ";
unset($sep);
$link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
+ 'tab' => 'apps',
];
$apps = \LibreNMS\Util\ObjectCache::applications()->flatten();
diff --git a/includes/html/pages/apps/proxmox/vm.inc.php b/includes/html/pages/apps/proxmox/vm.inc.php
index 27a7b9316f..2e5d665c04 100644
--- a/includes/html/pages/apps/proxmox/vm.inc.php
+++ b/includes/html/pages/apps/proxmox/vm.inc.php
@@ -3,7 +3,7 @@
$vm = proxmox_vm_info(var_get('vmid'), var_get('instance'));
$graphs = [
- 'proxmox_traffic' => 'Traffic',
+ 'proxmox_traffic' => 'Traffic',
];
foreach ($vm['ports'] as $port) {
diff --git a/includes/html/pages/bill/actions.inc.php b/includes/html/pages/bill/actions.inc.php
index 087104abe0..c1cdbba95d 100644
--- a/includes/html/pages/bill/actions.inc.php
+++ b/includes/html/pages/bill/actions.inc.php
@@ -79,15 +79,15 @@ if ($_POST['action'] == 'update_bill') {
// NOTE: casting to string for mysqli bug (fixed by mysqlnd)
if (dbUpdate(
[
- 'bill_name' => $_POST['bill_name'],
- 'bill_day' => $_POST['bill_day'],
- 'bill_quota' => (string) $bill_quota,
- 'bill_cdr' => (string) $bill_cdr,
- 'bill_type' => $_POST['bill_type'],
- 'dir_95th' => $_POST['dir_95th'],
+ 'bill_name' => $_POST['bill_name'],
+ 'bill_day' => $_POST['bill_day'],
+ 'bill_quota' => (string) $bill_quota,
+ 'bill_cdr' => (string) $bill_cdr,
+ 'bill_type' => $_POST['bill_type'],
+ 'dir_95th' => $_POST['dir_95th'],
'bill_custid' => $_POST['bill_custid'],
- 'bill_ref' => $_POST['bill_ref'],
- 'bill_notes' => $_POST['bill_notes'],
+ 'bill_ref' => $_POST['bill_ref'],
+ 'bill_notes' => $_POST['bill_notes'],
],
'bills',
'`bill_id` = ?',
diff --git a/includes/html/pages/device/apps.inc.php b/includes/html/pages/device/apps.inc.php
index 51191beab0..cb9e2e8153 100644
--- a/includes/html/pages/device/apps.inc.php
+++ b/includes/html/pages/device/apps.inc.php
@@ -10,9 +10,9 @@ echo "
Apps » ";
$sep = '';
$link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
+ 'tab' => 'apps',
];
$apps = DeviceCache::getPrimary()->applications
diff --git a/includes/html/pages/device/apps/apache.inc.php b/includes/html/pages/device/apps/apache.inc.php
index b9c934f35e..955f19b219 100644
--- a/includes/html/pages/device/apps/apache.inc.php
+++ b/includes/html/pages/device/apps/apache.inc.php
@@ -1,9 +1,9 @@
'Traffic',
- 'apache_hits' => 'Hits',
- 'apache_cpu' => 'CPU Utilisation',
+ 'apache_bits' => 'Traffic',
+ 'apache_hits' => 'Hits',
+ 'apache_cpu' => 'CPU Utilisation',
'apache_scoreboard' => 'Scoreboard Statistics',
];
diff --git a/includes/html/pages/device/apps/backupninja.inc.php b/includes/html/pages/device/apps/backupninja.inc.php
index 04f69b22e9..ad7e6fbf44 100644
--- a/includes/html/pages/device/apps/backupninja.inc.php
+++ b/includes/html/pages/device/apps/backupninja.inc.php
@@ -1,7 +1,7 @@
'backupninja backups',
+ 'backupninja_backupninja' => 'backupninja backups',
];
foreach ($graphs as $key => $text) {
$graph_type = $key;
diff --git a/includes/html/pages/device/apps/cape.inc.php b/includes/html/pages/device/apps/cape.inc.php
index f4ba47d6d6..6b5dddc212 100644
--- a/includes/html/pages/device/apps/cape.inc.php
+++ b/includes/html/pages/device/apps/cape.inc.php
@@ -27,10 +27,10 @@ if (sizeof($packages) > 0) {
print_optionbar_start();
if (isset($vars['package'])) {
- echo generate_link('General', $link_array, ['app'=>'cape', 'stddev'=>$vars['stddev'], 'bypkg'=>$vars['bypkg'], 'bytimeslot'=>$vars['bytimeslot'], 'statsavg'=>$vars['statsavg'], 'runstats'=>$vars['runstats']]);
+ echo generate_link('General', $link_array, ['app' => 'cape', 'stddev' => $vars['stddev'], 'bypkg' => $vars['bypkg'], 'bytimeslot' => $vars['bytimeslot'], 'statsavg' => $vars['statsavg'], 'runstats' => $vars['runstats']]);
} else {
$label = '';
- echo generate_link($label, $link_array, ['app'=>'cape', 'stddev'=>$vars['stddev'], 'bypkg'=>$vars['bypkg'], 'bytimeslot'=>$vars['bytimeslot'], 'statsavg'=>$vars['statsavg'], 'runstats'=>$vars['runstats']]);
+ echo generate_link($label, $link_array, ['app' => 'cape', 'stddev' => $vars['stddev'], 'bypkg' => $vars['bypkg'], 'bytimeslot' => $vars['bytimeslot'], 'statsavg' => $vars['statsavg'], 'runstats' => $vars['runstats']]);
}
echo ' |
Packages: ';
@@ -50,7 +50,7 @@ if (sizeof($packages) > 0) {
$append = ', ';
}
- echo generate_link($label, $link_array, ['app'=>'cape', 'stddev'=>$vars['stddev'], 'bypkg'=>$vars['bypkg'], 'bytimeslot'=>$vars['bytimeslot'], 'package'=>$package, 'statsavg'=>$vars['statsavg'], 'runstats'=>$vars['runstats']]) . $append;
+ echo generate_link($label, $link_array, ['app' => 'cape', 'stddev' => $vars['stddev'], 'bypkg' => $vars['bypkg'], 'bytimeslot' => $vars['bytimeslot'], 'package' => $package, 'statsavg' => $vars['statsavg'], 'runstats' => $vars['runstats']]) . $append;
}
echo "
\n";
@@ -58,12 +58,12 @@ if (sizeof($packages) > 0) {
echo '
Run Stats Averages: ';
if ($vars['statsavg'] == 'on') {
$label = '';
- echo generate_link($label, $link_array, ['app'=>'cape', 'bytimeslot'=>$vars['bytimeslot'], 'bypkg'=>$vars['bypkg'], 'stddev'=>$vars['stddev'], 'package'=>$vars['package'], 'statsavg'=>'on', 'runstats'=>$vars['runstats']]) . ', ' .
- generate_link('Off', $link_array, ['app'=>'cape', 'bytimeslot'=>$vars['bytimeslot'], 'bypkg'=>$vars['bypkg'], 'stddev'=>$vars['stddev'], 'package'=>$vars['package'], 'statsavg'=>'off', 'runstats'=>$vars['runstats']]);
+ echo generate_link($label, $link_array, ['app' => 'cape', 'bytimeslot' => $vars['bytimeslot'], 'bypkg' => $vars['bypkg'], 'stddev' => $vars['stddev'], 'package' => $vars['package'], 'statsavg' => 'on', 'runstats' => $vars['runstats']]) . ', ' .
+ generate_link('Off', $link_array, ['app' => 'cape', 'bytimeslot' => $vars['bytimeslot'], 'bypkg' => $vars['bypkg'], 'stddev' => $vars['stddev'], 'package' => $vars['package'], 'statsavg' => 'off', 'runstats' => $vars['runstats']]);
} else {
$label = '';
- echo generate_link('On', $link_array, ['app'=>'cape', 'bytimeslot'=>$vars['bytimeslot'], 'bypkg'=>$vars['bypkg'], 'stddev'=>$vars['stddev'], 'package'=>$vars['package'], 'statsavg'=>'on', 'runstats'=>$vars['runstats']]) . ', ' .
- generate_link($label, $link_array, ['app'=>'cape', 'bytimeslot'=>$vars['bytimeslot'], 'bypkg'=>$vars['bypkg'], 'stddev'=>$vars['stddev'], 'package'=>$vars['package'], 'statsavg'=>'off', 'runstats'=>$vars['runstats']]);
+ echo generate_link('On', $link_array, ['app' => 'cape', 'bytimeslot' => $vars['bytimeslot'], 'bypkg' => $vars['bypkg'], 'stddev' => $vars['stddev'], 'package' => $vars['package'], 'statsavg' => 'on', 'runstats' => $vars['runstats']]) . ', ' .
+ generate_link($label, $link_array, ['app' => 'cape', 'bytimeslot' => $vars['bytimeslot'], 'bypkg' => $vars['bypkg'], 'stddev' => $vars['stddev'], 'package' => $vars['package'], 'statsavg' => 'off', 'runstats' => $vars['runstats']]);
}
echo ' | ';
@@ -71,12 +71,12 @@ if (sizeof($packages) > 0) {
echo '
By Time Slot: ';
if ($vars['bytimeslot'] == 'on') {
$label = '';
- echo generate_link($label, $link_array, ['app'=>'cape', 'bytimeslot'=>'on', 'bypkg'=>$vars['bypkg'], 'stddev'=>$vars['stddev'], 'package'=>$vars['package'], 'statsavg'=>$vars['statsavg'], 'runstats'=>$vars['runstats']]) . ', ' .
- generate_link('Off', $link_array, ['app'=>'cape', 'bytimeslot'=>'off', 'bypkg'=>$vars['bypkg'], 'stddev'=>$vars['stddev'], 'package'=>$vars['package'], 'statsavg'=>$vars['statsavg'], 'runstats'=>$vars['runstats']]);
+ echo generate_link($label, $link_array, ['app' => 'cape', 'bytimeslot' => 'on', 'bypkg' => $vars['bypkg'], 'stddev' => $vars['stddev'], 'package' => $vars['package'], 'statsavg' => $vars['statsavg'], 'runstats' => $vars['runstats']]) . ', ' .
+ generate_link('Off', $link_array, ['app' => 'cape', 'bytimeslot' => 'off', 'bypkg' => $vars['bypkg'], 'stddev' => $vars['stddev'], 'package' => $vars['package'], 'statsavg' => $vars['statsavg'], 'runstats' => $vars['runstats']]);
} else {
$label = '';
- echo generate_link('On', $link_array, ['app'=>'cape', 'bytimeslot'=>'on', 'bypkg'=>$vars['bypkg'], 'stddev'=>$vars['stddev'], 'package'=>$vars['package'], 'statsavg'=>$vars['statsavg'], 'runstats'=>$vars['runstats']]) . ', ' .
- generate_link($label, $link_array, ['app'=>'cape', 'bytimeslot'=>'off', 'bypkg'=>$vars['bypkg'], 'stddev'=>$vars['stddev'], 'package'=>$vars['package'], 'statsavg'=>$vars['statsavg'], 'runstats'=>$vars['runstats']]);
+ echo generate_link('On', $link_array, ['app' => 'cape', 'bytimeslot' => 'on', 'bypkg' => $vars['bypkg'], 'stddev' => $vars['stddev'], 'package' => $vars['package'], 'statsavg' => $vars['statsavg'], 'runstats' => $vars['runstats']]) . ', ' .
+ generate_link($label, $link_array, ['app' => 'cape', 'bytimeslot' => 'off', 'bypkg' => $vars['bypkg'], 'stddev' => $vars['stddev'], 'package' => $vars['package'], 'statsavg' => $vars['statsavg'], 'runstats' => $vars['runstats']]);
}
if (! isset($vars['package'])) {
@@ -84,12 +84,12 @@ if (sizeof($packages) > 0) {
echo '
By Package: ';
if ($vars['bypkg'] == 'on') {
$label = '';
- echo generate_link($label, $link_array, ['app'=>'cape', 'bypkg'=>'on', 'bytimeslot'=>$vars['bytimeslot'], 'stddev'=>$vars['stddev'], 'package'=>$vars['package'], 'statsavg'=>$vars['statsavg'], 'runstats'=>$vars['runstats']]) . ', ' .
- generate_link('Off', $link_array, ['app'=>'cape', 'bypkg'=>'off', 'bytimeslot'=>$vars['bytimeslot'], 'stddev'=>$vars['stddev'], 'package'=>$vars['package'], 'statsavg'=>$vars['statsavg'], 'runstats'=>$vars['runstats']]);
+ echo generate_link($label, $link_array, ['app' => 'cape', 'bypkg' => 'on', 'bytimeslot' => $vars['bytimeslot'], 'stddev' => $vars['stddev'], 'package' => $vars['package'], 'statsavg' => $vars['statsavg'], 'runstats' => $vars['runstats']]) . ', ' .
+ generate_link('Off', $link_array, ['app' => 'cape', 'bypkg' => 'off', 'bytimeslot' => $vars['bytimeslot'], 'stddev' => $vars['stddev'], 'package' => $vars['package'], 'statsavg' => $vars['statsavg'], 'runstats' => $vars['runstats']]);
} else {
$label = '';
- echo generate_link('On', $link_array, ['app'=>'cape', 'bypkg'=>'on', 'bytimeslot'=>$vars['bytimeslot'], 'stddev'=>$vars['stddev'], 'package'=>$vars['package'], 'statsavg'=>$vars['statsavg'], 'runstats'=>$vars['runstats']]) . ', ' .
- generate_link($label, $link_array, ['app'=>'cape', 'bypkg'=>'off', 'bytimeslot'=>$vars['bytimeslot'], 'stddev'=>$vars['stddev'], 'package'=>$vars['package'], 'statsavg'=>$vars['statsavg'], 'runstats'=>$vars['runstats']]);
+ echo generate_link('On', $link_array, ['app' => 'cape', 'bypkg' => 'on', 'bytimeslot' => $vars['bytimeslot'], 'stddev' => $vars['stddev'], 'package' => $vars['package'], 'statsavg' => $vars['statsavg'], 'runstats' => $vars['runstats']]) . ', ' .
+ generate_link($label, $link_array, ['app' => 'cape', 'bypkg' => 'off', 'bytimeslot' => $vars['bytimeslot'], 'stddev' => $vars['stddev'], 'package' => $vars['package'], 'statsavg' => $vars['statsavg'], 'runstats' => $vars['runstats']]);
}
}
@@ -98,12 +98,12 @@ if (sizeof($packages) > 0) {
echo '
Standard Deviation: ';
if ($vars['stddev'] == 'on') {
$label = '';
- echo generate_link($label, $link_array, ['app'=>'cape', 'stddev'=>'on', 'bypkg'=>$vars['bypkg'], 'bytimeslot'=>$vars['bytimeslot'], 'package'=>$vars['package'], 'statsavg'=>$vars['statsavg'], 'runstats'=>$vars['runstats']]) . ', ' .
- generate_link('Off', $link_array, ['app'=>'cape', 'stddev'=>'off', 'bypkg'=>$vars['bypkg'], 'bytimeslot'=>$vars['bytimeslot'], 'package'=>$vars['package'], 'statsavg'=>$vars['statsavg'], 'runstats'=>$vars['runstats']]);
+ echo generate_link($label, $link_array, ['app' => 'cape', 'stddev' => 'on', 'bypkg' => $vars['bypkg'], 'bytimeslot' => $vars['bytimeslot'], 'package' => $vars['package'], 'statsavg' => $vars['statsavg'], 'runstats' => $vars['runstats']]) . ', ' .
+ generate_link('Off', $link_array, ['app' => 'cape', 'stddev' => 'off', 'bypkg' => $vars['bypkg'], 'bytimeslot' => $vars['bytimeslot'], 'package' => $vars['package'], 'statsavg' => $vars['statsavg'], 'runstats' => $vars['runstats']]);
} else {
$label = '';
- echo generate_link('On', $link_array, ['app'=>'cape', 'stddev'=>'on', 'bypkg'=>$vars['bypkg'], 'bytimeslot'=>$vars['bytimeslot'], 'package'=>$vars['package'], 'statsavg'=>$vars['statsavg'], 'runstats'=>$vars['runstats']]) . ', ' .
- generate_link($label, $link_array, ['app'=>'cape', 'stddev'=>'off', 'bypkg'=>$vars['bypkg'], 'bytimeslot'=>$vars['bytimeslot'], 'package'=>$vars['package'], 'statsavg'=>$vars['statsavg'], 'runstats'=>$vars['runstats']]);
+ echo generate_link('On', $link_array, ['app' => 'cape', 'stddev' => 'on', 'bypkg' => $vars['bypkg'], 'bytimeslot' => $vars['bytimeslot'], 'package' => $vars['package'], 'statsavg' => $vars['statsavg'], 'runstats' => $vars['runstats']]) . ', ' .
+ generate_link($label, $link_array, ['app' => 'cape', 'stddev' => 'off', 'bypkg' => $vars['bypkg'], 'bytimeslot' => $vars['bytimeslot'], 'package' => $vars['package'], 'statsavg' => $vars['statsavg'], 'runstats' => $vars['runstats']]);
}
if (! isset($vars['package'])) {
@@ -111,12 +111,12 @@ if (sizeof($packages) > 0) {
echo '
Run Statuses Averages: ';
if ($vars['runstats'] == 'on') {
$label = '';
- echo generate_link($label, $link_array, ['app'=>'cape', 'bypkg'=>$vars['bypkg'], 'bytimeslot'=>$vars['bytimeslot'], 'stddev'=>$vars['stddev'], 'package'=>$vars['package'], 'statsavg'=>$vars['statsavg'], 'runstats'=>'on']) . ', ' .
- generate_link('Off', $link_array, ['app'=>'cape', 'bypkg'=>$vars['bypkg'], 'bytimeslot'=>$vars['bytimeslot'], 'stddev'=>$vars['stddev'], 'package'=>$vars['package'], 'statsavg'=>$vars['statsavg'], 'runstats'=>'off']);
+ echo generate_link($label, $link_array, ['app' => 'cape', 'bypkg' => $vars['bypkg'], 'bytimeslot' => $vars['bytimeslot'], 'stddev' => $vars['stddev'], 'package' => $vars['package'], 'statsavg' => $vars['statsavg'], 'runstats' => 'on']) . ', ' .
+ generate_link('Off', $link_array, ['app' => 'cape', 'bypkg' => $vars['bypkg'], 'bytimeslot' => $vars['bytimeslot'], 'stddev' => $vars['stddev'], 'package' => $vars['package'], 'statsavg' => $vars['statsavg'], 'runstats' => 'off']);
} else {
$label = '';
- echo generate_link('On', $link_array, ['app'=>'cape', 'bypkg'=>$vars['bypkg'], 'bytimeslot'=>$vars['bytimeslot'], 'stddev'=>$vars['stddev'], 'package'=>$vars['package'], 'statsavg'=>$vars['statsavg'], 'runstats'=>'on']) . ', ' .
- generate_link($label, $link_array, ['app'=>'cape', 'bypkg'=>$vars['bypkg'], 'bytimeslot'=>$vars['bytimeslot'], 'stddev'=>$vars['stddev'], 'package'=>$vars['package'], 'statsavg'=>$vars['statsavg'], 'runstats'=>'off']);
+ echo generate_link('On', $link_array, ['app' => 'cape', 'bypkg' => $vars['bypkg'], 'bytimeslot' => $vars['bytimeslot'], 'stddev' => $vars['stddev'], 'package' => $vars['package'], 'statsavg' => $vars['statsavg'], 'runstats' => 'on']) . ', ' .
+ generate_link($label, $link_array, ['app' => 'cape', 'bypkg' => $vars['bypkg'], 'bytimeslot' => $vars['bytimeslot'], 'stddev' => $vars['stddev'], 'package' => $vars['package'], 'statsavg' => $vars['statsavg'], 'runstats' => 'off']);
}
}
diff --git a/includes/html/pages/device/apps/ceph.inc.php b/includes/html/pages/device/apps/ceph.inc.php
index ba8fac3eaf..27a3508e10 100644
--- a/includes/html/pages/device/apps/ceph.inc.php
+++ b/includes/html/pages/device/apps/ceph.inc.php
@@ -1,9 +1,9 @@
'Pool stats',
- 'ceph_osdperf' => 'OSD Performance',
- 'ceph_df' => 'Usage',
+ 'ceph_poolstats' => 'Pool stats',
+ 'ceph_osdperf' => 'OSD Performance',
+ 'ceph_df' => 'Usage',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/certificate.inc.php b/includes/html/pages/device/apps/certificate.inc.php
index 07a93b80a0..0625fd22f0 100644
--- a/includes/html/pages/device/apps/certificate.inc.php
+++ b/includes/html/pages/device/apps/certificate.inc.php
@@ -5,10 +5,10 @@ $domain_list = Rrd::getRrdApplicationArrays($device, $app['app_id'], 'certificat
print_optionbar_start();
$link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
- 'app' => 'certificate',
+ 'tab' => 'apps',
+ 'app' => 'certificate',
];
$cert_name_list = [];
@@ -28,7 +28,7 @@ printf('%s | certificates: %s', generate_link('All Certificates', $link_array),
print_optionbar_end();
$graphs = [
- 'certificate_age' => 'Age',
+ 'certificate_age' => 'Age',
'certificate_remaining_days' => 'Remaining days',
];
diff --git a/includes/html/pages/device/apps/chronyd.inc.php b/includes/html/pages/device/apps/chronyd.inc.php
index 4c1510ee04..acb07a83ce 100644
--- a/includes/html/pages/device/apps/chronyd.inc.php
+++ b/includes/html/pages/device/apps/chronyd.inc.php
@@ -1,10 +1,10 @@
'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
- 'app' => 'chronyd',
+ 'tab' => 'apps',
+ 'app' => 'chronyd',
];
print_optionbar_start();
@@ -36,9 +36,9 @@ if (! isset($vars['source'])) {
];
} else {
$graphs = [
- 'chronyd_source_sampling' => 'Clock sampling offsets',
- 'chronyd_source_frequency' => 'Clock residual frequency',
- 'chronyd_source_polling' => 'Polling',
+ 'chronyd_source_sampling' => 'Clock sampling offsets',
+ 'chronyd_source_frequency' => 'Clock residual frequency',
+ 'chronyd_source_polling' => 'Polling',
];
}
diff --git a/includes/html/pages/device/apps/dhcp-stats.inc.php b/includes/html/pages/device/apps/dhcp-stats.inc.php
index f9f7023e69..493f071a55 100644
--- a/includes/html/pages/device/apps/dhcp-stats.inc.php
+++ b/includes/html/pages/device/apps/dhcp-stats.inc.php
@@ -4,10 +4,10 @@ $graphs = [
'dhcp-stats_stats' => 'Stats',
'dhcp-stats_pools_percent' => 'Pools Percent',
'dhcp-stats_pools_current' => 'Pools Current',
- 'dhcp-stats_pools_max' => 'Pools Max',
+ 'dhcp-stats_pools_max' => 'Pools Max',
'dhcp-stats_networks_percent' => 'Networks Percent',
'dhcp-stats_networks_current' => 'Networks Current',
- 'dhcp-stats_networks_max' => 'Networks Max',
+ 'dhcp-stats_networks_max' => 'Networks Max',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/drbd.inc.php b/includes/html/pages/device/apps/drbd.inc.php
index 3c52dccb20..bf01a054cb 100644
--- a/includes/html/pages/device/apps/drbd.inc.php
+++ b/includes/html/pages/device/apps/drbd.inc.php
@@ -4,9 +4,9 @@ echo '
' . $app['app_instance'] . '
';
$graphs = [
'drbd_network_bits' => 'Network Traffic',
- 'drbd_disk_bits' => 'Disk Traffic',
- 'drbd_unsynced' => 'Unsynced Data',
- 'drbd_queue' => 'Queues',
+ 'drbd_disk_bits' => 'Disk Traffic',
+ 'drbd_unsynced' => 'Unsynced Data',
+ 'drbd_queue' => 'Queues',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/freeradius.inc.php b/includes/html/pages/device/apps/freeradius.inc.php
index 7613aed491..bce5b6aeae 100644
--- a/includes/html/pages/device/apps/freeradius.inc.php
+++ b/includes/html/pages/device/apps/freeradius.inc.php
@@ -1,13 +1,13 @@
'FreeRADIUS - Access',
- 'freeradius_auth' => 'FreeRADIUS - Auth',
- 'freeradius_acct' => 'FreeRADIUS - Acct',
+ 'freeradius_access' => 'FreeRADIUS - Access',
+ 'freeradius_auth' => 'FreeRADIUS - Auth',
+ 'freeradius_acct' => 'FreeRADIUS - Acct',
'freeradius_proxy_access' => 'FreeRADIUS - Proxy Access',
- 'freeradius_proxy_auth' => 'FreeRADIUS - Proxy Auth',
- 'freeradius_proxy_acct' => 'FreeRADIUS - Proxy Acct',
- 'freeradius_queue' => 'FreeRADIUS - Queue',
+ 'freeradius_proxy_auth' => 'FreeRADIUS - Proxy Auth',
+ 'freeradius_proxy_acct' => 'FreeRADIUS - Proxy Acct',
+ 'freeradius_queue' => 'FreeRADIUS - Queue',
];
foreach ($graphs as $key => $text) {
$graph_type = $key;
diff --git a/includes/html/pages/device/apps/hv-monitor.inc.php b/includes/html/pages/device/apps/hv-monitor.inc.php
index 3ebbc2c0e5..f16f388f24 100644
--- a/includes/html/pages/device/apps/hv-monitor.inc.php
+++ b/includes/html/pages/device/apps/hv-monitor.inc.php
@@ -3,10 +3,10 @@
use App\Models\Port;
$link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
- 'app' => 'hv-monitor',
+ 'tab' => 'apps',
+ 'app' => 'hv-monitor',
];
print_optionbar_start();
@@ -25,7 +25,7 @@ foreach ($app->data['VMs'] as $vm) {
$label = '';
}
- $vm_links[] = generate_link($label, $link_array, ['vm'=>$vm]);
+ $vm_links[] = generate_link($label, $link_array, ['vm' => $vm]);
}
echo implode(', ', $vm_links);
@@ -39,22 +39,22 @@ echo '
Pages: ';
if ($vars['vmpage'] == 'general') {
$page_links[] = '';
} else {
- $page_links[] = generate_link('General', $link_array, ['vm' => $vars['vm'], 'vmpage'=>'general']);
+ $page_links[] = generate_link('General', $link_array, ['vm' => $vars['vm'], 'vmpage' => 'general']);
}
if ($vars['vmpage'] == 'disk') {
$page_links[] = '';
} else {
- $page_links[] = generate_link('Disk', $link_array, ['vm' => $vars['vm'], 'vmpage'=>'disk']);
+ $page_links[] = generate_link('Disk', $link_array, ['vm' => $vars['vm'], 'vmpage' => 'disk']);
}
if ($vars['vmpage'] == 'network') {
$page_links[] = '';
} else {
- $page_links[] = generate_link('Network', $link_array, ['vm' => $vars['vm'], 'vmpage'=>'network']);
+ $page_links[] = generate_link('Network', $link_array, ['vm' => $vars['vm'], 'vmpage' => 'network']);
}
if ($vars['vmpage'] == 'Snapshots') {
$page_links[] = '';
} else {
- $page_links[] = generate_link('Snapshots', $link_array, ['vm' => $vars['vm'], 'vmpage'=>'snapshots']);
+ $page_links[] = generate_link('Snapshots', $link_array, ['vm' => $vars['vm'], 'vmpage' => 'snapshots']);
}
echo implode(', ', $page_links);
@@ -70,7 +70,7 @@ if (isset($vars['vm'])) {
if ($vars['vmdisk'] == $disk) {
$disk_links[] = $label;
} else {
- $disk_links[] = generate_link($label, $link_array, ['vm' => $vars['vm'], 'vmdisk'=>$disk]);
+ $disk_links[] = generate_link($label, $link_array, ['vm' => $vars['vm'], 'vmdisk' => $disk]);
}
}
echo implode(', ', $disk_links);
@@ -83,7 +83,7 @@ if (isset($vars['vm'])) {
if ($vars['vmif'] == $vmif) {
$if_links[] = '';
} else {
- $if_links[] = generate_link($label, $link_array, ['vm' => $vars['vm'], 'vmif'=>$vmif]);
+ $if_links[] = generate_link($label, $link_array, ['vm' => $vars['vm'], 'vmif' => $vmif]);
}
}
echo implode(', ', $if_links);
@@ -97,7 +97,7 @@ if (isset($vars['vmif']) and isset($vars['vm'])) {
'
MAC: ' . $mac;
if (isset($port) && isset($mac) && $mac != '') {
echo ' (' .
- generate_device_link(['device_id'=>$port->device_id]) .
+ generate_device_link(['device_id' => $port->device_id]) .
', ' .
generate_port_link([
'label' => $port->label,
@@ -150,10 +150,10 @@ if (isset($vars['vmif']) and isset($vars['vm'])) {
print_optionbar_end();
$link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
- 'app' => 'hv-monitor',
+ 'tab' => 'apps',
+ 'app' => 'hv-monitor',
];
$graphs = [];
diff --git a/includes/html/pages/device/apps/icecast.inc.php b/includes/html/pages/device/apps/icecast.inc.php
index aad9d4209a..fd0a2331fa 100644
--- a/includes/html/pages/device/apps/icecast.inc.php
+++ b/includes/html/pages/device/apps/icecast.inc.php
@@ -1,8 +1,8 @@
'CPU Load',
- 'icecast_memoryusage' => 'Used Memory',
+ 'icecast_cpuload' => 'CPU Load',
+ 'icecast_memoryusage' => 'Used Memory',
'icecast_openfiles' => 'Open files',
];
diff --git a/includes/html/pages/device/apps/logsize.inc.php b/includes/html/pages/device/apps/logsize.inc.php
index bfa43f0cec..40cdfe2cb9 100644
--- a/includes/html/pages/device/apps/logsize.inc.php
+++ b/includes/html/pages/device/apps/logsize.inc.php
@@ -1,10 +1,10 @@
'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
- 'app' => 'logsize',
+ 'tab' => 'apps',
+ 'app' => 'logsize',
];
$no_minus_d = $app->data['no_minus_d'] ?? false;
@@ -39,7 +39,7 @@ if (isset($vars['log_set']) && isset($sets[$vars['log_set']])) {
? ''
: $log_file;
- echo generate_link($label, $link_array, ['log_set' => $vars['log_set'], 'log_file'=>$log_file]) . "\n";
+ echo generate_link($label, $link_array, ['log_set' => $vars['log_set'], 'log_file' => $log_file]) . "\n";
if ($index < (count($log_files) - 1)) {
echo ', ';
diff --git a/includes/html/pages/device/apps/mailscanner.inc.php b/includes/html/pages/device/apps/mailscanner.inc.php
index d8bcbceb0a..dd5a4eab30 100644
--- a/includes/html/pages/device/apps/mailscanner.inc.php
+++ b/includes/html/pages/device/apps/mailscanner.inc.php
@@ -1,8 +1,8 @@
'Mailscanner - Sent / Received',
- 'mailscanner_spam' => 'Mailscanner - Spam / Virus',
+ 'mailscanner_sent' => 'Mailscanner - Sent / Received',
+ 'mailscanner_spam' => 'Mailscanner - Spam / Virus',
'mailscanner_reject' => 'Mailscanner - Rejected / Waiting / Relayed',
];
diff --git a/includes/html/pages/device/apps/mdadm.inc.php b/includes/html/pages/device/apps/mdadm.inc.php
index 9bcc17b299..af91717ea2 100644
--- a/includes/html/pages/device/apps/mdadm.inc.php
+++ b/includes/html/pages/device/apps/mdadm.inc.php
@@ -5,10 +5,10 @@ $mdadm_arrays = Rrd::getRrdApplicationArrays($device, $app['app_id'], 'mdadm');
print_optionbar_start();
$link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
- 'app' => 'mdadm',
+ 'tab' => 'apps',
+ 'app' => 'mdadm',
];
$array_list = [];
@@ -28,12 +28,12 @@ printf('%s | arrays: %s', generate_link('All RAID Arrays', $link_array), implode
print_optionbar_end();
$graphs = [
- 'mdadm_level' => 'RAID level',
- 'mdadm_size' => 'RAID Size',
- 'mdadm_disc_count' => 'RAID Disk count',
+ 'mdadm_level' => 'RAID level',
+ 'mdadm_size' => 'RAID Size',
+ 'mdadm_disc_count' => 'RAID Disk count',
'mdadm_hotspare_count' => 'RAID Hotspare Disk count',
- 'mdadm_degraded' => 'RAID degraded',
- 'mdadm_sync_speed' => 'RAID Sync speed',
+ 'mdadm_degraded' => 'RAID degraded',
+ 'mdadm_sync_speed' => 'RAID Sync speed',
'mdadm_sync_completed' => 'RAID Sync completed',
];
diff --git a/includes/html/pages/device/apps/memcached.inc.php b/includes/html/pages/device/apps/memcached.inc.php
index 7c01432ac4..a5c0adc0bc 100644
--- a/includes/html/pages/device/apps/memcached.inc.php
+++ b/includes/html/pages/device/apps/memcached.inc.php
@@ -1,13 +1,13 @@
'Traffic',
+ 'memcached_bits' => 'Traffic',
'memcached_commands' => 'Commands',
- 'memcached_data' => 'Data Size',
- 'memcached_items' => 'Items',
- 'memcached_hitmiss' => 'Hits/Misses',
- 'memcached_uptime' => 'Uptime',
- 'memcached_threads' => 'Threads',
+ 'memcached_data' => 'Data Size',
+ 'memcached_items' => 'Items',
+ 'memcached_hitmiss' => 'Hits/Misses',
+ 'memcached_uptime' => 'Uptime',
+ 'memcached_threads' => 'Threads',
];
diff --git a/includes/html/pages/device/apps/mojo_cape_submit.inc.php b/includes/html/pages/device/apps/mojo_cape_submit.inc.php
index b4a8bb155c..d1e14bca8f 100644
--- a/includes/html/pages/device/apps/mojo_cape_submit.inc.php
+++ b/includes/html/pages/device/apps/mojo_cape_submit.inc.php
@@ -1,10 +1,10 @@
'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
- 'app' => 'mojo_cape_submit',
+ 'tab' => 'apps',
+ 'app' => 'mojo_cape_submit',
];
print_optionbar_start();
diff --git a/includes/html/pages/device/apps/mysql.inc.php b/includes/html/pages/device/apps/mysql.inc.php
index c90ba4b54a..dbb94435b1 100644
--- a/includes/html/pages/device/apps/mysql.inc.php
+++ b/includes/html/pages/device/apps/mysql.inc.php
@@ -5,9 +5,9 @@ print_optionbar_start();
echo "
" . $app->displayName() . ' » ';
$app_sections = [
- 'system' => 'System',
+ 'system' => 'System',
'queries' => 'Queries',
- 'innodb' => 'InnoDB',
+ 'innodb' => 'InnoDB',
];
unset($sep);
@@ -33,33 +33,33 @@ foreach ($app_sections as $app_section => $app_section_text) {
print_optionbar_end();
$graphs['system'] = [
- 'mysql_connections' => 'Connections',
- 'mysql_files_tables' => 'Files and Tables',
- 'mysql_myisam_indexes' => 'MyISAM Indexes',
- 'mysql_network_traffic' => 'Network Traffic',
- 'mysql_table_locks' => 'Table Locks',
+ 'mysql_connections' => 'Connections',
+ 'mysql_files_tables' => 'Files and Tables',
+ 'mysql_myisam_indexes' => 'MyISAM Indexes',
+ 'mysql_network_traffic' => 'Network Traffic',
+ 'mysql_table_locks' => 'Table Locks',
'mysql_temporary_objects' => 'Temporary Objects',
];
$graphs['queries'] = [
- 'mysql_command_counters' => 'Command Counters',
- 'mysql_query_cache' => 'Query Cache',
+ 'mysql_command_counters' => 'Command Counters',
+ 'mysql_query_cache' => 'Query Cache',
'mysql_query_cache_memory' => 'Query Cache Memory',
- 'mysql_select_types' => 'Select Types',
- 'mysql_slow_queries' => 'Slow Queries',
- 'mysql_sorts' => 'Sorts',
+ 'mysql_select_types' => 'Select Types',
+ 'mysql_slow_queries' => 'Slow Queries',
+ 'mysql_sorts' => 'Sorts',
];
$graphs['innodb'] = [
- 'mysql_innodb_buffer_pool' => 'InnoDB Buffer Pool',
+ 'mysql_innodb_buffer_pool' => 'InnoDB Buffer Pool',
'mysql_innodb_buffer_pool_activity' => 'InnoDB Buffer Pool Activity',
- 'mysql_innodb_insert_buffer' => 'InnoDB Insert Buffer',
- 'mysql_innodb_io' => 'InnoDB IO',
- 'mysql_innodb_io_pending' => 'InnoDB IO Pending',
- 'mysql_innodb_log' => 'InnoDB Log',
- 'mysql_innodb_row_operations' => 'InnoDB Row Operations',
- 'mysql_innodb_semaphores' => 'InnoDB semaphores',
- 'mysql_innodb_transactions' => 'InnoDB Transactions',
+ 'mysql_innodb_insert_buffer' => 'InnoDB Insert Buffer',
+ 'mysql_innodb_io' => 'InnoDB IO',
+ 'mysql_innodb_io_pending' => 'InnoDB IO Pending',
+ 'mysql_innodb_log' => 'InnoDB Log',
+ 'mysql_innodb_row_operations' => 'InnoDB Row Operations',
+ 'mysql_innodb_semaphores' => 'InnoDB semaphores',
+ 'mysql_innodb_transactions' => 'InnoDB Transactions',
];
foreach ($graphs[$vars['app_section']] as $key => $text) {
diff --git a/includes/html/pages/device/apps/nfs-server.inc.php b/includes/html/pages/device/apps/nfs-server.inc.php
index 3d9681574b..2143d7035a 100755
--- a/includes/html/pages/device/apps/nfs-server.inc.php
+++ b/includes/html/pages/device/apps/nfs-server.inc.php
@@ -18,10 +18,10 @@ print_optionbar_start();
echo "
" . $app->displayName() . ' » ';
$app_sections = [
- 'default' => 'NFS',
- 'proc2' => 'NFS v2',
- 'proc3' => 'NFS v3',
- 'proc4' => 'NFS v4',
+ 'default' => 'NFS',
+ 'proc2' => 'NFS v2',
+ 'proc3' => 'NFS v3',
+ 'proc4' => 'NFS v4',
];
unset($sep);
diff --git a/includes/html/pages/device/apps/nginx.inc.php b/includes/html/pages/device/apps/nginx.inc.php
index 13e17d0361..d02912e89d 100644
--- a/includes/html/pages/device/apps/nginx.inc.php
+++ b/includes/html/pages/device/apps/nginx.inc.php
@@ -2,7 +2,7 @@
$graphs = [
'nginx_connections' => 'nginx Connections',
- 'nginx_req' => 'nginx requests',
+ 'nginx_req' => 'nginx requests',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/ntp-client.inc.php b/includes/html/pages/device/apps/ntp-client.inc.php
index 7c48391579..81c05d5f78 100644
--- a/includes/html/pages/device/apps/ntp-client.inc.php
+++ b/includes/html/pages/device/apps/ntp-client.inc.php
@@ -2,7 +2,7 @@
$graphs = [
'ntp-client_stats' => 'NTP Client - Statistics',
- 'ntp-client_freq' => 'NTP Client - Frequency',
+ 'ntp-client_freq' => 'NTP Client - Frequency',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/ntp-server.inc.php b/includes/html/pages/device/apps/ntp-server.inc.php
index bea87e0cae..7859627cff 100644
--- a/includes/html/pages/device/apps/ntp-server.inc.php
+++ b/includes/html/pages/device/apps/ntp-server.inc.php
@@ -1,13 +1,13 @@
'NTPD Server - Statistics',
- 'ntp-server_freq' => 'NTPD Server - Frequency',
+ 'ntp-server_stats' => 'NTPD Server - Statistics',
+ 'ntp-server_freq' => 'NTPD Server - Frequency',
'ntp-server_stratum' => 'NTPD Server - Stratum',
- 'ntp-server_buffer' => 'NTPD Server - Buffer',
- 'ntp-server_bits' => 'NTPD Server - Packets Sent/Received',
+ 'ntp-server_buffer' => 'NTPD Server - Buffer',
+ 'ntp-server_bits' => 'NTPD Server - Packets Sent/Received',
'ntp-server_packets' => 'NTPD Server - Packets Dropped/Ignored',
- 'ntp-server_uptime' => 'NTPD Server - Uptime',
+ 'ntp-server_uptime' => 'NTPD Server - Uptime',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/opensearch.inc.php b/includes/html/pages/device/apps/opensearch.inc.php
index 080f368a0a..f2288f80a8 100644
--- a/includes/html/pages/device/apps/opensearch.inc.php
+++ b/includes/html/pages/device/apps/opensearch.inc.php
@@ -1,10 +1,10 @@
'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
- 'app' => 'opensearch',
+ 'tab' => 'apps',
+ 'app' => 'opensearch',
];
print_optionbar_start();
@@ -51,20 +51,20 @@ if (isset($vars['set'])) {
if ($graph_set == 'cluster') {
$graphs = [
- 'opensearch_c_nodes'=>'Nodes',
- 'opensearch_c_data_nodes'=>'Data Nodes',
- 'opensearch_c_all_shards'=>'Combined Shard Stats',
- 'opensearch_c_pending_tasks'=>'Pending Tasks',
- 'opensearch_c_in_fl_fetch'=>'In Flight Fetches',
- 'opensearch_status'=>'Status: 0=Green, 1=Yellow, 2=Red, 3=Unknown',
- 'opensearch_c_task_max_in_time'=>'Tasks Max Time In Milliseconds',
- 'opensearch_c_act_shards_perc'=>'Active Shards Percentage',
- 'opensearch_c_act_pri_shards'=>'Active Primary Shards',
- 'opensearch_c_act_shards'=>'Active Shards',
- 'opensearch_c_rel_shards'=>'Relocating Shards',
- 'opensearch_c_init_shards'=>'Initializing Shards',
- 'opensearch_c_delayed_shards'=>'Delayed Shards',
- 'opensearch_c_unass_shards'=>'Unassigned Shards',
+ 'opensearch_c_nodes' => 'Nodes',
+ 'opensearch_c_data_nodes' => 'Data Nodes',
+ 'opensearch_c_all_shards' => 'Combined Shard Stats',
+ 'opensearch_c_pending_tasks' => 'Pending Tasks',
+ 'opensearch_c_in_fl_fetch' => 'In Flight Fetches',
+ 'opensearch_status' => 'Status: 0=Green, 1=Yellow, 2=Red, 3=Unknown',
+ 'opensearch_c_task_max_in_time' => 'Tasks Max Time In Milliseconds',
+ 'opensearch_c_act_shards_perc' => 'Active Shards Percentage',
+ 'opensearch_c_act_pri_shards' => 'Active Primary Shards',
+ 'opensearch_c_act_shards' => 'Active Shards',
+ 'opensearch_c_rel_shards' => 'Relocating Shards',
+ 'opensearch_c_init_shards' => 'Initializing Shards',
+ 'opensearch_c_delayed_shards' => 'Delayed Shards',
+ 'opensearch_c_unass_shards' => 'Unassigned Shards',
];
} elseif ($graph_set == 'translog') {
$graphs = [
@@ -175,7 +175,7 @@ if ($graph_set == 'cluster') {
];
} elseif ($graph_set == 'time') {
$graphs = [
- 'opensearch_c_task_max_in_time'=>'Tasks Max Time',
+ 'opensearch_c_task_max_in_time' => 'Tasks Max Time',
'opensearch_time_all' => 'Combined',
'opensearch_ti_time' => 'Index Time',
'opensearch_ti_del_time' => 'Delete Time',
@@ -213,20 +213,20 @@ if ($graph_set == 'cluster') {
];
} else {
$graphs = [
- 'opensearch_c_nodes'=>'Nodes',
- 'opensearch_c_data_nodes'=>'Data Nodes',
- 'opensearch_c_all_shards'=>'Combined Shard Stats',
- 'opensearch_c_pending_tasks'=>'Pending Tasks',
- 'opensearch_c_in_fl_fetch'=>'In Flight Fetches',
- 'opensearch_status'=>'Status: 0=Green, 1=Yellow, 2=Red, 3=Unknown',
- 'opensearch_c_task_max_in_time'=>'Tasks Max Time In Milliseconds',
- 'opensearch_c_act_shards_perc'=>'Active Shards Percentage',
- 'opensearch_c_act_pri_shards'=>'Active Primary Shards',
- 'opensearch_c_act_shards'=>'Active Shards',
- 'opensearch_c_rel_shards'=>'Relocating Shards',
- 'opensearch_c_init_shards'=>'Initializing Shards',
- 'opensearch_c_delayed_shards'=>'Delayed Shards',
- 'opensearch_c_unass_shards'=>'Unassigned Shards',
+ 'opensearch_c_nodes' => 'Nodes',
+ 'opensearch_c_data_nodes' => 'Data Nodes',
+ 'opensearch_c_all_shards' => 'Combined Shard Stats',
+ 'opensearch_c_pending_tasks' => 'Pending Tasks',
+ 'opensearch_c_in_fl_fetch' => 'In Flight Fetches',
+ 'opensearch_status' => 'Status: 0=Green, 1=Yellow, 2=Red, 3=Unknown',
+ 'opensearch_c_task_max_in_time' => 'Tasks Max Time In Milliseconds',
+ 'opensearch_c_act_shards_perc' => 'Active Shards Percentage',
+ 'opensearch_c_act_pri_shards' => 'Active Primary Shards',
+ 'opensearch_c_act_shards' => 'Active Shards',
+ 'opensearch_c_rel_shards' => 'Relocating Shards',
+ 'opensearch_c_init_shards' => 'Initializing Shards',
+ 'opensearch_c_delayed_shards' => 'Delayed Shards',
+ 'opensearch_c_unass_shards' => 'Unassigned Shards',
];
}
diff --git a/includes/html/pages/device/apps/opensips.inc.php b/includes/html/pages/device/apps/opensips.inc.php
index 4b0d696dcb..6042d99ce3 100644
--- a/includes/html/pages/device/apps/opensips.inc.php
+++ b/includes/html/pages/device/apps/opensips.inc.php
@@ -1,8 +1,8 @@
'Load Average',
- 'opensips_memory' => 'Memory',
+ 'opensips_load' => 'Load Average',
+ 'opensips_memory' => 'Memory',
'opensips_openfiles' => 'Open files',
];
diff --git a/includes/html/pages/device/apps/portactivity.inc.php b/includes/html/pages/device/apps/portactivity.inc.php
index 82bdeec45b..7494b35962 100644
--- a/includes/html/pages/device/apps/portactivity.inc.php
+++ b/includes/html/pages/device/apps/portactivity.inc.php
@@ -1,10 +1,10 @@
'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
- 'app' => 'portactivity',
+ 'tab' => 'apps',
+ 'app' => 'portactivity',
];
print_optionbar_start();
@@ -34,10 +34,10 @@ if (! isset($vars['port'])) {
];
} else {
$graphs = [
- 'portactivity_totals'=>'Total Connections',
- 'portactivity_total_details'=>'Total Connections Details',
- 'portactivity_to'=>'Connections To Server',
- 'portactivity_from'=>'Connections From Server',
+ 'portactivity_totals' => 'Total Connections',
+ 'portactivity_total_details' => 'Total Connections Details',
+ 'portactivity_to' => 'Connections To Server',
+ 'portactivity_from' => 'Connections From Server',
];
}
diff --git a/includes/html/pages/device/apps/postgres.inc.php b/includes/html/pages/device/apps/postgres.inc.php
index d40f55d3e2..01d2c92503 100644
--- a/includes/html/pages/device/apps/postgres.inc.php
+++ b/includes/html/pages/device/apps/postgres.inc.php
@@ -1,10 +1,10 @@
'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
- 'app' => 'postgres',
+ 'tab' => 'apps',
+ 'app' => 'postgres',
];
print_optionbar_start();
diff --git a/includes/html/pages/device/apps/powerdns.inc.php b/includes/html/pages/device/apps/powerdns.inc.php
index 4929ac45a6..557f46d005 100644
--- a/includes/html/pages/device/apps/powerdns.inc.php
+++ b/includes/html/pages/device/apps/powerdns.inc.php
@@ -1,12 +1,12 @@
'PowerDNS - Latency',
- 'powerdns_fail' => 'PowerDNS - Corrupt / Failed / Timed out',
+ 'powerdns_latency' => 'PowerDNS - Latency',
+ 'powerdns_fail' => 'PowerDNS - Corrupt / Failed / Timed out',
'powerdns_packetcache' => 'PowerDNS - Packet Cache',
- 'powerdns_querycache' => 'PowerDNS - Query Cache',
- 'powerdns_recursing' => 'PowerDNS - Recursing Queries and Answers',
- 'powerdns_queries' => 'PowerDNS - Total UDP/TCP Queries and Answers',
+ 'powerdns_querycache' => 'PowerDNS - Query Cache',
+ 'powerdns_recursing' => 'PowerDNS - Recursing Queries and Answers',
+ 'powerdns_queries' => 'PowerDNS - Total UDP/TCP Queries and Answers',
'powerdns_queries_udp' => 'PowerDNS - Detail UDP IPv4/IPv6 Queries and Answers',
];
diff --git a/includes/html/pages/device/apps/powermon.inc.php b/includes/html/pages/device/apps/powermon.inc.php
index 6edae2b56b..148c795a56 100644
--- a/includes/html/pages/device/apps/powermon.inc.php
+++ b/includes/html/pages/device/apps/powermon.inc.php
@@ -17,7 +17,7 @@ version 3. See https://www.gnu.org/licenses/gpl-3.0.txt
*/
$graphs = [
- 'powermon_consumption' => 'PowerMon - Consumption',
+ 'powermon_consumption' => 'PowerMon - Consumption',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/privoxy.inc.php b/includes/html/pages/device/apps/privoxy.inc.php
index a87f9e5747..3f25d522a4 100644
--- a/includes/html/pages/device/apps/privoxy.inc.php
+++ b/includes/html/pages/device/apps/privoxy.inc.php
@@ -14,43 +14,43 @@ if (! isset($vars['privoxyPage'])) {
print_optionbar_start();
-$link_tmp = generate_link('General', $link_array, ['app'=>'privoxy', 'privoxyPage'=>'general']);
+$link_tmp = generate_link('General', $link_array, ['app' => 'privoxy', 'privoxyPage' => 'general']);
if ($vars['privoxyPage'] == 'general') {
$link_tmp = '';
}
echo $link_tmp . ' | ';
-$link_tmp = generate_link('Blocks', $link_array, ['app'=>'privoxy', 'privoxyPage'=>'blocks']);
+$link_tmp = generate_link('Blocks', $link_array, ['app' => 'privoxy', 'privoxyPage' => 'blocks']);
if ($vars['privoxyPage'] == 'blocks') {
$link_tmp = '';
}
echo $link_tmp . ' | ';
-$link_tmp = generate_link('Connections', $link_array, ['app'=>'privoxy', 'privoxyPage'=>'conn']);
+$link_tmp = generate_link('Connections', $link_array, ['app' => 'privoxy', 'privoxyPage' => 'conn']);
if ($vars['privoxyPage'] == 'conn') {
$link_tmp = '';
}
echo $link_tmp . ' | ';
-$link_tmp = generate_link('Domains', $link_array, ['app'=>'privoxy', 'privoxyPage'=>'domains']);
+$link_tmp = generate_link('Domains', $link_array, ['app' => 'privoxy', 'privoxyPage' => 'domains']);
if ($vars['privoxyPage'] == 'domains') {
$link_tmp = '';
}
echo $link_tmp . ' | ';
-$link_tmp = generate_link('HTTP Req Type', $link_array, ['app'=>'privoxy', 'privoxyPage'=>'http_type']);
+$link_tmp = generate_link('HTTP Req Type', $link_array, ['app' => 'privoxy', 'privoxyPage' => 'http_type']);
if ($vars['privoxyPage'] == 'http_type') {
$link_tmp = '';
}
echo $link_tmp . ' | ';
-$link_tmp = generate_link('HTTP Response Codes', $link_array, ['app'=>'privoxy', 'privoxyPage'=>'http_resp']);
+$link_tmp = generate_link('HTTP Response Codes', $link_array, ['app' => 'privoxy', 'privoxyPage' => 'http_resp']);
if ($vars['privoxyPage'] == 'http_resp') {
$link_tmp = '';
}
echo $link_tmp . ' | ';
-$link_tmp = generate_link('HTTP Version', $link_array, ['app'=>'privoxy', 'privoxyPage'=>'http_ver']);
+$link_tmp = generate_link('HTTP Version', $link_array, ['app' => 'privoxy', 'privoxyPage' => 'http_ver']);
if ($vars['privoxyPage'] == 'http_ver') {
$link_tmp = '';
}
@@ -63,10 +63,10 @@ if ($vars['privoxyPage'] == 'general') {
'privoxy_client_requests' => 'Client Requests',
'privoxy_blocks' => 'Blocked Requests',
'privoxy_block_percent' => 'Blocked Requests, Percent',
- 'privoxy_crunches'=>'Crunches',
- 'privoxy_unique_domains'=>'Unique Domains',
- 'privoxy_unique_bdomains'=>'Unique Domains Blocked',
- 'privoxy_ubd_per'=>'Unique Domains Blocked, Percent',
+ 'privoxy_crunches' => 'Crunches',
+ 'privoxy_unique_domains' => 'Unique Domains',
+ 'privoxy_unique_bdomains' => 'Unique Domains Blocked',
+ 'privoxy_ubd_per' => 'Unique Domains Blocked, Percent',
'privoxy_bytes_to_client' => 'Bytes Sent To Clients',
'privoxy_imp_accounted' => 'Improperly Accounted',
];
@@ -82,7 +82,7 @@ if ($vars['privoxyPage'] == 'general') {
$graphs = [
'privoxy_blocks' => 'Blocked Requests',
'privoxy_block_percent' => 'Blocked Requests, Percent',
- 'privoxy_crunches'=>'Crunches',
+ 'privoxy_crunches' => 'Crunches',
'privoxy_unique_bdomains' => 'Unique Domains, Blocked',
'privoxy_unique_bdomains_np' => 'Unique Domains Without Port, Blocked',
];
diff --git a/includes/html/pages/device/apps/proxmox.inc.php b/includes/html/pages/device/apps/proxmox.inc.php
index 91fc6dca73..3336d8d74e 100644
--- a/includes/html/pages/device/apps/proxmox.inc.php
+++ b/includes/html/pages/device/apps/proxmox.inc.php
@@ -22,7 +22,7 @@ if (! \LibreNMS\Config::get('enable_proxmox')) {
print_error('Proxmox agent was discovered on this host. Please enable Proxmox in your config.');
} else {
$graphs = [
- 'proxmox_traffic' => 'Traffic',
+ 'proxmox_traffic' => 'Traffic',
];
foreach (proxmox_node_vms(var_get('device')) as $nvm) {
diff --git a/includes/html/pages/device/apps/pureftpd.inc.php b/includes/html/pages/device/apps/pureftpd.inc.php
index a65af086a9..782f318966 100644
--- a/includes/html/pages/device/apps/pureftpd.inc.php
+++ b/includes/html/pages/device/apps/pureftpd.inc.php
@@ -1,9 +1,9 @@
'PureFTPd - Bitrate',
+ 'pureftpd_bitrate' => 'PureFTPd - Bitrate',
'pureftpd_connections' => 'PureFTPd - Connections',
- 'pureftpd_users' => 'PureFTPd - Users Connected',
+ 'pureftpd_users' => 'PureFTPd - Users Connected',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/pwrstatd.inc.php b/includes/html/pages/device/apps/pwrstatd.inc.php
index e26852d07a..86be829624 100644
--- a/includes/html/pages/device/apps/pwrstatd.inc.php
+++ b/includes/html/pages/device/apps/pwrstatd.inc.php
@@ -5,10 +5,10 @@ $psu_list = Rrd::getRrdApplicationArrays($device, $app['app_id'], 'pwrstatd');
print_optionbar_start();
$link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
- 'app' => 'pwrstatd',
+ 'tab' => 'apps',
+ 'app' => 'pwrstatd',
];
$sn_list = [];
@@ -28,10 +28,10 @@ printf('%s | PSUs: %s', generate_link('All PSUs', $link_array), implode(', ', $s
print_optionbar_end();
$graphs = [
- 'pwrstatd_minutes' => 'Battery Runtime Remaining',
+ 'pwrstatd_minutes' => 'Battery Runtime Remaining',
'pwrstatd_percentage' => 'Percentage Readings',
- 'pwrstatd_voltage' => 'Voltage Readings',
- 'pwrstatd_wattage' => 'Power Readings',
+ 'pwrstatd_voltage' => 'Voltage Readings',
+ 'pwrstatd_wattage' => 'Power Readings',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/redis.inc.php b/includes/html/pages/device/apps/redis.inc.php
index 780a7f254e..c71e026f13 100644
--- a/includes/html/pages/device/apps/redis.inc.php
+++ b/includes/html/pages/device/apps/redis.inc.php
@@ -1,17 +1,17 @@
'Clients',
- 'redis_memory' => 'Memory',
- 'redis_commands' => 'Commands',
- 'redis_connections' => 'Connections',
- 'redis_defrag' => 'Defrag',
+ 'redis_clients' => 'Clients',
+ 'redis_memory' => 'Memory',
+ 'redis_commands' => 'Commands',
+ 'redis_connections' => 'Connections',
+ 'redis_defrag' => 'Defrag',
'redis_fragmentation' => 'Fragmentation',
- 'redis_keyspace' => 'Keyspace',
- 'redis_net' => 'Net',
- 'redis_objects' => 'Objects',
- 'redis_sync' => 'Sync',
- 'redis_usage' => 'Usage',
+ 'redis_keyspace' => 'Keyspace',
+ 'redis_net' => 'Net',
+ 'redis_objects' => 'Objects',
+ 'redis_sync' => 'Sync',
+ 'redis_usage' => 'Usage',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/rrdcached.inc.php b/includes/html/pages/device/apps/rrdcached.inc.php
index 4098b5da2e..a26673a875 100644
--- a/includes/html/pages/device/apps/rrdcached.inc.php
+++ b/includes/html/pages/device/apps/rrdcached.inc.php
@@ -24,9 +24,9 @@
*/
$graphs = [
'rrdcached_queue_length' => 'Queue Length',
- 'rrdcached_events' => 'Events',
- 'rrdcached_tree' => 'Tree',
- 'rrdcached_journal' => 'Journal',
+ 'rrdcached_events' => 'Events',
+ 'rrdcached_tree' => 'Tree',
+ 'rrdcached_journal' => 'Journal',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/sagan.inc.php b/includes/html/pages/device/apps/sagan.inc.php
index a23abae87c..19a72e13fb 100644
--- a/includes/html/pages/device/apps/sagan.inc.php
+++ b/includes/html/pages/device/apps/sagan.inc.php
@@ -1,10 +1,10 @@
'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
- 'app' => 'sagan',
+ 'tab' => 'apps',
+ 'app' => 'sagan',
];
print_optionbar_start();
@@ -28,21 +28,21 @@ foreach ($sagan_instances as $index => $sinstance) {
print_optionbar_end();
$graphs = [
- 'sagan_bytes'=>'Bytes',
- 'sagan_eps'=>'Events Per Second',
- 'sagan_total'=>'Recieved Log Entries',
- 'sagan_drop'=>'Drop',
- 'sagan_drop_percent'=>'Drop Percent',
- 'sagan_f_total'=>'Flows Total',
- 'sagan_f_dropped'=>'Flows Dropped',
- 'sagan_f_drop_percent'=>'Flows Dropped Percent',
- 'sagan_ignore'=>'Ignore',
- 'sagan_bytes_ignored'=>'Bytes Ignored',
- 'sagan_match'=>'Match',
- 'sagan_max_bytes_log_line'=>'Max Bytes Log Line',
- 'sagan_threshold'=>'Threshold',
- 'sagan_uptime'=>'Uptime',
- 'sagan_alert'=>'Alert: 0=OK, 1=WARNING, 2=CRITICAL, 3+UNKNOWN',
+ 'sagan_bytes' => 'Bytes',
+ 'sagan_eps' => 'Events Per Second',
+ 'sagan_total' => 'Recieved Log Entries',
+ 'sagan_drop' => 'Drop',
+ 'sagan_drop_percent' => 'Drop Percent',
+ 'sagan_f_total' => 'Flows Total',
+ 'sagan_f_dropped' => 'Flows Dropped',
+ 'sagan_f_drop_percent' => 'Flows Dropped Percent',
+ 'sagan_ignore' => 'Ignore',
+ 'sagan_bytes_ignored' => 'Bytes Ignored',
+ 'sagan_match' => 'Match',
+ 'sagan_max_bytes_log_line' => 'Max Bytes Log Line',
+ 'sagan_threshold' => 'Threshold',
+ 'sagan_uptime' => 'Uptime',
+ 'sagan_alert' => 'Alert: 0=OK, 1=WARNING, 2=CRITICAL, 3+UNKNOWN',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/seafile.inc.php b/includes/html/pages/device/apps/seafile.inc.php
index 1ab3c9182a..dd39026ee0 100644
--- a/includes/html/pages/device/apps/seafile.inc.php
+++ b/includes/html/pages/device/apps/seafile.inc.php
@@ -1,14 +1,14 @@
'Connected Devices',
- 'seafile_enabled' => 'activated Accounts',
- 'seafile_libraries' => 'Libraries',
+ 'seafile_connected' => 'Connected Devices',
+ 'seafile_enabled' => 'activated Accounts',
+ 'seafile_libraries' => 'Libraries',
'seafile_trashed_libraries' => 'Trashed Libraries',
- 'seafile_size_consumption' => 'Size Consumption',
- 'seafile_groups' => 'Groups',
- 'seafile_version' => 'Client Version',
- 'seafile_platform' => 'Client Platform',
+ 'seafile_size_consumption' => 'Size Consumption',
+ 'seafile_groups' => 'Groups',
+ 'seafile_version' => 'Client Version',
+ 'seafile_platform' => 'Client Platform',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/shoutcast.inc.php b/includes/html/pages/device/apps/shoutcast.inc.php
index 004ec090c0..191d29d8e0 100644
--- a/includes/html/pages/device/apps/shoutcast.inc.php
+++ b/includes/html/pages/device/apps/shoutcast.inc.php
@@ -4,7 +4,7 @@ $total = true;
if (isset($total) && $total === true) {
$graphs = [
- 'shoutcast_multi_bits' => 'Traffic Statistics - Total of all Shoutcast servers',
+ 'shoutcast_multi_bits' => 'Traffic Statistics - Total of all Shoutcast servers',
'shoutcast_multi_stats' => 'Shoutcast Statistics - Total of all Shoutcast servers',
];
@@ -35,7 +35,7 @@ foreach ($files as $file) {
$hostname = end($pieces);
[$host, $port] = explode('_', $hostname, 2);
$graphs = [
- 'shoutcast_bits' => 'Traffic Statistics - ' . $host . ' (Port: ' . $port . ')',
+ 'shoutcast_bits' => 'Traffic Statistics - ' . $host . ' (Port: ' . $port . ')',
'shoutcast_stats' => 'Shoutcast Statistics - ' . $host . ' (Port: ' . $port . ')',
];
diff --git a/includes/html/pages/device/apps/smart.inc.php b/includes/html/pages/device/apps/smart.inc.php
index 0e428f2726..9f3bc98eca 100644
--- a/includes/html/pages/device/apps/smart.inc.php
+++ b/includes/html/pages/device/apps/smart.inc.php
@@ -3,10 +3,10 @@
print_optionbar_start();
$link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
- 'app' => 'smart',
+ 'tab' => 'apps',
+ 'app' => 'smart',
];
$drives = [];
@@ -28,7 +28,7 @@ foreach ($app_data['disks'] as $label => $disk_data) {
}
}
- array_push($drives, generate_link($label, $link_array, ['disk'=>$disk]) . $health_status);
+ array_push($drives, generate_link($label, $link_array, ['disk' => $disk]) . $health_status);
}
printf('%s | drives: %s', generate_link('All Drives', $link_array), implode(', ', $drives));
@@ -71,13 +71,13 @@ if (isset($vars['disk'])) {
}
print_optionbar_end();
$graphs = [
- 'smart_big5' => 'Reliability / Age',
- 'smart_temp' => 'Temperature',
- 'smart_ssd' => 'SSD-specific',
- 'smart_other' => 'Other',
- 'smart_tests_status'=> 'S.M.A.R.T self-tests results',
- 'smart_tests_ran' => 'S.M.A.R.T self-tests run count',
- 'smart_runtime' => 'Power On Hours',
+ 'smart_big5' => 'Reliability / Age',
+ 'smart_temp' => 'Temperature',
+ 'smart_ssd' => 'SSD-specific',
+ 'smart_other' => 'Other',
+ 'smart_tests_status' => 'S.M.A.R.T self-tests results',
+ 'smart_tests_ran' => 'S.M.A.R.T self-tests run count',
+ 'smart_runtime' => 'Power On Hours',
];
if ($app_data['disks'][$vars['disk']]['is_ssd'] != 1) {
unset($graphs['smart_ssd']);
diff --git a/includes/html/pages/device/apps/sneck.inc.php b/includes/html/pages/device/apps/sneck.inc.php
index e537d5871f..95e2a91172 100644
--- a/includes/html/pages/device/apps/sneck.inc.php
+++ b/includes/html/pages/device/apps/sneck.inc.php
@@ -1,22 +1,22 @@
'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
- 'app' => 'sneck',
+ 'tab' => 'apps',
+ 'app' => 'sneck',
];
$link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
- 'app' => 'sneck',
+ 'tab' => 'apps',
+ 'app' => 'sneck',
];
$graphs = [
- 'sneck_results'=>'Results',
- 'sneck_time'=>'Time Difference',
+ 'sneck_results' => 'Results',
+ 'sneck_time' => 'Time Difference',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/suricata.inc.php b/includes/html/pages/device/apps/suricata.inc.php
index ab00589926..3f817613f1 100644
--- a/includes/html/pages/device/apps/suricata.inc.php
+++ b/includes/html/pages/device/apps/suricata.inc.php
@@ -1,10 +1,10 @@
'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
- 'app' => 'suricata',
+ 'tab' => 'apps',
+ 'app' => 'suricata',
];
print_optionbar_start();
@@ -28,17 +28,17 @@ foreach ($suricata_instances as $index => $sinstance) {
print_optionbar_end();
$graphs = [
- 'suricata_packets'=>'Packets',
- 'suricata_bytes'=>'Bytes',
- 'suricata_nasty_delta'=>'Drops or Errors Delta',
- 'suricata_nasty_percent'=>'Drops or Errors Percent',
- 'suricata_dec_proto'=>'Decoder Protocols',
- 'suricata_flow_proto'=>'Flow Protocols',
- 'suricata_app_flows'=>'App Layer Flows',
- 'suricata_app_tx'=>'App Layer TX',
- 'suricata_mem_use'=>'Memory Usage',
- 'suricata_uptime'=>'Uptime',
- 'suricata_alert'=>'Alert Status',
+ 'suricata_packets' => 'Packets',
+ 'suricata_bytes' => 'Bytes',
+ 'suricata_nasty_delta' => 'Drops or Errors Delta',
+ 'suricata_nasty_percent' => 'Drops or Errors Percent',
+ 'suricata_dec_proto' => 'Decoder Protocols',
+ 'suricata_flow_proto' => 'Flow Protocols',
+ 'suricata_app_flows' => 'App Layer Flows',
+ 'suricata_app_tx' => 'App Layer TX',
+ 'suricata_mem_use' => 'Memory Usage',
+ 'suricata_uptime' => 'Uptime',
+ 'suricata_alert' => 'Alert Status',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/suricata_extract.inc.php b/includes/html/pages/device/apps/suricata_extract.inc.php
index 7f898a0bea..2deaf645ad 100644
--- a/includes/html/pages/device/apps/suricata_extract.inc.php
+++ b/includes/html/pages/device/apps/suricata_extract.inc.php
@@ -2,20 +2,20 @@
$graphs = [
'suricata_extract_sub' => 'Submission',
- 'suricata_extract_ignored_host' => 'Ignored By Host',
- 'suricata_extract_ignored_ip' => 'Ignored By IP',
- 'suricata_extract_ignored_ip_src' => 'Ignored By IP Source',
- 'suricata_extract_ignored_ip_dest' => 'Ignored By IP Destination',
- 'suricata_extract_sub_fail' => 'Submission Failure',
- 'suricata_extract_errors' => 'Errors',
- 'suricata_extract_truncated' => 'File Truncated',
- 'suricata_extract_zero_sized' => 'File Zero Sized',
- 'suricata_extract_sub_size' => 'Total Size Of Submissions',
- 'suricata_extract_sub_codes' => 'HTTP Submission Result Codes',
- 'suricata_extract_sub_2xx' => 'HTTP Submission Result Code, 2xx',
- 'suricata_extract_sub_3xx' => 'HTTP Submission Result Code, 3xx',
- 'suricata_extract_sub_4xx' => 'HTTP Submission Result Code, 4xx',
- 'suricata_extract_sub_5xx' => 'HTTP Submission Result Code, 5xx',
+ 'suricata_extract_ignored_host' => 'Ignored By Host',
+ 'suricata_extract_ignored_ip' => 'Ignored By IP',
+ 'suricata_extract_ignored_ip_src' => 'Ignored By IP Source',
+ 'suricata_extract_ignored_ip_dest' => 'Ignored By IP Destination',
+ 'suricata_extract_sub_fail' => 'Submission Failure',
+ 'suricata_extract_errors' => 'Errors',
+ 'suricata_extract_truncated' => 'File Truncated',
+ 'suricata_extract_zero_sized' => 'File Zero Sized',
+ 'suricata_extract_sub_size' => 'Total Size Of Submissions',
+ 'suricata_extract_sub_codes' => 'HTTP Submission Result Codes',
+ 'suricata_extract_sub_2xx' => 'HTTP Submission Result Code, 2xx',
+ 'suricata_extract_sub_3xx' => 'HTTP Submission Result Code, 3xx',
+ 'suricata_extract_sub_4xx' => 'HTTP Submission Result Code, 4xx',
+ 'suricata_extract_sub_5xx' => 'HTTP Submission Result Code, 5xx',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/tinydns.inc.php b/includes/html/pages/device/apps/tinydns.inc.php
index d4e0b30665..1a61b0f9ba 100644
--- a/includes/html/pages/device/apps/tinydns.inc.php
+++ b/includes/html/pages/device/apps/tinydns.inc.php
@@ -26,9 +26,9 @@
$graphs = [
'tinydns_queries' => 'Queries',
- 'tinydns_errors' => 'Errors',
- 'tinydns_dnssec' => 'DNSSec',
- 'tinydns_other' => 'Other',
+ 'tinydns_errors' => 'Errors',
+ 'tinydns_dnssec' => 'DNSSec',
+ 'tinydns_other' => 'Other',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/unbound.inc.php b/includes/html/pages/device/apps/unbound.inc.php
index c53457bcbc..19b3b63821 100644
--- a/includes/html/pages/device/apps/unbound.inc.php
+++ b/includes/html/pages/device/apps/unbound.inc.php
@@ -2,10 +2,10 @@
$graphs = [
'unbound_queries' => 'Unbound - Queries',
- 'unbound_cache' => 'Unbound - Cache',
- 'unbound_operations' => 'Unbound - Operations',
- 'unbound_requestlist' => 'Unbound - Request list',
- 'unbound_recursiontime' => 'Unbound - Recursion time',
+ 'unbound_cache' => 'Unbound - Cache',
+ 'unbound_operations' => 'Unbound - Operations',
+ 'unbound_requestlist' => 'Unbound - Request list',
+ 'unbound_recursiontime' => 'Unbound - Recursion time',
];
foreach ($graphs as $key => $text) {
$graph_type = $key;
diff --git a/includes/html/pages/device/apps/voip-monitor.inc.php b/includes/html/pages/device/apps/voip-monitor.inc.php
index a113bd793f..fbbb8f8335 100644
--- a/includes/html/pages/device/apps/voip-monitor.inc.php
+++ b/includes/html/pages/device/apps/voip-monitor.inc.php
@@ -1,9 +1,9 @@
'CPU Load',
- 'voip-monitor_memoryusage' => 'Used Memory',
- 'voip-monitor_openfiles' => 'Open files',
+ 'voip-monitor_cpuload' => 'CPU Load',
+ 'voip-monitor_memoryusage' => 'Used Memory',
+ 'voip-monitor_openfiles' => 'Open files',
];
foreach ($graphs as $key => $text) {
diff --git a/includes/html/pages/device/apps/zfs.inc.php b/includes/html/pages/device/apps/zfs.inc.php
index c4e5ba8d89..7e931ebe79 100644
--- a/includes/html/pages/device/apps/zfs.inc.php
+++ b/includes/html/pages/device/apps/zfs.inc.php
@@ -1,16 +1,16 @@
'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'apps',
- 'app' => 'zfs',
+ 'tab' => 'apps',
+ 'app' => 'zfs',
];
print_optionbar_start();
echo generate_link('ARC', $link_array);
-echo ' | ' . generate_link('L2', $link_array, ['zfs_page'=>'l2']);
+echo ' | ' . generate_link('L2', $link_array, ['zfs_page' => 'l2']);
echo ' | Pools: ';
$pools = $app->data['pools'] ?? [];
@@ -31,9 +31,9 @@ print_optionbar_end();
if (isset($vars['pool'])) {
$graphs = [
- 'zfs_pool_space'=>'Pool Space',
- 'zfs_pool_cap'=>'Pool Capacity',
- 'zfs_pool_frag'=>'Pool Fragmentation',
+ 'zfs_pool_space' => 'Pool Space',
+ 'zfs_pool_cap' => 'Pool Capacity',
+ 'zfs_pool_frag' => 'Pool Fragmentation',
];
} elseif (isset($vars['zfs_page']) && $vars['zfs_page'] == 'l2') {
$graphs = [
diff --git a/includes/html/pages/device/collectd.inc.php b/includes/html/pages/device/collectd.inc.php
index 28583ab95b..febb99b563 100644
--- a/includes/html/pages/device/collectd.inc.php
+++ b/includes/html/pages/device/collectd.inc.php
@@ -48,9 +48,9 @@ function dhtml_response_list(&$items, $method)
print_optionbar_start();
$link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'collectd',
+ 'tab' => 'collectd',
];
$plugins = collectd_list_plugins($device['hostname']);
diff --git a/includes/html/pages/device/edit.inc.php b/includes/html/pages/device/edit.inc.php
index 164d65c493..17d36a59a9 100644
--- a/includes/html/pages/device/edit.inc.php
+++ b/includes/html/pages/device/edit.inc.php
@@ -2,8 +2,8 @@
$no_refresh = true;
-$link_array = ['page' => 'device',
- 'device' => $device['device_id'],
+$link_array = ['page' => 'device',
+ 'device' => $device['device_id'],
'tab' => 'edit', ];
if (! Auth::user()->hasGlobalAdmin()) {
@@ -69,7 +69,7 @@ if (! Auth::user()->hasGlobalAdmin()) {
} else {
}
- echo generate_link($text, $link_array, ['section'=>$type]);
+ echo generate_link($text, $link_array, ['section' => $type]);
if ($vars['section'] == $type) {
echo '';
diff --git a/includes/html/pages/device/graphs.inc.php b/includes/html/pages/device/graphs.inc.php
index afc15f1d49..789def962b 100644
--- a/includes/html/pages/device/graphs.inc.php
+++ b/includes/html/pages/device/graphs.inc.php
@@ -2,9 +2,9 @@
// Graphs are printed in the order they exist in \LibreNMS\Config::get('graph_types')
$link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'graphs',
+ 'tab' => 'graphs',
];
$bg = '#ffffff';
diff --git a/includes/html/pages/device/health.inc.php b/includes/html/pages/device/health.inc.php
index 219d0989e4..068eab7c69 100644
--- a/includes/html/pages/device/health.inc.php
+++ b/includes/html/pages/device/health.inc.php
@@ -36,7 +36,7 @@ use App\Models\Storage;
$qfp = 0;
if ($device['os_group'] == 'cisco') {
$component = new LibreNMS\Component();
- $components = $component->getComponents($device['device_id'], ['type'=> 'cisco-qfp']);
+ $components = $component->getComponents($device['device_id'], ['type' => 'cisco-qfp']);
$components = $components[$device['device_id']];
$qfp = isset($components) ? count($components) : 0;
}
@@ -87,9 +87,9 @@ $type_text['storage'] = 'Disk Usage';
$type_text['diskio'] = 'Disk I/O';
$link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'health',
+ 'tab' => 'health',
];
print_optionbar_start();
diff --git a/includes/html/pages/device/loadbalancer.inc.php b/includes/html/pages/device/loadbalancer.inc.php
index 8f8134e3c4..1e9ef41414 100644
--- a/includes/html/pages/device/loadbalancer.inc.php
+++ b/includes/html/pages/device/loadbalancer.inc.php
@@ -1,9 +1,9 @@
'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'loadbalancer',
+ 'tab' => 'loadbalancer',
];
$type_text['loadbalancer_rservers'] = 'Rservers'; // Cisco ACE
diff --git a/includes/html/pages/device/loadbalancer/ace_rservers.inc.php b/includes/html/pages/device/loadbalancer/ace_rservers.inc.php
index 45617ddff1..afa16fc782 100644
--- a/includes/html/pages/device/loadbalancer/ace_rservers.inc.php
+++ b/includes/html/pages/device/loadbalancer/ace_rservers.inc.php
@@ -33,9 +33,9 @@ echo ' Graphs: ';
// "pkts" => "Packets",
// "errors" => "Errors");
$graph_types = [
- 'curr' => 'CurrentConns',
+ 'curr' => 'CurrentConns',
'failed' => 'FailedConns',
- 'total' => 'TotalConns',
+ 'total' => 'TotalConns',
];
foreach ($graph_types as $type => $descr) {
diff --git a/includes/html/pages/device/loadbalancer/ace_vservers.inc.php b/includes/html/pages/device/loadbalancer/ace_vservers.inc.php
index 4125a67aea..93b19a4b45 100644
--- a/includes/html/pages/device/loadbalancer/ace_vservers.inc.php
+++ b/includes/html/pages/device/loadbalancer/ace_vservers.inc.php
@@ -30,8 +30,8 @@ unset($sep);
echo ' Graphs: ';
$graph_types = [
- 'bits' => 'Bits',
- 'pkts' => 'Packets',
+ 'bits' => 'Bits',
+ 'pkts' => 'Packets',
'conns' => 'Connections',
];
diff --git a/includes/html/pages/device/loadbalancer/netscaler_vsvr.inc.php b/includes/html/pages/device/loadbalancer/netscaler_vsvr.inc.php
index 2039e9c223..46606578cd 100644
--- a/includes/html/pages/device/loadbalancer/netscaler_vsvr.inc.php
+++ b/includes/html/pages/device/loadbalancer/netscaler_vsvr.inc.php
@@ -6,10 +6,10 @@ if (is_numeric($vars['vsvr'])) {
// echo('
All');
// print_optionbar_end();
$graph_types = [
- 'bits' => 'Bits',
- 'pkts' => 'Packets',
- 'conns' => 'Connections',
- 'reqs' => 'Requests',
+ 'bits' => 'Bits',
+ 'pkts' => 'Packets',
+ 'conns' => 'Connections',
+ 'reqs' => 'Requests',
'hitmiss' => 'Hit/Miss',
];
@@ -96,10 +96,10 @@ if (is_numeric($vars['vsvr'])) {
unset($sep);
echo ' Graphs: ';
$graph_types = [
- 'bits' => 'Bits',
- 'pkts' => 'Packets',
- 'conns' => 'Connections',
- 'reqs' => 'Requests',
+ 'bits' => 'Bits',
+ 'pkts' => 'Packets',
+ 'conns' => 'Connections',
+ 'reqs' => 'Requests',
'hitmiss' => 'Hit/Miss',
];
diff --git a/includes/html/pages/device/munin.inc.php b/includes/html/pages/device/munin.inc.php
index 7113b18cd6..512697996e 100644
--- a/includes/html/pages/device/munin.inc.php
+++ b/includes/html/pages/device/munin.inc.php
@@ -2,9 +2,9 @@
// Graphs are printed in the order they exist in \LibreNMS\Config::get('graph_types')
$link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'munin',
+ 'tab' => 'munin',
];
$bg = '#ffffff';
diff --git a/includes/html/pages/device/nfsen.inc.php b/includes/html/pages/device/nfsen.inc.php
index 2a29a6bef1..15151963e5 100644
--- a/includes/html/pages/device/nfsen.inc.php
+++ b/includes/html/pages/device/nfsen.inc.php
@@ -3,9 +3,9 @@
print_optionbar_start();
$link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'netflow',
+ 'tab' => 'netflow',
];
echo generate_link('General', $link_array, ['nfsen' => 'general']);
diff --git a/includes/html/pages/device/nfsen/channel.inc.php b/includes/html/pages/device/nfsen/channel.inc.php
index 9a92312f6e..d50de31ffb 100644
--- a/includes/html/pages/device/nfsen/channel.inc.php
+++ b/includes/html/pages/device/nfsen/channel.inc.php
@@ -1,7 +1,7 @@
'nfsen_channel_flows',
+ 'Flows' => 'nfsen_channel_flows',
'Packets' => 'nfsen_channel_packets',
'Traffic' => 'nfsen_channel_traffic',
];
diff --git a/includes/html/pages/device/nfsen/general.inc.php b/includes/html/pages/device/nfsen/general.inc.php
index 9bb6b22052..5de04f98d0 100644
--- a/includes/html/pages/device/nfsen/general.inc.php
+++ b/includes/html/pages/device/nfsen/general.inc.php
@@ -1,7 +1,7 @@
'nfsen_flows',
+ 'Flows' => 'nfsen_flows',
'Packets' => 'nfsen_packets',
'Traffic' => 'nfsen_traffic',
];
diff --git a/includes/html/pages/device/nfsen/stats.inc.php b/includes/html/pages/device/nfsen/stats.inc.php
index c844588d22..b3bfd768db 100644
--- a/includes/html/pages/device/nfsen/stats.inc.php
+++ b/includes/html/pages/device/nfsen/stats.inc.php
@@ -44,19 +44,19 @@ echo '
$option_default = $vars['stattype'] ?? \LibreNMS\Config::get('nfsen_stats_default');
$stat_types = [
- 'record'=>'Flow Records',
- 'ip'=>'Any IP Address',
- 'srcip'=>'SRC IP Address',
- 'dstip'=>'DST IP Address',
- 'port'=>'Any Port',
- 'srcport'=>'SRC Port',
- 'dstport'=>'DST Port',
- 'srctos'=>'SRC TOS',
- 'dsttos'=>'DST TOS',
- 'tos'=>'TOS',
- 'as'=>'AS',
- 'srcas'=>'SRC AS',
- 'dstas'=>'DST AS',
+ 'record' => 'Flow Records',
+ 'ip' => 'Any IP Address',
+ 'srcip' => 'SRC IP Address',
+ 'dstip' => 'DST IP Address',
+ 'port' => 'Any Port',
+ 'srcport' => 'SRC Port',
+ 'dstport' => 'DST Port',
+ 'srctos' => 'SRC TOS',
+ 'dsttos' => 'DST TOS',
+ 'tos' => 'TOS',
+ 'as' => 'AS',
+ 'srcas' => 'SRC AS',
+ 'dstas' => 'DST AS',
];
// puts together the drop down options
@@ -82,12 +82,12 @@ if (isset($vars['statorder'])) {
// WARNING: order is relevant as it has to match the
// check later in the process part of this page.
$order_types = [
- 'flows'=>1,
- 'packets'=>1,
- 'bytes'=>1,
- 'pps'=>1,
- 'bps'=>1,
- 'bpp'=>1,
+ 'flows' => 1,
+ 'packets' => 1,
+ 'bytes' => 1,
+ 'pps' => 1,
+ 'bps' => 1,
+ 'bpp' => 1,
];
// puts together the drop down options
diff --git a/includes/html/pages/device/port.inc.php b/includes/html/pages/device/port.inc.php
index 3e38a10ade..cfec5dc91c 100644
--- a/includes/html/pages/device/port.inc.php
+++ b/includes/html/pages/device/port.inc.php
@@ -66,10 +66,10 @@ echo "
";
print_optionbar_start();
$link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'port',
- 'port' => $port->port_id,
+ 'tab' => 'port',
+ 'port' => $port->port_id,
];
$menu_options['graphs'] = 'Graphs';
diff --git a/includes/html/pages/device/processes.inc.php b/includes/html/pages/device/processes.inc.php
index f91d82a6bb..cd3b9df4b5 100644
--- a/includes/html/pages/device/processes.inc.php
+++ b/includes/html/pages/device/processes.inc.php
@@ -57,11 +57,11 @@ if (isset($vars['by']) && $vars['by'] == 'desc') {
}
$heads = [
- 'PID' => '',
- 'VSZ' => 'Virtual Memory',
- 'RSS' => 'Resident Memory',
+ 'PID' => '',
+ 'VSZ' => 'Virtual Memory',
+ 'RSS' => 'Resident Memory',
'cputime' => '',
- 'user' => '',
+ 'user' => '',
'command' => '',
];
diff --git a/includes/html/pages/device/routing.inc.php b/includes/html/pages/device/routing.inc.php
index 981efdcaaa..d8ea8929d3 100644
--- a/includes/html/pages/device/routing.inc.php
+++ b/includes/html/pages/device/routing.inc.php
@@ -1,9 +1,9 @@
'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'routing',
+ 'tab' => 'routing',
];
// $type_text['overview'] = "Overview";
diff --git a/includes/html/pages/device/routing/cef.inc.php b/includes/html/pages/device/routing/cef.inc.php
index 8ab6b72d4b..3b8b358483 100644
--- a/includes/html/pages/device/routing/cef.inc.php
+++ b/includes/html/pages/device/routing/cef.inc.php
@@ -3,10 +3,10 @@
print_optionbar_start();
$link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'routing',
- 'proto' => 'cef',
+ 'tab' => 'routing',
+ 'proto' => 'cef',
];
if (! isset($vars['view'])) {
diff --git a/includes/html/pages/device/routing/mpls.inc.php b/includes/html/pages/device/routing/mpls.inc.php
index a792be8acc..2c99f02731 100644
--- a/includes/html/pages/device/routing/mpls.inc.php
+++ b/includes/html/pages/device/routing/mpls.inc.php
@@ -5,10 +5,10 @@ use LibreNMS\Util\Number;
print_optionbar_start();
$link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'routing',
- 'proto' => 'mpls',
+ 'tab' => 'routing',
+ 'proto' => 'mpls',
];
if (! isset($vars['view'])) {
diff --git a/includes/html/pages/device/routing/vrf.inc.php b/includes/html/pages/device/routing/vrf.inc.php
index 5d37ea69d2..c19501172a 100644
--- a/includes/html/pages/device/routing/vrf.inc.php
+++ b/includes/html/pages/device/routing/vrf.inc.php
@@ -1,10 +1,10 @@
'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'routing',
- 'proto' => 'vrf',
+ 'tab' => 'routing',
+ 'proto' => 'vrf',
];
// echo(generate_link("Basic", $link_array,array('view'=>'basic')));
@@ -43,10 +43,10 @@ unset($sep);
echo ' Graphs: ';
$graph_types = [
- 'bits' => 'Bits',
- 'upkts' => 'Unicast Packets',
- 'nupkts' => 'Non-Unicast Packets',
- 'errors' => 'Errors',
+ 'bits' => 'Bits',
+ 'upkts' => 'Unicast Packets',
+ 'nupkts' => 'Non-Unicast Packets',
+ 'errors' => 'Errors',
'etherlike' => 'Etherlike',
];
diff --git a/includes/html/pages/device/wireless.inc.php b/includes/html/pages/device/wireless.inc.php
index 3c1cfba119..52cd317487 100644
--- a/includes/html/pages/device/wireless.inc.php
+++ b/includes/html/pages/device/wireless.inc.php
@@ -13,9 +13,9 @@ $sensors = dbFetchColumn(
$datas = array_intersect(array_keys($types), $sensors);
$wireless_link_array = [
- 'page' => 'device',
+ 'page' => 'device',
'device' => $device['device_id'],
- 'tab' => 'wireless',
+ 'tab' => 'wireless',
];
print_optionbar_start();
diff --git a/includes/html/pages/health.inc.php b/includes/html/pages/health.inc.php
index e1c52d5303..9991e9e00d 100644
--- a/includes/html/pages/health.inc.php
+++ b/includes/html/pages/health.inc.php
@@ -77,7 +77,7 @@ foreach ($datas as $texttype) {
if ($active_metric == $metric) {
$navbar .= '';
}
@@ -90,7 +90,7 @@ if ($vars['view'] == 'graphs') {
$displayoptions = '';
@@ -102,7 +102,7 @@ if ($vars['view'] != 'graphs') {
$displayoptions .= '';
diff --git a/includes/html/pages/routing/bgp.inc.php b/includes/html/pages/routing/bgp.inc.php
index 44597339a1..76f542a052 100644
--- a/includes/html/pages/routing/bgp.inc.php
+++ b/includes/html/pages/routing/bgp.inc.php
@@ -11,7 +11,7 @@ if (! Auth::user()->hasGlobalRead()) {
include 'includes/html/error-no-perm.inc.php';
} else {
$link_array = [
- 'page' => 'routing',
+ 'page' => 'routing',
'protocol' => 'bgp',
];
diff --git a/includes/html/pages/routing/isis.inc.php b/includes/html/pages/routing/isis.inc.php
index 693a9f824e..66b66a76bb 100644
--- a/includes/html/pages/routing/isis.inc.php
+++ b/includes/html/pages/routing/isis.inc.php
@@ -6,7 +6,7 @@ if (! Auth::user()->hasGlobalRead()) {
include 'includes/html/error-no-perm.inc.php';
} else {
$link_array = [
- 'page' => 'routing',
+ 'page' => 'routing',
'protocol' => 'isis',
];
diff --git a/includes/html/pages/routing/mpls.inc.php b/includes/html/pages/routing/mpls.inc.php
index e076f17cb7..db8f7a237c 100644
--- a/includes/html/pages/routing/mpls.inc.php
+++ b/includes/html/pages/routing/mpls.inc.php
@@ -5,8 +5,8 @@ use LibreNMS\Util\Number;
print_optionbar_start();
$link_array = [
- 'page' => 'routing',
- 'protocol' => 'mpls',
+ 'page' => 'routing',
+ 'protocol' => 'mpls',
];
if (! isset($vars['view'])) {
diff --git a/includes/html/pages/routing/vrf.inc.php b/includes/html/pages/routing/vrf.inc.php
index 1901d3c25c..e1c3543c53 100644
--- a/includes/html/pages/routing/vrf.inc.php
+++ b/includes/html/pages/routing/vrf.inc.php
@@ -7,7 +7,7 @@ if (! Auth::user()->hasGlobalRead()) {
include 'includes/html/error-no-perm.inc.php';
} else {
$link_array = [
- 'page' => 'routing',
+ 'page' => 'routing',
'protocol' => 'vrf',
];
@@ -41,10 +41,10 @@ if (! Auth::user()->hasGlobalRead()) {
echo ' Graphs: ';
$graph_types = [
- 'bits' => 'Bits',
- 'upkts' => 'Unicast Packets',
- 'nupkts' => 'Non-Unicast Packets',
- 'errors' => 'Errors',
+ 'bits' => 'Bits',
+ 'upkts' => 'Unicast Packets',
+ 'nupkts' => 'Non-Unicast Packets',
+ 'errors' => 'Errors',
'etherlike' => 'Etherlike',
];
diff --git a/includes/html/pages/search.inc.php b/includes/html/pages/search.inc.php
index 842327246f..679816c78f 100644
--- a/includes/html/pages/search.inc.php
+++ b/includes/html/pages/search.inc.php
@@ -7,9 +7,9 @@ $pagetitle[] = 'Search';
$sections = [
'ipv4' => 'IPv4 Address',
'ipv6' => 'IPv6 Address',
- 'mac' => 'MAC Address',
- 'arp' => 'ARP Table',
- 'fdb' => 'FDB Table',
+ 'mac' => 'MAC Address',
+ 'arp' => 'ARP Table',
+ 'fdb' => 'FDB Table',
];
if (dbFetchCell('SELECT 1 from `packages` LIMIT 1')) {
diff --git a/includes/html/pages/wireless.inc.php b/includes/html/pages/wireless.inc.php
index c8d5991a1e..be3a806c68 100644
--- a/includes/html/pages/wireless.inc.php
+++ b/includes/html/pages/wireless.inc.php
@@ -42,7 +42,7 @@ foreach ($valid_wireless_types as $type => $details) {
$linkoptions .= '';
@@ -56,7 +56,7 @@ $displayoptions = '';
if ($vars['view'] == 'graphs') {
$displayoptions .= '';
}
@@ -67,7 +67,7 @@ if ($vars['view'] != 'graphs') {
$displayoptions .= '';
diff --git a/includes/html/table/address-search.inc.php b/includes/html/table/address-search.inc.php
index 1c723aa94a..bd71f88d74 100644
--- a/includes/html/table/address-search.inc.php
+++ b/includes/html/table/address-search.inc.php
@@ -104,9 +104,9 @@ foreach (dbFetchRows($sql, $param) as $interface) {
if (port_permitted($interface['port_id'])) {
$interface = cleanPort($interface, $interface);
$row = [
- 'hostname' => generate_device_link($interface),
- 'interface' => generate_port_link($interface) . ' ' . $error_img,
- 'address' => $address,
+ 'hostname' => generate_device_link($interface),
+ 'interface' => generate_port_link($interface) . ' ' . $error_img,
+ 'address' => $address,
'description' => $interface['ifAlias'],
];
if ($vars['search_type'] == 'mac') {
@@ -117,9 +117,9 @@ foreach (dbFetchRows($sql, $param) as $interface) {
}//end foreach
$output = [
- 'current' => $current,
+ 'current' => $current,
'rowCount' => $rowCount,
- 'rows' => $response,
- 'total' => $total,
+ 'rows' => $response,
+ 'total' => $total,
];
echo json_encode($output, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
diff --git a/includes/html/table/app_ntp.inc.php b/includes/html/table/app_ntp.inc.php
index 297b30b85b..fed388c7d6 100644
--- a/includes/html/table/app_ntp.inc.php
+++ b/includes/html/table/app_ntp.inc.php
@@ -72,10 +72,10 @@ foreach ($components as $devid => $comp) {
}
$response[] = [
- 'device' => $device_link,
- 'peer' => $array['peer'],
- 'stratum' => $array['stratum'],
- 'error' => $array['error'],
+ 'device' => $device_link,
+ 'peer' => $array['peer'],
+ 'stratum' => $array['stratum'],
+ 'error' => $array['error'],
];
// Do we want a graphrow.
@@ -84,10 +84,10 @@ foreach ($components as $devid => $comp) {
require 'includes/html/print-graphrow.inc.php';
unset($return_data);
$response[] = [
- 'device' => $graph_data[0],
- 'peer' => $graph_data[1],
- 'stratum' => $graph_data[2],
- 'error' => $graph_data[3],
+ 'device' => $graph_data[0],
+ 'peer' => $graph_data[1],
+ 'stratum' => $graph_data[2],
+ 'error' => $graph_data[3],
];
}
} // End if in range
@@ -101,9 +101,9 @@ if ($count == 0) {
}
$output = [
- 'current' => $current,
+ 'current' => $current,
'rowCount' => $rowCount,
- 'rows' => $response,
- 'total' => $count,
+ 'rows' => $response,
+ 'total' => $count,
];
echo json_encode($output, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
diff --git a/includes/html/table/arp-search.inc.php b/includes/html/table/arp-search.inc.php
index 3c2e8603fd..71ec687be6 100644
--- a/includes/html/table/arp-search.inc.php
+++ b/includes/html/table/arp-search.inc.php
@@ -99,12 +99,12 @@ foreach (dbFetchRows($sql, $param) as $entry) {
$mac = Mac::parse($entry['mac_address']);
$response[] = [
- 'mac_address' => $mac->readable(),
- 'mac_oui' => $mac->vendor(),
- 'ipv4_address' => $entry['ipv4_address'],
- 'hostname' => generate_device_link($entry),
- 'interface' => generate_port_link($entry, makeshortif($entry['label'])) . ' ' . $error_img,
- 'remote_device' => $arp_name,
+ 'mac_address' => $mac->readable(),
+ 'mac_oui' => $mac->vendor(),
+ 'ipv4_address' => $entry['ipv4_address'],
+ 'hostname' => generate_device_link($entry),
+ 'interface' => generate_port_link($entry, makeshortif($entry['label'])) . ' ' . $error_img,
+ 'remote_device' => $arp_name,
'remote_interface' => $arp_if,
];
}//end if
@@ -113,9 +113,9 @@ foreach (dbFetchRows($sql, $param) as $entry) {
}//end foreach
$output = [
- 'current' => $current,
+ 'current' => $current,
'rowCount' => $rowCount,
- 'rows' => $response,
- 'total' => $total,
+ 'rows' => $response,
+ 'total' => $total,
];
echo json_encode($output, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
diff --git a/includes/html/table/as-selection.inc.php b/includes/html/table/as-selection.inc.php
index 8e558b8817..cfb44f8c32 100644
--- a/includes/html/table/as-selection.inc.php
+++ b/includes/html/table/as-selection.inc.php
@@ -40,16 +40,16 @@ $sql = "SELECT `bgpLocalAs` $sql";
foreach (dbFetchRows($sql, $param) as $asn) {
$astext = \LibreNMS\Util\AutonomousSystem::get($asn['bgpLocalAs'])->name();
$response[] = [
- 'bgpLocalAs' => $asn['bgpLocalAs'],
+ 'bgpLocalAs' => $asn['bgpLocalAs'],
'asname' => $astext,
'action' => "
'peering', 'section' => 'ix-list', 'bgpLocalAs' => $asn['bgpLocalAs']]) . "' role='button'>Show connected IXes",
];
}
$output = [
- 'current' => $current,
+ 'current' => $current,
'rowCount' => $rowCount,
- 'rows' => $response,
- 'total' => $total,
+ 'rows' => $response,
+ 'total' => $total,
];
echo json_encode($output, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
diff --git a/includes/html/table/bills.inc.php b/includes/html/table/bills.inc.php
index 78eb78b11c..b296cbaad1 100644
--- a/includes/html/table/bills.inc.php
+++ b/includes/html/table/bills.inc.php
@@ -159,19 +159,19 @@ foreach (dbFetchRows($sql, $param) as $bill) {
}
$response[] = [
- 'bill_name' => $bill_name,
- 'notes' => $notes,
- 'bill_type' => $type,
- 'bill_allowed' => $allowed,
+ 'bill_name' => $bill_name,
+ 'notes' => $notes,
+ 'bill_type' => $type,
+ 'bill_allowed' => $allowed,
'total_data_in' => $in,
- 'total_data_out'=> $out,
- 'total_data' => $total_data,
- 'rate_95th' => $rate_95th,
- 'used' => $used,
- 'overusage' => $overuse_formatted,
- 'predicted' => $predicted,
- 'graph' => $bar,
- 'actions' => $actions,
+ 'total_data_out' => $out,
+ 'total_data' => $total_data,
+ 'rate_95th' => $rate_95th,
+ 'used' => $used,
+ 'overusage' => $overuse_formatted,
+ 'predicted' => $predicted,
+ 'graph' => $bar,
+ 'actions' => $actions,
];
}
diff --git a/includes/html/table/component.inc.php b/includes/html/table/component.inc.php
index 6d4b04c11c..8888a46d47 100644
--- a/includes/html/table/component.inc.php
+++ b/includes/html/table/component.inc.php
@@ -60,9 +60,9 @@ foreach ($COMPONENTS[$device_id] as $ID => $AVP) {
}//end foreach
$output = [
- 'current' => $current,
+ 'current' => $current,
'rowCount' => $rowCount,
- 'rows' => $response,
- 'total' => ! empty($COMPONENTS[$device_id]) ? count($COMPONENTS[$device_id]) : 0,
+ 'rows' => $response,
+ 'total' => ! empty($COMPONENTS[$device_id]) ? count($COMPONENTS[$device_id]) : 0,
];
echo json_encode($output, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
diff --git a/includes/html/table/ix-list.inc.php b/includes/html/table/ix-list.inc.php
index 50c8914a21..d5402fb27e 100644
--- a/includes/html/table/ix-list.inc.php
+++ b/includes/html/table/ix-list.inc.php
@@ -58,15 +58,15 @@ foreach (dbFetchRows($sql, $params) as $ix) {
$ix_id = $ix['ix_id'];
$response[] = [
'exchange' => $ix['name'],
- 'action' => "
'peering', 'section' => 'ix-peers', 'asn' => $asn, 'ixid' => $ix['ix_id']]) . "' role='button'>Show Peers",
- 'links' => "
",
+ 'action' => "
'peering', 'section' => 'ix-peers', 'asn' => $asn, 'ixid' => $ix['ix_id']]) . "' role='button'>Show Peers",
+ 'links' => "
",
];
}
$output = [
- 'current' => $current,
+ 'current' => $current,
'rowCount' => $rowCount,
- 'rows' => $response,
- 'total' => $total,
+ 'rows' => $response,
+ 'total' => $total,
];
echo json_encode($output, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
diff --git a/includes/html/table/ix-peers.inc.php b/includes/html/table/ix-peers.inc.php
index a586e455ac..f789e47a67 100644
--- a/includes/html/table/ix-peers.inc.php
+++ b/includes/html/table/ix-peers.inc.php
@@ -75,18 +75,18 @@ foreach (dbFetchRows($sql, $params) as $peer) {
}
$peer_id = $peer['peer_id'];
$response[] = [
- 'remote_asn' => $peer['remote_asn'],
+ 'remote_asn' => $peer['remote_asn'],
'remote_ipaddr4' => $peer['remote_ipaddr4'],
- 'peer' => $peer['name'],
- 'connected' => "$connected",
- 'links' => "
",
+ 'peer' => $peer['name'],
+ 'connected' => "$connected",
+ 'links' => "
",
];
}
$output = [
- 'current' => $current,
+ 'current' => $current,
'rowCount' => $rowCount,
- 'rows' => $response,
- 'total' => $total,
+ 'rows' => $response,
+ 'total' => $total,
];
echo json_encode($output, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
diff --git a/includes/html/table/mempool-edit.inc.php b/includes/html/table/mempool-edit.inc.php
index c1b0108a9d..f99f2dd9af 100644
--- a/includes/html/table/mempool-edit.inc.php
+++ b/includes/html/table/mempool-edit.inc.php
@@ -48,5 +48,5 @@ foreach (dbFetchRows($sql, $param) as $drive) {
'mempool_perc_warn' => $perc_warn, ];
}
-$output = ['current'=>$current, 'rowCount'=>$rowCount, 'rows'=>$response, 'total'=>$total];
+$output = ['current' => $current, 'rowCount' => $rowCount, 'rows' => $response, 'total' => $total];
echo json_encode($output, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
diff --git a/includes/html/table/poll-log.inc.php b/includes/html/table/poll-log.inc.php
index 81d6621159..a5bb1d21f7 100644
--- a/includes/html/table/poll-log.inc.php
+++ b/includes/html/table/poll-log.inc.php
@@ -62,18 +62,18 @@ foreach (dbFetchRows($sql, $param) as $device) {
$device['group_name'] = 'General';
}
$response[] = [
- 'hostname' => generate_device_link($device, null, ['tab' => 'graphs', 'group' => 'poller']),
- 'last_polled' => $device['last_polled'],
- 'poller_group' => $device['group_name'],
- 'location' => $device['location'],
+ 'hostname' => generate_device_link($device, null, ['tab' => 'graphs', 'group' => 'poller']),
+ 'last_polled' => $device['last_polled'],
+ 'poller_group' => $device['group_name'],
+ 'location' => $device['location'],
'last_polled_timetaken' => round($device['last_polled_timetaken'], 2),
];
}
$output = [
- 'current' => $current,
+ 'current' => $current,
'rowCount' => $rowCount,
- 'rows' => $response,
- 'total' => $total,
+ 'rows' => $response,
+ 'total' => $total,
];
echo json_encode($output);
diff --git a/includes/html/table/processor-edit.inc.php b/includes/html/table/processor-edit.inc.php
index edce1f8975..dffbf9cf4e 100644
--- a/includes/html/table/processor-edit.inc.php
+++ b/includes/html/table/processor-edit.inc.php
@@ -48,5 +48,5 @@ foreach (dbFetchRows($sql, $param) as $drive) {
'processor_perc_warn' => $perc_warn, ];
}
-$output = ['current'=>$current, 'rowCount'=>$rowCount, 'rows'=>$response, 'total'=>$total];
+$output = ['current' => $current, 'rowCount' => $rowCount, 'rows' => $response, 'total' => $total];
echo json_encode($output, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
diff --git a/includes/html/table/processor.inc.php b/includes/html/table/processor.inc.php
index 9e522a224e..6de6245289 100644
--- a/includes/html/table/processor.inc.php
+++ b/includes/html/table/processor.inc.php
@@ -71,9 +71,9 @@ foreach (dbFetchRows($sql, $param) as $processor) {
$bar_link = \LibreNMS\Util\Url::overlibLink($link, print_percentage_bar(400, 20, $perc, $perc . '%', 'ffffff', $background['left'], (100 - $perc) . '%', 'ffffff', $background['right']), \LibreNMS\Util\Url::graphTag($graph_array_zoom));
$response[] = [
- 'hostname' => generate_device_link($processor),
+ 'hostname' => generate_device_link($processor),
'processor_descr' => $processor['processor_descr'],
- 'graph' => $mini_graph,
+ 'graph' => $mini_graph,
'processor_usage' => $bar_link,
];
if ($vars['view'] == 'graphs') {
@@ -86,18 +86,18 @@ foreach (dbFetchRows($sql, $param) as $processor) {
include 'includes/html/print-graphrow.inc.php';
unset($return_data);
$response[] = [
- 'hostname' => $graph_data[0],
+ 'hostname' => $graph_data[0],
'processor_descr' => $graph_data[1],
- 'graph' => $graph_data[2],
+ 'graph' => $graph_data[2],
'processor_usage' => $graph_data[3],
];
} //end if
}//end foreach
$output = [
- 'current' => $current,
+ 'current' => $current,
'rowCount' => $rowCount,
- 'rows' => $response,
- 'total' => $total,
+ 'rows' => $response,
+ 'total' => $total,
];
echo json_encode($output, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
diff --git a/includes/html/table/routing-edit.inc.php b/includes/html/table/routing-edit.inc.php
index 0e098904b8..c18f8a9db6 100644
--- a/includes/html/table/routing-edit.inc.php
+++ b/includes/html/table/routing-edit.inc.php
@@ -57,5 +57,5 @@ foreach (dbFetchRows($sql, $param) as $routing) {
'bgpPeerDescr' => $routing['bgpPeerDescr'], ];
}
-$output = ['current'=>$current, 'rowCount'=>$rowCount, 'rows'=>$response, 'total'=>$total];
+$output = ['current' => $current, 'rowCount' => $rowCount, 'rows' => $response, 'total' => $total];
echo json_encode($output, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
diff --git a/includes/html/table/sensors-common.php b/includes/html/table/sensors-common.php
index 9e1b0f8a39..bcd0032d1e 100644
--- a/includes/html/table/sensors-common.php
+++ b/includes/html/table/sensors-common.php
@@ -116,14 +116,14 @@ foreach (dbFetchRows($sql, $param) as $sensor) {
$sensor_current = $graph_type == 'sensor_state' ? get_state_label($sensor) : get_sensor_label_color($sensor, $translations);
$response[] = [
- 'hostname' => generate_device_link($sensor),
- 'sensor_descr' => \LibreNMS\Util\Url::overlibLink($link, $sensor['sensor_descr'], $overlib_content),
- 'graph' => \LibreNMS\Util\Url::overlibLink($link_graph, $sensor_minigraph, $overlib_content),
- 'alert' => $alert,
- 'sensor_current' => $sensor_current,
+ 'hostname' => generate_device_link($sensor),
+ 'sensor_descr' => \LibreNMS\Util\Url::overlibLink($link, $sensor['sensor_descr'], $overlib_content),
+ 'graph' => \LibreNMS\Util\Url::overlibLink($link_graph, $sensor_minigraph, $overlib_content),
+ 'alert' => $alert,
+ 'sensor_current' => $sensor_current,
'sensor_limit_low' => is_null($sensor['sensor_limit_low']) ? '-' :
'
' . trim(\LibreNMS\Util\Number::formatSi($sensor['sensor_limit_low'], 2, 3, '') . $unit) . '',
- 'sensor_limit' => is_null($sensor['sensor_limit']) ? '-' :
+ 'sensor_limit' => is_null($sensor['sensor_limit']) ? '-' :
'
' . trim(\LibreNMS\Util\Number::formatSi($sensor['sensor_limit'], 2, 3, '') . $unit) . '',
];
@@ -141,24 +141,24 @@ foreach (dbFetchRows($sql, $param) as $sensor) {
$yearly_url = 'graph.php?id=' . $sensor['sensor_id'] . '&type=' . $graph_type . '&from=' . Config::get('time.year') . '&to=' . Config::get('time.now') . '&width=400&height=150';
$response[] = [
- 'hostname' => "
', LEFT);\" onmouseout=\"return nd();\">
+ 'hostname' => "', LEFT);\" onmouseout=\"return nd();\">
",
- 'sensor_descr' => "
', LEFT);\" onmouseout=\"return nd();\">
+ 'sensor_descr' => "', LEFT);\" onmouseout=\"return nd();\">
",
- 'graph' => "
', LEFT);\" onmouseout=\"return nd();\">
+ 'graph' => "', LEFT);\" onmouseout=\"return nd();\">
",
- 'alert' => '',
+ 'alert' => '',
'sensor_current' => "
', LEFT);\" onmouseout=\"return nd();\">
",
- 'sensor_range' => '',
+ 'sensor_range' => '',
];
} //end if
}//end foreach
$output = [
- 'current' => $current,
+ 'current' => $current,
'rowCount' => $rowCount,
- 'rows' => $response,
- 'total' => $count,
+ 'rows' => $response,
+ 'total' => $count,
];
echo json_encode($output, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
diff --git a/includes/html/table/storage-edit.inc.php b/includes/html/table/storage-edit.inc.php
index a317b0f504..21bad15298 100644
--- a/includes/html/table/storage-edit.inc.php
+++ b/includes/html/table/storage-edit.inc.php
@@ -52,5 +52,5 @@ foreach (dbFetchRows($sql, $param) as $drive) {
];
}
-$output = ['current'=>$current, 'rowCount'=>$rowCount, 'rows'=>$response, 'total'=>$total];
+$output = ['current' => $current, 'rowCount' => $rowCount, 'rows' => $response, 'total' => $total];
echo json_encode($output, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
diff --git a/includes/html/table/storage.inc.php b/includes/html/table/storage.inc.php
index 9a6d33df2b..4dcea49bab 100644
--- a/includes/html/table/storage.inc.php
+++ b/includes/html/table/storage.inc.php
@@ -83,11 +83,11 @@ foreach (dbFetchRows($sql, $param) as $drive) {
$bar_link = \LibreNMS\Util\Url::overlibLink($link, print_percentage_bar(400, 20, $perc, "$used / $total", 'ffffff', $background['left'], $free, 'ffffff', $background['right']), \LibreNMS\Util\Url::graphTag($graph_array_zoom));
$response[] = [
- 'hostname' => generate_device_link($drive),
+ 'hostname' => generate_device_link($drive),
'storage_descr' => $drive['storage_descr'],
- 'graph' => $mini_graph,
- 'storage_used' => $bar_link,
- 'storage_perc' => $perc . '%',
+ 'graph' => $mini_graph,
+ 'storage_used' => $bar_link,
+ 'storage_perc' => $perc . '%',
];
if ($vars['view'] == 'graphs') {
$graph_array['height'] = '100';
@@ -100,19 +100,19 @@ foreach (dbFetchRows($sql, $param) as $drive) {
include 'includes/html/print-graphrow.inc.php';
unset($return_data);
$response[] = [
- 'hostname' => $graph_data[0],
+ 'hostname' => $graph_data[0],
'storage_descr' => $graph_data[1],
- 'graph' => $graph_data[2],
- 'storage_used' => $graph_data[3],
- 'storage_perc' => '',
+ 'graph' => $graph_data[2],
+ 'storage_used' => $graph_data[3],
+ 'storage_perc' => '',
];
} //end if
}//end foreach
$output = [
- 'current' => $current,
+ 'current' => $current,
'rowCount' => $rowCount,
- 'rows' => $response,
- 'total' => $count,
+ 'rows' => $response,
+ 'total' => $count,
];
echo json_encode($output, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
diff --git a/includes/html/table/toner.inc.php b/includes/html/table/toner.inc.php
index 2e310be65f..e1cbcc6520 100644
--- a/includes/html/table/toner.inc.php
+++ b/includes/html/table/toner.inc.php
@@ -92,20 +92,20 @@ foreach (dbFetchRows($sql, $param) as $toner) {
include 'includes/html/print-graphrow.inc.php';
unset($return_data);
$response[] = [
- 'hostname' => $graph_data[0],
+ 'hostname' => $graph_data[0],
'mempool_descr' => $graph_data[1],
- 'graph' => $graph_data[2],
- 'mempool_used' => $graph_data[3],
- 'mempool_perc' => '',
+ 'graph' => $graph_data[2],
+ 'mempool_used' => $graph_data[3],
+ 'mempool_perc' => '',
];
}
}
}
$output = [
- 'current' => $current,
+ 'current' => $current,
'rowCount' => $rowCount,
- 'rows' => $response,
- 'total' => $count,
+ 'rows' => $response,
+ 'total' => $count,
];
echo json_encode($output, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
diff --git a/includes/polling/applications/apache.inc.php b/includes/polling/applications/apache.inc.php
index 2fd204441c..93c983d298 100644
--- a/includes/polling/applications/apache.inc.php
+++ b/includes/polling/applications/apache.inc.php
@@ -48,26 +48,26 @@ $rrd_def = RrdDefinition::make()
->addDataset('sb_open', 'GAUGE', 0, 125000000000);
$fields = [
- 'access' => intval(trim($total_access, '"')),
- 'kbyte' => $total_kbyte,
- 'cpu' => $cpuload,
- 'uptime' => $uptime,
- 'reqpersec' => $reqpersec,
- 'bytespersec' => $bytespersec,
- 'byesperreq' => $bytesperreq,
- 'busyworkers' => $busyworkers,
- 'idleworkers' => $idleworkers,
- 'sb_wait' => $score_wait,
- 'sb_start' => $score_start,
- 'sb_reading' => $score_reading,
- 'sb_writing' => $score_writing,
+ 'access' => intval(trim($total_access, '"')),
+ 'kbyte' => $total_kbyte,
+ 'cpu' => $cpuload,
+ 'uptime' => $uptime,
+ 'reqpersec' => $reqpersec,
+ 'bytespersec' => $bytespersec,
+ 'byesperreq' => $bytesperreq,
+ 'busyworkers' => $busyworkers,
+ 'idleworkers' => $idleworkers,
+ 'sb_wait' => $score_wait,
+ 'sb_start' => $score_start,
+ 'sb_reading' => $score_reading,
+ 'sb_writing' => $score_writing,
'sb_keepalive' => $score_keepalive,
- 'sb_dns' => $score_dns,
- 'sb_closing' => $score_closing,
- 'sb_logging' => $score_logging,
- 'sb_graceful' => $score_graceful,
- 'sb_idle' => $score_idle,
- 'sb_open' => intval(trim($score_open, '"')),
+ 'sb_dns' => $score_dns,
+ 'sb_closing' => $score_closing,
+ 'sb_logging' => $score_logging,
+ 'sb_graceful' => $score_graceful,
+ 'sb_idle' => $score_idle,
+ 'sb_open' => intval(trim($score_open, '"')),
];
$tags = [
diff --git a/includes/polling/applications/backupninja.inc.php b/includes/polling/applications/backupninja.inc.php
index 6fc675506d..5974003042 100644
--- a/includes/polling/applications/backupninja.inc.php
+++ b/includes/polling/applications/backupninja.inc.php
@@ -30,10 +30,10 @@ $rrd_def = RrdDefinition::make()
->addDataset('last_warning', 'GAUGE', 0);
$fields = [
- 'last_actions' => $backupninja_data['last_actions'],
- 'last_fatal' => $backupninja_data['last_fatal'],
- 'last_error' => $backupninja_data['last_error'],
- 'last_warning' => $backupninja_data['last_warning'],
+ 'last_actions' => $backupninja_data['last_actions'],
+ 'last_fatal' => $backupninja_data['last_fatal'],
+ 'last_error' => $backupninja_data['last_error'],
+ 'last_warning' => $backupninja_data['last_warning'],
];
$metrics[$category] = $fields;
diff --git a/includes/polling/applications/bind.inc.php b/includes/polling/applications/bind.inc.php
index 5dc0bb16e8..05df1942b7 100644
--- a/includes/polling/applications/bind.inc.php
+++ b/includes/polling/applications/bind.inc.php
@@ -44,16 +44,16 @@ $rrd_def = RrdDefinition::make()
->addDataset('spf', 'DERIVE', 0);
$fields = [
- 'any' => $any,
- 'a' => $a,
- 'aaaa' => $aaaa,
+ 'any' => $any,
+ 'a' => $a,
+ 'aaaa' => $aaaa,
'cname' => $cname,
- 'mx' => $mx,
- 'ns' => $ns,
- 'ptr' => $ptr,
- 'soa' => $soa,
- 'srv' => $srv,
- 'spf' => $spf,
+ 'mx' => $mx,
+ 'ns' => $ns,
+ 'ptr' => $ptr,
+ 'soa' => $soa,
+ 'srv' => $srv,
+ 'spf' => $spf,
];
$metrics['queries'] = $fields;
@@ -187,16 +187,16 @@ $rrd_def = RrdDefinition::make()
->addDataset('opt', 'DERIVE', 0);
$fields = [
- 'any' => $any,
- 'a' => $a,
- 'aaaa' => $aaaa,
+ 'any' => $any,
+ 'a' => $a,
+ 'aaaa' => $aaaa,
'cname' => $cname,
- 'mx' => $mx,
- 'ns' => $ns,
- 'ptr' => $ptr,
- 'soa' => $soa,
- 'srv' => $srv,
- 'spf' => $spf,
+ 'mx' => $mx,
+ 'ns' => $ns,
+ 'ptr' => $ptr,
+ 'soa' => $soa,
+ 'srv' => $srv,
+ 'spf' => $spf,
'afsdb' => $afsdb,
'apl' => $apl,
'caa' => $caa,
@@ -580,16 +580,16 @@ $rrd_def = RrdDefinition::make()
$rrd_name = ['app', $name, $app->app_id, 'rrpositive'];
$fields = [
- 'any' => $any,
- 'a' => $a,
- 'aaaa' => $aaaa,
+ 'any' => $any,
+ 'a' => $a,
+ 'aaaa' => $aaaa,
'cname' => $cname,
- 'mx' => $mx,
- 'ns' => $ns,
- 'ptr' => $ptr,
- 'soa' => $soa,
- 'srv' => $srv,
- 'spf' => $spf,
+ 'mx' => $mx,
+ 'ns' => $ns,
+ 'ptr' => $ptr,
+ 'soa' => $soa,
+ 'srv' => $srv,
+ 'spf' => $spf,
'afsdb' => $afsdb,
'apl' => $apl,
'caa' => $caa,
@@ -633,16 +633,16 @@ data_update($device, 'app', $tags, $fields);
$rrd_name = ['app', $name, $app->app_id, 'rrnegative'];
$fields = [
- 'any' => $notany,
- 'a' => $nota,
- 'aaaa' => $notaaaa,
+ 'any' => $notany,
+ 'a' => $nota,
+ 'aaaa' => $notaaaa,
'cname' => $notcname,
- 'mx' => $notmx,
- 'ns' => $notns,
- 'ptr' => $notptr,
- 'soa' => $notsoa,
- 'srv' => $notsrv,
- 'spf' => $notspf,
+ 'mx' => $notmx,
+ 'ns' => $notns,
+ 'ptr' => $notptr,
+ 'soa' => $notsoa,
+ 'srv' => $notsrv,
+ 'spf' => $notspf,
'afsdb' => $notafsdb,
'apl' => $notapl,
'caa' => $notcaa,
@@ -672,7 +672,7 @@ $fields = [
'txt' => $nottxt,
'uri' => $noturi,
'dname' => $notdname,
- 'nxdomain'=> $notnxdomain,
+ 'nxdomain' => $notnxdomain,
'axfr' => $notaxfr,
'ixfr' => $notixfr,
'opt' => $notopt,
diff --git a/includes/polling/applications/certificate.inc.php b/includes/polling/applications/certificate.inc.php
index 54ea3528b8..3b788a78b4 100644
--- a/includes/polling/applications/certificate.inc.php
+++ b/includes/polling/applications/certificate.inc.php
@@ -32,7 +32,7 @@ foreach ($certificate_data as $data) {
$rrd_name = ['app', $name, $app->app_id, $cert_name];
$fields = [
- 'age' => $age,
+ 'age' => $age,
'remaining_days' => $remaining_days,
];
diff --git a/includes/polling/applications/chronyd.inc.php b/includes/polling/applications/chronyd.inc.php
index 5c6e1b1253..232b53bf2b 100644
--- a/includes/polling/applications/chronyd.inc.php
+++ b/includes/polling/applications/chronyd.inc.php
@@ -28,17 +28,17 @@ $rrd_def = RrdDefinition::make()
->addDataset('update_interval', 'GAUGE', 0, 4096); // good for >1h
$fields = [
- 'stratum' => $chronyd['tracking']['stratum'],
- 'reference_time' => $chronyd['tracking']['reference_time'],
- 'system_time' => $chronyd['tracking']['system_time'],
- 'last_offset' => $chronyd['tracking']['last_offset'],
- 'rms_offset' => $chronyd['tracking']['rms_offset'],
- 'frequency' => $chronyd['tracking']['frequency'],
- 'residual_frequency' => $chronyd['tracking']['residual_frequency'],
- 'skew' => $chronyd['tracking']['skew'],
- 'root_delay' => $chronyd['tracking']['root_delay'],
- 'root_dispersion' => $chronyd['tracking']['root_dispersion'],
- 'update_interval' => $chronyd['tracking']['update_interval'],
+ 'stratum' => $chronyd['tracking']['stratum'],
+ 'reference_time' => $chronyd['tracking']['reference_time'],
+ 'system_time' => $chronyd['tracking']['system_time'],
+ 'last_offset' => $chronyd['tracking']['last_offset'],
+ 'rms_offset' => $chronyd['tracking']['rms_offset'],
+ 'frequency' => $chronyd['tracking']['frequency'],
+ 'residual_frequency' => $chronyd['tracking']['residual_frequency'],
+ 'skew' => $chronyd['tracking']['skew'],
+ 'root_delay' => $chronyd['tracking']['root_delay'],
+ 'root_dispersion' => $chronyd['tracking']['root_dispersion'],
+ 'update_interval' => $chronyd['tracking']['update_interval'],
];
$tags = ['name' => $name, 'app_id' => $app->app_id, 'rrd_def' => $rrd_def, 'rrd_name' => $rrd_name];
@@ -69,19 +69,19 @@ foreach ($chronyd['sources'] as $source) {
$sources[] = $source['source_name'];
$rrd_name = ['app', $name, $app->app_id, $source['source_name']];
$fields = [
- 'stratum' => $source['stratum'],
- 'polling_rate' => $source['polling_rate'],
- 'last_rx' => $source['last_rx'],
- 'adjusted_offset' => $source['adjusted_offset'],
- 'measured_offset' => $source['measured_offset'],
- 'estimated_error' => $source['estimated_error'],
- 'number_samplepoints' => $source['number_samplepoints'],
- 'number_runs' => $source['number_runs'],
- 'span' => $source['span'],
- 'frequency' => $source['frequency'],
- 'frequency_skew' => $source['frequency_skew'],
- 'offset' => $source['offset'],
- 'stddev' => $source['stddev'],
+ 'stratum' => $source['stratum'],
+ 'polling_rate' => $source['polling_rate'],
+ 'last_rx' => $source['last_rx'],
+ 'adjusted_offset' => $source['adjusted_offset'],
+ 'measured_offset' => $source['measured_offset'],
+ 'estimated_error' => $source['estimated_error'],
+ 'number_samplepoints' => $source['number_samplepoints'],
+ 'number_runs' => $source['number_runs'],
+ 'span' => $source['span'],
+ 'frequency' => $source['frequency'],
+ 'frequency_skew' => $source['frequency_skew'],
+ 'offset' => $source['offset'],
+ 'stddev' => $source['stddev'],
];
$tags = ['name' => $name, 'app_id' => $app->app_id, 'rrd_def' => $source_rrd_def, 'rrd_name' => $rrd_name];
diff --git a/includes/polling/applications/dhcp-stats.inc.php b/includes/polling/applications/dhcp-stats.inc.php
index 7f870c5eab..a59d564ba4 100644
--- a/includes/polling/applications/dhcp-stats.inc.php
+++ b/includes/polling/applications/dhcp-stats.inc.php
@@ -65,15 +65,15 @@ $rrd_def = RrdDefinition::make()
->addDataset('dhcp_free', 'GAUGE', 0);
$fields = [
- 'dhcp_total' => $dhcp_total,
- 'dhcp_active' => $dhcp_active,
- 'dhcp_expired' => $dhcp_expired,
- 'dhcp_released' => $dhcp_released,
+ 'dhcp_total' => $dhcp_total,
+ 'dhcp_active' => $dhcp_active,
+ 'dhcp_expired' => $dhcp_expired,
+ 'dhcp_released' => $dhcp_released,
'dhcp_abandoned' => $dhcp_abandoned,
- 'dhcp_reset' => $dhcp_reset,
- 'dhcp_bootp' => $dhcp_bootp,
- 'dhcp_backup' => $dhcp_backup,
- 'dhcp_free' => $dhcp_free,
+ 'dhcp_reset' => $dhcp_reset,
+ 'dhcp_bootp' => $dhcp_bootp,
+ 'dhcp_backup' => $dhcp_backup,
+ 'dhcp_free' => $dhcp_free,
];
$metrics[$name . '_' . $category] = $fields;
@@ -99,7 +99,7 @@ if ($version == 2) {
$fields = [
'current' => $dhcp_current,
- 'max' => $dhcp_max,
+ 'max' => $dhcp_max,
'percent' => $dhcp_percent,
];
@@ -126,7 +126,7 @@ if ($version == 2) {
$fields = [
'current' => $dhcp_current,
- 'max' => $dhcp_max,
+ 'max' => $dhcp_max,
'percent' => $dhcp_percent,
];
diff --git a/includes/polling/applications/drbd.inc.php b/includes/polling/applications/drbd.inc.php
index 0f3f239835..007e0d7ab2 100644
--- a/includes/polling/applications/drbd.inc.php
+++ b/includes/polling/applications/drbd.inc.php
@@ -26,16 +26,16 @@ $rrd_def = RrdDefinition::make()
->addDataset('oos', 'GAUGE', 0, 125000000000);
$fields = [
- 'ns' => $drbd['ns'],
- 'nr' => $drbd['nr'],
- 'dw' => $drbd['dw'],
- 'dr' => $drbd['dr'],
- 'al' => $drbd['al'],
- 'bm' => $drbd['bm'],
- 'lo' => $drbd['lo'],
- 'pe' => $drbd['pe'],
- 'ua' => $drbd['ua'],
- 'ap' => $drbd['ap'],
+ 'ns' => $drbd['ns'],
+ 'nr' => $drbd['nr'],
+ 'dw' => $drbd['dw'],
+ 'dr' => $drbd['dr'],
+ 'al' => $drbd['al'],
+ 'bm' => $drbd['bm'],
+ 'lo' => $drbd['lo'],
+ 'pe' => $drbd['pe'],
+ 'ua' => $drbd['ua'],
+ 'ap' => $drbd['ap'],
'oos' => $drbd['oos'],
];
diff --git a/includes/polling/applications/logsize.inc.php b/includes/polling/applications/logsize.inc.php
index e4264ce5c5..9b19255cfb 100644
--- a/includes/polling/applications/logsize.inc.php
+++ b/includes/polling/applications/logsize.inc.php
@@ -28,7 +28,7 @@ $set_rrd_def = RrdDefinition::make()
->addDataset('min_size', 'GAUGE')
->addDataset('size', 'GAUGE');
-$app_data = ['sets'=>[], 'no_minus_d'=>$data['no_minus_d']];
+$app_data = ['sets' => [], 'no_minus_d' => $data['no_minus_d']];
$rrd_name = ['app', $name, $app->app_id];
$fields = [
diff --git a/includes/polling/applications/mailscanner.inc.php b/includes/polling/applications/mailscanner.inc.php
index f83f1cc696..504247765d 100644
--- a/includes/polling/applications/mailscanner.inc.php
+++ b/includes/polling/applications/mailscanner.inc.php
@@ -22,13 +22,13 @@ $rrd_def = RrdDefinition::make()
->addDataset('virus', 'COUNTER', 0, 125000000000);
$fields = [
- 'msg_recv' => $msg_recv,
+ 'msg_recv' => $msg_recv,
'msg_rejected' => $msg_rejected,
- 'msg_relay' => $msg_relay,
- 'msg_sent' => $msg_sent,
- 'msg_waiting' => $msg_waiting,
- 'spam' => $spam,
- 'virus' => $virus,
+ 'msg_relay' => $msg_relay,
+ 'msg_sent' => $msg_sent,
+ 'msg_waiting' => $msg_waiting,
+ 'spam' => $spam,
+ 'virus' => $virus,
];
$tags = [
diff --git a/includes/polling/applications/mdadm.inc.php b/includes/polling/applications/mdadm.inc.php
index 5fa8b0cd3f..4331cf4199 100644
--- a/includes/polling/applications/mdadm.inc.php
+++ b/includes/polling/applications/mdadm.inc.php
@@ -46,12 +46,12 @@ foreach ($mdadm_data as $data) {
$array_level = str_replace('raid', '', $level);
$fields = [
- 'level' => $array_level,
- 'size' => $size,
- 'disc_count' => $disc_count,
+ 'level' => $array_level,
+ 'size' => $size,
+ 'disc_count' => $disc_count,
'hotspare_count' => $hotspare_count,
- 'degraded' => $degraded,
- 'sync_speed' => $sync_speed,
+ 'degraded' => $degraded,
+ 'sync_speed' => $sync_speed,
'sync_completed' => $sync_completed,
];
diff --git a/includes/polling/applications/memcached.inc.php b/includes/polling/applications/memcached.inc.php
index 02b7dfb613..fb42e221ae 100644
--- a/includes/polling/applications/memcached.inc.php
+++ b/includes/polling/applications/memcached.inc.php
@@ -43,24 +43,24 @@ $rrd_def = RrdDefinition::make()
->addDataset('bytes_written', 'DERIVE', 0, 125000000000);
$fields = [
- 'uptime' => $data['uptime'] ?? null,
- 'threads' => $data['threads'] ?? null,
- 'rusage_user_ms' => $data['rusage_user_microseconds'] ?? null,
- 'rusage_system_ms' => $data['rusage_system_microseconds'] ?? null,
- 'curr_items' => $data['curr_items'] ?? null,
- 'total_items' => $data['total_items'] ?? null,
- 'limit_maxbytes' => $data['limit_maxbytes'] ?? null,
- 'curr_connections' => $data['curr_connections'] ?? null,
+ 'uptime' => $data['uptime'] ?? null,
+ 'threads' => $data['threads'] ?? null,
+ 'rusage_user_ms' => $data['rusage_user_microseconds'] ?? null,
+ 'rusage_system_ms' => $data['rusage_system_microseconds'] ?? null,
+ 'curr_items' => $data['curr_items'] ?? null,
+ 'total_items' => $data['total_items'] ?? null,
+ 'limit_maxbytes' => $data['limit_maxbytes'] ?? null,
+ 'curr_connections' => $data['curr_connections'] ?? null,
'total_connections' => $data['total_connections'] ?? null,
- 'conn_structures' => $data['connection_structures'] ?? null,
- 'bytes' => $data['bytes'] ?? null,
- 'cmd_get' => $data['cmd_get'] ?? null,
- 'cmd_set' => $data['cmd_set'] ?? null,
- 'get_hits' => $data['get_hits'] ?? null,
- 'get_misses' => $data['get_misses'] ?? null,
- 'evictions' => $data['evictions'] ?? null,
- 'bytes_read' => $data['bytes_read'] ?? null,
- 'bytes_written' => $data['bytes_written'] ?? null,
+ 'conn_structures' => $data['connection_structures'] ?? null,
+ 'bytes' => $data['bytes'] ?? null,
+ 'cmd_get' => $data['cmd_get'] ?? null,
+ 'cmd_set' => $data['cmd_set'] ?? null,
+ 'get_hits' => $data['get_hits'] ?? null,
+ 'get_misses' => $data['get_misses'] ?? null,
+ 'evictions' => $data['evictions'] ?? null,
+ 'bytes_read' => $data['bytes_read'] ?? null,
+ 'bytes_written' => $data['bytes_written'] ?? null,
];
$tags = [
diff --git a/includes/polling/applications/mysql.inc.php b/includes/polling/applications/mysql.inc.php
index fe03a9976d..aa6d87f801 100644
--- a/includes/polling/applications/mysql.inc.php
+++ b/includes/polling/applications/mysql.inc.php
@@ -17,85 +17,85 @@ $metrics = [];
// General Stats
$mapping = [
'IDBLBSe' => 'cr',
- 'IBLFh' => 'ct',
- 'IBLWn' => 'cu',
- 'SRows' => 'ck',
- 'SRange' => 'cj',
- 'SMPs' => 'ci',
- 'SScan' => 'cl',
- 'IBIRd' => 'ai',
- 'IBIWr' => 'aj',
- 'IBILg' => 'ak',
- 'IBIFSc' => 'ah',
- 'IDBRDd' => 'b2',
- 'IDBRId' => 'b0',
- 'IDBRRd' => 'b3',
- 'IDBRUd' => 'b1',
- 'IBRd' => 'ae',
- 'IBCd' => 'af',
- 'IBWr' => 'ag',
- 'TLIe' => 'b5',
- 'TLWd' => 'b4',
- 'IBPse' => 'aa',
- 'IBPDBp' => 'ac',
- 'IBPFe' => 'ab',
- 'IBPMps' => 'ad',
- 'TOC' => 'bc',
- 'OFs' => 'b7',
- 'OTs' => 'b8',
- 'OdTs' => 'b9',
- 'IBSRs' => 'ay',
- 'IBSWs' => 'ax',
- 'IBOWs' => 'az',
- 'QCs' => 'c1',
- 'QCeFy' => 'bu',
- 'MaCs' => 'bl',
- 'MUCs' => 'bf',
- 'ACs' => 'bd',
- 'AdCs' => 'be',
- 'TCd' => 'bi',
- 'Cs' => 'bn',
- 'IBTNx' => 'a5',
- 'KRRs' => 'a0',
- 'KRs' => 'a1',
- 'KWR' => 'a2',
- 'KWs' => 'a3',
- 'QCQICe' => 'bz',
- 'QCHs' => 'bv',
- 'QCIs' => 'bw',
- 'QCNCd' => 'by',
- 'QCLMPs' => 'bx',
+ 'IBLFh' => 'ct',
+ 'IBLWn' => 'cu',
+ 'SRows' => 'ck',
+ 'SRange' => 'cj',
+ 'SMPs' => 'ci',
+ 'SScan' => 'cl',
+ 'IBIRd' => 'ai',
+ 'IBIWr' => 'aj',
+ 'IBILg' => 'ak',
+ 'IBIFSc' => 'ah',
+ 'IDBRDd' => 'b2',
+ 'IDBRId' => 'b0',
+ 'IDBRRd' => 'b3',
+ 'IDBRUd' => 'b1',
+ 'IBRd' => 'ae',
+ 'IBCd' => 'af',
+ 'IBWr' => 'ag',
+ 'TLIe' => 'b5',
+ 'TLWd' => 'b4',
+ 'IBPse' => 'aa',
+ 'IBPDBp' => 'ac',
+ 'IBPFe' => 'ab',
+ 'IBPMps' => 'ad',
+ 'TOC' => 'bc',
+ 'OFs' => 'b7',
+ 'OTs' => 'b8',
+ 'OdTs' => 'b9',
+ 'IBSRs' => 'ay',
+ 'IBSWs' => 'ax',
+ 'IBOWs' => 'az',
+ 'QCs' => 'c1',
+ 'QCeFy' => 'bu',
+ 'MaCs' => 'bl',
+ 'MUCs' => 'bf',
+ 'ACs' => 'bd',
+ 'AdCs' => 'be',
+ 'TCd' => 'bi',
+ 'Cs' => 'bn',
+ 'IBTNx' => 'a5',
+ 'KRRs' => 'a0',
+ 'KRs' => 'a1',
+ 'KWR' => 'a2',
+ 'KWs' => 'a3',
+ 'QCQICe' => 'bz',
+ 'QCHs' => 'bv',
+ 'QCIs' => 'bw',
+ 'QCNCd' => 'by',
+ 'QCLMPs' => 'bx',
'CTMPDTs' => 'cn',
- 'CTMPTs' => 'cm',
- 'CTMPFs' => 'co',
- 'IBIIs' => 'au',
- 'IBIMRd' => 'av',
- 'IBIMs' => 'aw',
- 'IBILog' => 'al',
- 'IBISc' => 'am',
- 'IBIFLg' => 'an',
- 'IBFBl' => 'aq',
- 'IBIIAo' => 'ap',
- 'IBIAd' => 'as',
- 'IBIAe' => 'at',
- 'SFJn' => 'cd',
- 'SFRJn' => 'ce',
- 'SRe' => 'cf',
- 'SRCk' => 'cg',
- 'SSn' => 'ch',
- 'SQs' => 'b6',
- 'BRd' => 'cq',
- 'BSt' => 'cp',
- 'CDe' => 'c6',
- 'CIt' => 'c4',
- 'CISt' => 'ca',
- 'CLd' => 'c8',
- 'CRe' => 'c7',
- 'CRSt' => 'cc',
- 'CSt' => 'c5',
- 'CUe' => 'c3',
- 'CUMi' => 'c9',
- 'SlLa' => 'br',
+ 'CTMPTs' => 'cm',
+ 'CTMPFs' => 'co',
+ 'IBIIs' => 'au',
+ 'IBIMRd' => 'av',
+ 'IBIMs' => 'aw',
+ 'IBILog' => 'al',
+ 'IBISc' => 'am',
+ 'IBIFLg' => 'an',
+ 'IBFBl' => 'aq',
+ 'IBIIAo' => 'ap',
+ 'IBIAd' => 'as',
+ 'IBIAe' => 'at',
+ 'SFJn' => 'cd',
+ 'SFRJn' => 'ce',
+ 'SRe' => 'cf',
+ 'SRCk' => 'cg',
+ 'SSn' => 'ch',
+ 'SQs' => 'b6',
+ 'BRd' => 'cq',
+ 'BSt' => 'cp',
+ 'CDe' => 'c6',
+ 'CIt' => 'c4',
+ 'CISt' => 'ca',
+ 'CLd' => 'c8',
+ 'CRe' => 'c7',
+ 'CRSt' => 'cc',
+ 'CSt' => 'c5',
+ 'CUe' => 'c3',
+ 'CUMi' => 'c9',
+ 'SlLa' => 'br',
];
$data = explode("\n", $mysql);
@@ -211,22 +211,22 @@ data_update($device, 'app', $tags, $fields);
// Process state statistics
$mapping_status = [
- 'State_closing_tables' => 'd2',
+ 'State_closing_tables' => 'd2',
'State_copying_to_tmp_table' => 'd3',
- 'State_end' => 'd4',
- 'State_freeing_items' => 'd5',
- 'State_init' => 'd6',
- 'State_locked' => 'd7',
- 'State_login' => 'd8',
- 'State_preparing' => 'd9',
- 'State_reading_from_net' => 'da',
- 'State_sending_data' => 'db',
- 'State_sorting_result' => 'dc',
- 'State_statistics' => 'dd',
- 'State_updating' => 'de',
- 'State_writing_to_net' => 'df',
- 'State_none' => 'dg',
- 'State_other' => 'dh',
+ 'State_end' => 'd4',
+ 'State_freeing_items' => 'd5',
+ 'State_init' => 'd6',
+ 'State_locked' => 'd7',
+ 'State_login' => 'd8',
+ 'State_preparing' => 'd9',
+ 'State_reading_from_net' => 'da',
+ 'State_sending_data' => 'db',
+ 'State_sorting_result' => 'dc',
+ 'State_statistics' => 'dd',
+ 'State_updating' => 'de',
+ 'State_writing_to_net' => 'df',
+ 'State_none' => 'dg',
+ 'State_other' => 'dh',
];
$rrd_def = new RrdDefinition();
diff --git a/includes/polling/applications/nginx.inc.php b/includes/polling/applications/nginx.inc.php
index c675e8bf7f..eb03a3a674 100644
--- a/includes/polling/applications/nginx.inc.php
+++ b/includes/polling/applications/nginx.inc.php
@@ -29,10 +29,10 @@ $rrd_def = RrdDefinition::make()
$fields = [
'Requests' => $req,
- 'Active' => $active,
- 'Reading' => $reading,
- 'Writing' => $writing,
- 'Waiting' => $waiting,
+ 'Active' => $active,
+ 'Reading' => $reading,
+ 'Writing' => $writing,
+ 'Waiting' => $waiting,
];
$tags = [
diff --git a/includes/polling/applications/ntp-server.inc.php b/includes/polling/applications/ntp-server.inc.php
index 809b35d8da..f16445507a 100644
--- a/includes/polling/applications/ntp-server.inc.php
+++ b/includes/polling/applications/ntp-server.inc.php
@@ -44,20 +44,20 @@ $rrd_def = RrdDefinition::make()
->addDataset('packets_sent', 'DERIVE', 0, 125000000000);
$fields = [
- 'stratum' => $ntp['data']['stratum'],
- 'offset' => $ntp['data']['offset'],
- 'frequency' => $ntp['data']['frequency'],
- 'jitter' => $ntp['data']['sys_jitter'],
- 'noise' => $ntp['data']['clk_jitter'],
- 'stability' => $ntp['data']['clk_wander'],
- 'uptime' => $ntp['data']['time_since_reset'],
- 'buffer_recv' => $ntp['data']['receive_buffers'],
- 'buffer_free' => $ntp['data']['free_receive_buffers'],
- 'buffer_used' => $ntp['data']['used_receive_buffers'],
- 'packets_drop' => $ntp['data']['dropped_packets'],
+ 'stratum' => $ntp['data']['stratum'],
+ 'offset' => $ntp['data']['offset'],
+ 'frequency' => $ntp['data']['frequency'],
+ 'jitter' => $ntp['data']['sys_jitter'],
+ 'noise' => $ntp['data']['clk_jitter'],
+ 'stability' => $ntp['data']['clk_wander'],
+ 'uptime' => $ntp['data']['time_since_reset'],
+ 'buffer_recv' => $ntp['data']['receive_buffers'],
+ 'buffer_free' => $ntp['data']['free_receive_buffers'],
+ 'buffer_used' => $ntp['data']['used_receive_buffers'],
+ 'packets_drop' => $ntp['data']['dropped_packets'],
'packets_ignore' => $ntp['data']['ignored_packets'],
- 'packets_recv' => $ntp['data']['received_packets'],
- 'packets_sent' => $ntp['data']['packets_sent'],
+ 'packets_recv' => $ntp['data']['received_packets'],
+ 'packets_sent' => $ntp['data']['packets_sent'],
];
$tags = [
diff --git a/includes/polling/applications/postfix.inc.php b/includes/polling/applications/postfix.inc.php
index 027bbc8561..d014e45f75 100644
--- a/includes/polling/applications/postfix.inc.php
+++ b/includes/polling/applications/postfix.inc.php
@@ -72,7 +72,7 @@ $fields = [
'senders' => $senders,
'sendinghd' => $sendinghd,
'recipients' => $recipients,
- 'recipienthd'=> $recipienthd,
+ 'recipienthd' => $recipienthd,
'deferralcr' => $deferralcr,
'deferralhid' => $deferralhid,
'chr' => $chr,
diff --git a/includes/polling/applications/powermon.inc.php b/includes/polling/applications/powermon.inc.php
index 163d45fe6b..2f0d94fd25 100644
--- a/includes/polling/applications/powermon.inc.php
+++ b/includes/polling/applications/powermon.inc.php
@@ -40,9 +40,9 @@ $rrd_def = RrdDefinition::make()
->addDataset('rate', 'GAUGE', 0);
$fields = [
- 'watts-gauge' => $result['data']['reading'],
- 'watts-abs' => $result['data']['reading'],
- 'rate' => $result['data']['supply']['rate'],
+ 'watts-gauge' => $result['data']['reading'],
+ 'watts-abs' => $result['data']['reading'],
+ 'rate' => $result['data']['supply']['rate'],
];
/*
diff --git a/includes/polling/applications/pwrstatd.inc.php b/includes/polling/applications/pwrstatd.inc.php
index 9d3aaec71e..0f52bccc9e 100644
--- a/includes/polling/applications/pwrstatd.inc.php
+++ b/includes/polling/applications/pwrstatd.inc.php
@@ -51,14 +51,14 @@ foreach ($pwrstatd_data as $data) {
$rrd_name = ['app', $name, $app->app_id, $sn];
$fields = [
- 'mruntime' => $mruntime,
+ 'mruntime' => $mruntime,
'pcapacity' => $pcapacity,
- 'pload' => $pload,
- 'voutput' => $voutput,
- 'vrating' => $vrating,
- 'vutility' => $vutility,
- 'wload' => $wload,
- 'wrating' => $wrating,
+ 'pload' => $pload,
+ 'voutput' => $voutput,
+ 'vrating' => $vrating,
+ 'vutility' => $vutility,
+ 'wload' => $wload,
+ 'wrating' => $wrating,
];
$metrics[$sn] = $fields;
diff --git a/includes/polling/applications/redis.inc.php b/includes/polling/applications/redis.inc.php
index d4e522d0c9..ab04adcfa4 100644
--- a/includes/polling/applications/redis.inc.php
+++ b/includes/polling/applications/redis.inc.php
@@ -36,7 +36,7 @@ $metrics = [];
$category = 'clients';
$fields = [
'connected' => $client_data['connected_clients'],
- 'blocked' => $client_data['blocked_clients'],
+ 'blocked' => $client_data['blocked_clients'],
];
$rrd_def = RrdDefinition::make()
->addDataset('connected', 'GAUGE', 0)
@@ -50,10 +50,10 @@ data_update($device, 'app', $tags, $fields);
$category = 'memory';
$fields = [
'active' => $memory_data['allocator'],
- 'allocated' => $memory_data['allocator_allocated'],
- 'resident' => $memory_data['allocator_resident'],
- 'frag_bytes' => $memory_data['allocator_frag_bytes'],
- 'rss_bytes' => $memory_data['allocator_rss_bytes'],
+ 'allocated' => $memory_data['allocator_allocated'],
+ 'resident' => $memory_data['allocator_resident'],
+ 'frag_bytes' => $memory_data['allocator_frag_bytes'],
+ 'rss_bytes' => $memory_data['allocator_rss_bytes'],
];
$rrd_def = RrdDefinition::make()
->addDataset('active', 'GAUGE', 0)
@@ -120,9 +120,9 @@ data_update($device, 'app', $tags, $fields);
$category = 'defrag';
$fields = [
'hits' => $stats_data['active_defrag_hits'],
- 'misses' => $stats_data['active_defrag_misses'],
- 'key_hits' => $stats_data['active_defrag_key_hits'],
- 'key_misses' => $stats_data['active_defrag_key_misses'],
+ 'misses' => $stats_data['active_defrag_misses'],
+ 'key_hits' => $stats_data['active_defrag_key_hits'],
+ 'key_misses' => $stats_data['active_defrag_key_misses'],
];
$rrd_def = RrdDefinition::make()
->addDataset('hits', 'GAUGE', 0)
@@ -138,7 +138,7 @@ data_update($device, 'app', $tags, $fields);
$category = 'keyspace';
$fields = [
'hits' => $stats_data['keyspace_hits'],
- 'misses' => $stats_data['keyspace_misses'],
+ 'misses' => $stats_data['keyspace_misses'],
];
$rrd_def = RrdDefinition::make()
->addDataset('hits', 'COUNTER', 0)
diff --git a/includes/polling/applications/sagan.inc.php b/includes/polling/applications/sagan.inc.php
index b91d73f792..285dfab530 100644
--- a/includes/polling/applications/sagan.inc.php
+++ b/includes/polling/applications/sagan.inc.php
@@ -19,7 +19,7 @@ try {
}
// grab the alert here as it is the global one
-$metrics = ['alert'=>$sagan['alert']];
+$metrics = ['alert' => $sagan['alert']];
$rrd_def = RrdDefinition::make()
->addDataset('after', 'GAUGE', 0)
diff --git a/includes/polling/applications/seafile.inc.php b/includes/polling/applications/seafile.inc.php
index 0b49a902ec..8a45fbe83a 100644
--- a/includes/polling/applications/seafile.inc.php
+++ b/includes/polling/applications/seafile.inc.php
@@ -44,10 +44,10 @@ foreach ($account_data as $data) {
$rrd_name = ['app', $name, $app->app_id, $category, $owner_name];
$fields = [
- 'enabled' => $enabled,
- 'libraries' => $libraries,
+ 'enabled' => $enabled,
+ 'libraries' => $libraries,
'trashed_libraries' => $trashed_libraries,
- 'size_consumption' => $size_consumption,
+ 'size_consumption' => $size_consumption,
];
$metrics[$owner_name . '_' . $category] = $fields;
diff --git a/includes/polling/applications/shoutcast.inc.php b/includes/polling/applications/shoutcast.inc.php
index 7190c3f44f..74ce8b003a 100644
--- a/includes/polling/applications/shoutcast.inc.php
+++ b/includes/polling/applications/shoutcast.inc.php
@@ -31,14 +31,14 @@ foreach ($servers as $item => $server) {
->addDataset('unique', 'GAUGE', 0, 125000000000);
$fields = [
- 'bitrate' => $data['1'],
- 'traf_in' => $data['2'],
+ 'bitrate' => $data['1'],
+ 'traf_in' => $data['2'],
'traf_out' => $data['3'],
- 'current' => $data['4'],
- 'status' => $data['5'],
- 'peak' => $data['6'],
- 'max' => $data['7'],
- 'unique' => $data['8'],
+ 'current' => $data['4'],
+ 'status' => $data['5'],
+ 'peak' => $data['6'],
+ 'max' => $data['7'],
+ 'unique' => $data['8'],
];
$metrics[$server] = $fields;
diff --git a/includes/polling/applications/suricata.inc.php b/includes/polling/applications/suricata.inc.php
index f1f041bdd2..6075b378d6 100644
--- a/includes/polling/applications/suricata.inc.php
+++ b/includes/polling/applications/suricata.inc.php
@@ -14,7 +14,7 @@ try {
}
// grab the alert here as it is the global one
-$metrics = ['alert'=>$suricata['alert']];
+$metrics = ['alert' => $suricata['alert']];
$rrd_def = RrdDefinition::make()
->addDataset('af_dcerpc_tcp', 'DERIVE', 0)
diff --git a/includes/polling/applications/tinydns.inc.php b/includes/polling/applications/tinydns.inc.php
index 6002297bb7..97efa52092 100644
--- a/includes/polling/applications/tinydns.inc.php
+++ b/includes/polling/applications/tinydns.inc.php
@@ -58,26 +58,26 @@ if (! empty($agent_data['app'][$name]) && $app->app_id > 0) {
] = explode(':', $agent_data['app'][$name]);
$fields = [
- 'a' => $a,
- 'ns' => $ns,
- 'cname' => $cname,
- 'soa' => $soa,
- 'ptr' => $ptr,
- 'hinfo' => $hinfo,
- 'mx' => $mx,
- 'txt' => $txt,
- 'rp' => $rp,
- 'sig' => $sig,
- 'key' => $key,
- 'aaaa' => $aaaa,
- 'axfr' => $axfr,
- 'any' => $any,
- 'total' => $total,
- 'other' => $other,
- 'notauth' => $notauth,
- 'notimpl' => $notimpl,
+ 'a' => $a,
+ 'ns' => $ns,
+ 'cname' => $cname,
+ 'soa' => $soa,
+ 'ptr' => $ptr,
+ 'hinfo' => $hinfo,
+ 'mx' => $mx,
+ 'txt' => $txt,
+ 'rp' => $rp,
+ 'sig' => $sig,
+ 'key' => $key,
+ 'aaaa' => $aaaa,
+ 'axfr' => $axfr,
+ 'any' => $any,
+ 'total' => $total,
+ 'other' => $other,
+ 'notauth' => $notauth,
+ 'notimpl' => $notimpl,
'badclass' => $badclass,
- 'noquery' => $noquery,
+ 'noquery' => $noquery,
];
$tags = [
diff --git a/includes/polling/aruba-controller.inc.php b/includes/polling/aruba-controller.inc.php
index c209903978..8c46b11486 100644
--- a/includes/polling/aruba-controller.inc.php
+++ b/includes/polling/aruba-controller.inc.php
@@ -52,7 +52,7 @@ if ($device['type'] == 'wireless' && $device['os'] == 'arubaos') {
->addDataset('NUMCLIENTS', 'GAUGE', 0, 12500000000);
$fields = [
- 'NUMAPS' => $aruba_stats[0]['wlsxSwitchTotalNumAccessPoints'],
+ 'NUMAPS' => $aruba_stats[0]['wlsxSwitchTotalNumAccessPoints'],
'NUMCLIENTS' => $aruba_stats[0]['wlsxSwitchTotalNumStationsAssociated'],
];
@@ -104,13 +104,13 @@ if ($device['type'] == 'wireless' && $device['os'] == 'arubaos') {
->addDataset('interference', 'GAUGE', 0, 2000);
$fields = [
- 'channel' => $channel,
- 'txpow' => $txpow,
- 'radioutil' => $radioutil,
- 'nummonclients' => $nummonclients,
- 'nummonbssid' => $nummonbssid,
- 'numasoclients' => $numasoclients,
- 'interference' => $interference,
+ 'channel' => $channel,
+ 'txpow' => $txpow,
+ 'radioutil' => $radioutil,
+ 'nummonclients' => $nummonclients,
+ 'nummonbssid' => $nummonbssid,
+ 'numasoclients' => $numasoclients,
+ 'interference' => $interference,
];
$tags = [
@@ -145,39 +145,39 @@ if ($device['type'] == 'wireless' && $device['os'] == 'arubaos') {
if ($foundid == 0) {
$ap_id = dbInsert(
[
- 'channel' => $channel,
- 'deleted' => 0,
- 'device_id' => $device['device_id'],
- 'interference' => $interference,
- 'mac_addr' => $mac,
- 'name' => $name,
- 'numactbssid' => $numactbssid,
+ 'channel' => $channel,
+ 'deleted' => 0,
+ 'device_id' => $device['device_id'],
+ 'interference' => $interference,
+ 'mac_addr' => $mac,
+ 'name' => $name,
+ 'numactbssid' => $numactbssid,
'numasoclients' => $numasoclients,
- 'nummonbssid' => $nummonbssid,
+ 'nummonbssid' => $nummonbssid,
'nummonclients' => $nummonclients,
- 'radio_number' => $radionum,
- 'radioutil' => $radioutil,
- 'txpow' => $txpow,
- 'type' => $type,
+ 'radio_number' => $radionum,
+ 'radioutil' => $radioutil,
+ 'txpow' => $txpow,
+ 'type' => $type,
],
'access_points'
);
} else {
dbUpdate(
[
- 'channel' => $channel,
- 'deleted' => 0,
- 'interference' => $interference,
- 'mac_addr' => $mac,
- 'name' => $name,
- 'numactbssid' => $numactbssid,
+ 'channel' => $channel,
+ 'deleted' => 0,
+ 'interference' => $interference,
+ 'mac_addr' => $mac,
+ 'name' => $name,
+ 'numactbssid' => $numactbssid,
'numasoclients' => $numasoclients,
- 'nummonbssid' => $nummonbssid,
+ 'nummonbssid' => $nummonbssid,
'nummonclients' => $nummonclients,
- 'radio_number' => $radionum,
- 'radioutil' => $radioutil,
- 'txpow' => $txpow,
- 'type' => $type,
+ 'radio_number' => $radionum,
+ 'radioutil' => $radioutil,
+ 'txpow' => $txpow,
+ 'type' => $type,
],
'access_points',
'`accesspoint_id` = ?',
diff --git a/includes/polling/bgp-peers.inc.php b/includes/polling/bgp-peers.inc.php
index bed7730cbe..e4ac30a749 100644
--- a/includes/polling/bgp-peers.inc.php
+++ b/includes/polling/bgp-peers.inc.php
@@ -729,14 +729,14 @@ if (! empty($peers)) {
$cbgpPeerWithdrawnPrefixes = set_numeric($cbgpPeerWithdrawnPrefixes);
$cbgpPeers_cbgp_fields = [
- 'AcceptedPrefixes' => $cbgpPeerAcceptedPrefixes,
- 'DeniedPrefixes' => $cbgpPeerDeniedPrefixes,
- 'PrefixAdminLimit' => $cbgpPeerPrefixAdminLimit,
- 'PrefixThreshold' => $cbgpPeerPrefixThreshold,
+ 'AcceptedPrefixes' => $cbgpPeerAcceptedPrefixes,
+ 'DeniedPrefixes' => $cbgpPeerDeniedPrefixes,
+ 'PrefixAdminLimit' => $cbgpPeerPrefixAdminLimit,
+ 'PrefixThreshold' => $cbgpPeerPrefixThreshold,
'PrefixClearThreshold' => $cbgpPeerPrefixClearThreshold,
- 'AdvertisedPrefixes' => $cbgpPeerAdvertisedPrefixes,
- 'SuppressedPrefixes' => $cbgpPeerSuppressedPrefixes,
- 'WithdrawnPrefixes' => $cbgpPeerWithdrawnPrefixes,
+ 'AdvertisedPrefixes' => $cbgpPeerAdvertisedPrefixes,
+ 'SuppressedPrefixes' => $cbgpPeerSuppressedPrefixes,
+ 'WithdrawnPrefixes' => $cbgpPeerWithdrawnPrefixes,
];
foreach ($cbgpPeers_cbgp_fields as $field => $value) {
@@ -781,11 +781,11 @@ if (! empty($peers)) {
->addDataset('SuppressedPrefixes', 'GAUGE', null, 100000000000)
->addDataset('WithdrawnPrefixes', 'GAUGE', null, 100000000000);
$fields = [
- 'AcceptedPrefixes' => $cbgpPeerAcceptedPrefixes,
- 'DeniedPrefixes' => $cbgpPeerDeniedPrefixes,
- 'AdvertisedPrefixes' => $cbgpPeerAdvertisedPrefixes,
- 'SuppressedPrefixes' => $cbgpPeerSuppressedPrefixes,
- 'WithdrawnPrefixes' => $cbgpPeerWithdrawnPrefixes,
+ 'AcceptedPrefixes' => $cbgpPeerAcceptedPrefixes,
+ 'DeniedPrefixes' => $cbgpPeerDeniedPrefixes,
+ 'AdvertisedPrefixes' => $cbgpPeerAdvertisedPrefixes,
+ 'SuppressedPrefixes' => $cbgpPeerSuppressedPrefixes,
+ 'WithdrawnPrefixes' => $cbgpPeerWithdrawnPrefixes,
];
$tags = [
diff --git a/includes/polling/cisco-cef.inc.php b/includes/polling/cisco-cef.inc.php
index 41842cb45b..6b82d3b4cc 100644
--- a/includes/polling/cisco-cef.inc.php
+++ b/includes/polling/cisco-cef.inc.php
@@ -78,9 +78,9 @@ if ($device['os_group'] == 'cisco') {
dbUpdate($cef_stat['update'], 'cef_switching', '`device_id` = ? AND `entPhysicalIndex` = ? AND `afi` = ? AND `cef_index` = ?', [$device['device_id'], $entity, $afi, $index]);
$fields = [
- 'drop' => $cef_stat['cefSwitchingDrop'],
- 'punt' => $cef_stat['cefSwitchingPunt'],
- 'hostpunt' => $cef_stat['cefSwitchingPunt2Host'],
+ 'drop' => $cef_stat['cefSwitchingDrop'],
+ 'punt' => $cef_stat['cefSwitchingPunt'],
+ 'hostpunt' => $cef_stat['cefSwitchingPunt2Host'],
];
$tags = compact('entity', 'afi', 'index', 'rrd_name', 'rrd_def');
diff --git a/includes/polling/cisco-ipsec-flow-monitor.inc.php b/includes/polling/cisco-ipsec-flow-monitor.inc.php
index b1012e89e3..5f4b7c0f28 100644
--- a/includes/polling/cisco-ipsec-flow-monitor.inc.php
+++ b/includes/polling/cisco-ipsec-flow-monitor.inc.php
@@ -79,27 +79,27 @@ if ($device['os_group'] == 'cisco') {
->addDataset('SysCapFails', 'COUNTER', 0, 100000000000);
$fields = [
- 'Tunnels' => $data['cipSecGlobalActiveTunnels'],
- 'InOctets' => $data['cipSecGlobalInOctets'],
- 'OutOctets' => $data['cipSecGlobalOutOctets'],
- 'InDecompOctets' => $data['cipSecGlobalInDecompOctets'],
- 'OutUncompOctets' => $data['cipSecGlobalOutUncompOctets'],
- 'InPkts' => $data['cipSecGlobalInPkts'],
- 'OutPkts' => $data['cipSecGlobalOutPkts'],
- 'InDrops' => $data['cipSecGlobalInDrops'],
- 'InReplayDrops' => $data['cipSecGlobalInReplayDrops'],
- 'OutDrops' => $data['cipSecGlobalOutDrops'],
- 'InAuths' => $data['cipSecGlobalInAuths'],
- 'OutAuths' => $data['cipSecGlobalOutAuths'],
- 'InAuthFails' => $data['cipSecGlobalInAuthFails'],
- 'OutAuthFails' => $data['cipSecGlobalOutAuthFails'],
- 'InDencrypts' => $data['cipSecGlobalInDecrypts'],
- 'OutEncrypts' => $data['cipSecGlobalOutEncrypts'],
- 'InDecryptFails' => $data['cipSecGlobalInDecryptFails'],
- 'OutEncryptFails' => $data['cipSecGlobalOutEncryptFails'],
+ 'Tunnels' => $data['cipSecGlobalActiveTunnels'],
+ 'InOctets' => $data['cipSecGlobalInOctets'],
+ 'OutOctets' => $data['cipSecGlobalOutOctets'],
+ 'InDecompOctets' => $data['cipSecGlobalInDecompOctets'],
+ 'OutUncompOctets' => $data['cipSecGlobalOutUncompOctets'],
+ 'InPkts' => $data['cipSecGlobalInPkts'],
+ 'OutPkts' => $data['cipSecGlobalOutPkts'],
+ 'InDrops' => $data['cipSecGlobalInDrops'],
+ 'InReplayDrops' => $data['cipSecGlobalInReplayDrops'],
+ 'OutDrops' => $data['cipSecGlobalOutDrops'],
+ 'InAuths' => $data['cipSecGlobalInAuths'],
+ 'OutAuths' => $data['cipSecGlobalOutAuths'],
+ 'InAuthFails' => $data['cipSecGlobalInAuthFails'],
+ 'OutAuthFails' => $data['cipSecGlobalOutAuthFails'],
+ 'InDencrypts' => $data['cipSecGlobalInDecrypts'],
+ 'OutEncrypts' => $data['cipSecGlobalOutEncrypts'],
+ 'InDecryptFails' => $data['cipSecGlobalInDecryptFails'],
+ 'OutEncryptFails' => $data['cipSecGlobalOutEncryptFails'],
'ProtocolUseFails' => $data['cipSecGlobalProtocolUseFails'],
- 'NoSaFails' => $data['cipSecGlobalNoSaFails'],
- 'SysCapFails' => $data['cipSecGlobalSysCapFails'],
+ 'NoSaFails' => $data['cipSecGlobalNoSaFails'],
+ 'SysCapFails' => $data['cipSecGlobalSysCapFails'],
];
$tags = compact('rrd_def');
diff --git a/includes/polling/cisco-remote-access-monitor.inc.php b/includes/polling/cisco-remote-access-monitor.inc.php
index 7cad68baed..8e61938787 100644
--- a/includes/polling/cisco-remote-access-monitor.inc.php
+++ b/includes/polling/cisco-remote-access-monitor.inc.php
@@ -53,12 +53,12 @@ if ($device['os_group'] == 'cisco') {
->addDataset('webvpn', 'GAUGE', 0);
$fields = [
- 'email' => $data['crasEmailNumSessions'],
- 'ipsec' => $data['crasIPSecNumSessions'],
- 'l2l' => $data['crasL2LNumSessions'],
- 'lb' => $data['crasLBNumSessions'],
- 'svc' => $data['crasSVCNumSessions'],
- 'webvpn' => $data['crasWebvpnNumSessions'],
+ 'email' => $data['crasEmailNumSessions'],
+ 'ipsec' => $data['crasIPSecNumSessions'],
+ 'l2l' => $data['crasL2LNumSessions'],
+ 'lb' => $data['crasLBNumSessions'],
+ 'svc' => $data['crasSVCNumSessions'],
+ 'webvpn' => $data['crasWebvpnNumSessions'],
];
$tags = compact('rrd_def');
diff --git a/includes/polling/cisco-voice/cisco-iosmtp.inc.php b/includes/polling/cisco-voice/cisco-iosmtp.inc.php
index ea6b682af9..519f0fddad 100644
--- a/includes/polling/cisco-voice/cisco-iosmtp.inc.php
+++ b/includes/polling/cisco-voice/cisco-iosmtp.inc.php
@@ -31,7 +31,7 @@ if ($device['os_group'] == 'cisco') {
->addDataset('active', 'GAUGE', 0);
$fields = [
- 'total' => $total,
+ 'total' => $total,
'active' => $active,
];
diff --git a/includes/polling/cisco-voice/cisco-iosxcode.inc.php b/includes/polling/cisco-voice/cisco-iosxcode.inc.php
index 2d24c50b28..d3ca17c882 100644
--- a/includes/polling/cisco-voice/cisco-iosxcode.inc.php
+++ b/includes/polling/cisco-voice/cisco-iosxcode.inc.php
@@ -31,7 +31,7 @@ if ($device['os_group'] == 'cisco') {
->addDataset('active', 'GAUGE', 0);
$fields = [
- 'total' => $total,
+ 'total' => $total,
'active' => $active,
];
diff --git a/includes/polling/cisco-vpdn.inc.php b/includes/polling/cisco-vpdn.inc.php
index 469705586e..aa1a653598 100644
--- a/includes/polling/cisco-vpdn.inc.php
+++ b/includes/polling/cisco-vpdn.inc.php
@@ -21,9 +21,9 @@ if ($device['os_group'] == 'cisco') {
->addDataset('denied', 'COUNTER', 0, 100000);
$fields = [
- 'tunnels' => $vpdn['cvpdnSystemTunnelTotal'],
- 'sessions' => $vpdn['cvpdnSystemSessionTotal'],
- 'denied' => $vpdn['cvpdnSystemDeniedUsersTotal'],
+ 'tunnels' => $vpdn['cvpdnSystemTunnelTotal'],
+ 'sessions' => $vpdn['cvpdnSystemSessionTotal'],
+ 'denied' => $vpdn['cvpdnSystemDeniedUsersTotal'],
];
$tags = compact('type', 'rrd_name', 'rrd_def');
diff --git a/includes/polling/entity-physical/cimc.inc.php b/includes/polling/entity-physical/cimc.inc.php
index 7a1277a448..e7bc89d4a5 100644
--- a/includes/polling/entity-physical/cimc.inc.php
+++ b/includes/polling/entity-physical/cimc.inc.php
@@ -12,7 +12,7 @@
*/
$component = new LibreNMS\Component();
-$components = $component->getComponents($device['device_id'], ['type'=>'Cisco-CIMC']);
+$components = $component->getComponents($device['device_id'], ['type' => 'Cisco-CIMC']);
// We only care about our device id.
$components = $components[$device['device_id']];
diff --git a/includes/polling/entity-physical/ios.inc.php b/includes/polling/entity-physical/ios.inc.php
index 948ec14d15..a02dc1590d 100644
--- a/includes/polling/entity-physical/ios.inc.php
+++ b/includes/polling/entity-physical/ios.inc.php
@@ -35,11 +35,11 @@ foreach ($chan_stats as $index => $entry) {
->addDataset('inerrors', 'DERIVE', 0, 125000000000);
$fields = [
- 'inutil' => $entry['cc6kxbarStatisticsInUtil'],
- 'oututil' => $entry['cc6kxbarStatisticsOutUtil'],
- 'outdropped' => $entry['cc6kxbarStatisticsOutDropped'],
- 'outerrors' => $entry['cc6kxbarStatisticsOutErrors'],
- 'inerrors' => $entry['cc6kxbarStatisticsInErrors'],
+ 'inutil' => $entry['cc6kxbarStatisticsInUtil'],
+ 'oututil' => $entry['cc6kxbarStatisticsOutUtil'],
+ 'outdropped' => $entry['cc6kxbarStatisticsOutDropped'],
+ 'outerrors' => $entry['cc6kxbarStatisticsOutErrors'],
+ 'inerrors' => $entry['cc6kxbarStatisticsInErrors'],
];
$tags = compact('index', 'subindex', 'rrd_name', 'rrd_def');
diff --git a/includes/polling/functions.inc.php b/includes/polling/functions.inc.php
index d64ce079d1..88eb46e767 100644
--- a/includes/polling/functions.inc.php
+++ b/includes/polling/functions.inc.php
@@ -135,36 +135,36 @@ function poll_sensor($device, $class)
function record_sensor_data($device, $all_sensors)
{
$supported_sensors = [
- 'airflow' => 'cfm',
- 'ber' => '',
- 'bitrate' => 'bps',
- 'charge' => '%',
+ 'airflow' => 'cfm',
+ 'ber' => '',
+ 'bitrate' => 'bps',
+ 'charge' => '%',
'chromatic_dispersion' => 'ps/nm',
- 'cooling' => 'W',
- 'count' => '',
- 'current' => 'A',
- 'delay' => 's',
- 'dbm' => 'dBm',
- 'eer' => 'eer',
- 'fanspeed' => 'rpm',
- 'frequency' => 'Hz',
- 'humidity' => '%',
- 'load' => '%',
- 'loss' => '%',
- 'percent' => '%',
- 'power' => 'W',
+ 'cooling' => 'W',
+ 'count' => '',
+ 'current' => 'A',
+ 'delay' => 's',
+ 'dbm' => 'dBm',
+ 'eer' => 'eer',
+ 'fanspeed' => 'rpm',
+ 'frequency' => 'Hz',
+ 'humidity' => '%',
+ 'load' => '%',
+ 'loss' => '%',
+ 'percent' => '%',
+ 'power' => 'W',
'power_consumed' => 'kWh',
- 'power_factor' => '',
- 'pressure' => 'kPa',
+ 'power_factor' => '',
+ 'pressure' => 'kPa',
'quality_factor' => 'dB',
- 'runtime' => 'Min',
- 'signal' => 'dBm',
- 'snr' => 'SNR',
- 'state' => '#',
- 'temperature' => 'C',
- 'tv_signal' => 'dBmV',
- 'voltage' => 'V',
- 'waterflow' => 'l/m',
+ 'runtime' => 'Min',
+ 'signal' => 'dBm',
+ 'snr' => 'SNR',
+ 'state' => '#',
+ 'temperature' => 'C',
+ 'tv_signal' => 'dBmV',
+ 'voltage' => 'V',
+ 'waterflow' => 'l/m',
];
foreach ($all_sensors as $sensor) {
diff --git a/includes/polling/junose-atm-vp.inc.php b/includes/polling/junose-atm-vp.inc.php
index 471f961684..4431758c22 100644
--- a/includes/polling/junose-atm-vp.inc.php
+++ b/includes/polling/junose-atm-vp.inc.php
@@ -44,13 +44,13 @@ if (count($vp_rows)) {
$rrd_name = ['vp', $ifIndex, $vp_id];
$fields = [
- 'incells' => $t_vp['juniAtmVpStatsInCells'],
- 'outcells' => $t_vp['juniAtmVpStatsOutCells'],
- 'inpackets' => $t_vp['juniAtmVpStatsInPackets'],
- 'outpackets' => $t_vp['juniAtmVpStatsOutPackets'],
- 'inpacketoctets' => $t_vp['juniAtmVpStatsInPacketOctets'],
+ 'incells' => $t_vp['juniAtmVpStatsInCells'],
+ 'outcells' => $t_vp['juniAtmVpStatsOutCells'],
+ 'inpackets' => $t_vp['juniAtmVpStatsInPackets'],
+ 'outpackets' => $t_vp['juniAtmVpStatsOutPackets'],
+ 'inpacketoctets' => $t_vp['juniAtmVpStatsInPacketOctets'],
'outpacketoctets' => $t_vp['juniAtmVpStatsOutPacketOctets'],
- 'inpacketerrors' => $t_vp['juniAtmVpStatsInPacketErrors'],
+ 'inpacketerrors' => $t_vp['juniAtmVpStatsInPacketErrors'],
'outpacketerrors' => $t_vp['juniAtmVpStatsOutPacketErrors'],
];
diff --git a/includes/polling/netscaler-vsvr.inc.php b/includes/polling/netscaler-vsvr.inc.php
index 83a6d51b38..1888bd1b40 100644
--- a/includes/polling/netscaler-vsvr.inc.php
+++ b/includes/polling/netscaler-vsvr.inc.php
@@ -101,13 +101,13 @@ if ($device['os'] == 'netscaler') {
echo ' | ' . str_pad($vsvr['vsvrRequestRate'], 8) . ' | ' . str_pad($vsvr['vsvrRxBytesRate'] . 'B/s', 8) . ' | ' . str_pad($vsvr['vsvrTxBytesRate'] . 'B/s', 8);
$db_update = [
- 'vsvr_ip' => $vsvr['vsvrIpAddress'],
- 'vsvr_port' => $vsvr['vsvrPort'],
- 'vsvr_state' => $vsvr['vsvrState'],
- 'vsvr_type' => $vsvr['vsvrType'],
+ 'vsvr_ip' => $vsvr['vsvrIpAddress'],
+ 'vsvr_port' => $vsvr['vsvrPort'],
+ 'vsvr_state' => $vsvr['vsvrState'],
+ 'vsvr_type' => $vsvr['vsvrType'],
'vsvr_req_rate' => $vsvr['RequestRate'],
- 'vsvr_bps_in' => $vsvr['vsvrRxBytesRate'],
- 'vsvr_bps_out' => $vsvr['vsvrTxBytesRate'],
+ 'vsvr_bps_in' => $vsvr['vsvrRxBytesRate'],
+ 'vsvr_bps_out' => $vsvr['vsvrTxBytesRate'],
];
if (! is_array($vsvrs[$vsvr['vsvrFullName']])) {
diff --git a/includes/polling/ports/os/cnmatrix.inc.php b/includes/polling/ports/os/cnmatrix.inc.php
index 0037005a51..68d5e5e076 100644
--- a/includes/polling/ports/os/cnmatrix.inc.php
+++ b/includes/polling/ports/os/cnmatrix.inc.php
@@ -1,6 +1,6 @@
$port) {
+foreach ($port_stats as $index => $port) {
$port_stats[$index]['ifAlias'] = $int_desc[$index]['ifMainDesc'];
}
diff --git a/includes/polling/ports/os/infinera-groove.inc.php b/includes/polling/ports/os/infinera-groove.inc.php
index 4d447b284f..c3b3b96e3d 100644
--- a/includes/polling/ports/os/infinera-groove.inc.php
+++ b/includes/polling/ports/os/infinera-groove.inc.php
@@ -33,19 +33,19 @@ foreach (['eth100g', 'eth40g', 'eth10g', 'fc16g', 'fc8g'] as $infineratype) {
$cg_stats = snmpwalk_cache_multi_oid($device, $infineratype . 'Statistics', $cg_stats, 'CORIANT-GROOVE-MIB');
$required = [
- 'ifAlias' => $infineratype . 'AliasName',
- 'ifAdminStatus' => $infineratype . 'AdminStatus',
- 'ifOperStatus' => $infineratype . 'OperStatus',
- 'ifType' => 'Ethernet',
- 'ifHCInBroadcastPkts' => $infineratype . 'StatisticsEntryInBroadcastPackets',
- 'ifHCInMulticastPkts' => $infineratype . 'StatisticsEntryInMulticastPackets',
- 'ifHCInOctets' => $infineratype . 'StatisticsEntryInOctets',
- 'ifHCInUcastPkts' => $infineratype . 'StatisticsEntryInPackets',
- 'ifHCOutBroadcastPkts' => $infineratype . 'StatisticsEntryOutBroadcastPackets',
- 'ifHCOutMulticastPkts' => $infineratype . 'StatisticsEntryOutMulticastPackets',
- 'ifHCOutOctets' => $infineratype . 'StatisticsEntryOutOctets',
- 'ifHCOutUcastPkts' => $infineratype . 'StatisticsEntryOutPackets',
- 'ifHighSpeed' => $infspeed * 1000,
+ 'ifAlias' => $infineratype . 'AliasName',
+ 'ifAdminStatus' => $infineratype . 'AdminStatus',
+ 'ifOperStatus' => $infineratype . 'OperStatus',
+ 'ifType' => 'Ethernet',
+ 'ifHCInBroadcastPkts' => $infineratype . 'StatisticsEntryInBroadcastPackets',
+ 'ifHCInMulticastPkts' => $infineratype . 'StatisticsEntryInMulticastPackets',
+ 'ifHCInOctets' => $infineratype . 'StatisticsEntryInOctets',
+ 'ifHCInUcastPkts' => $infineratype . 'StatisticsEntryInPackets',
+ 'ifHCOutBroadcastPkts' => $infineratype . 'StatisticsEntryOutBroadcastPackets',
+ 'ifHCOutMulticastPkts' => $infineratype . 'StatisticsEntryOutMulticastPackets',
+ 'ifHCOutOctets' => $infineratype . 'StatisticsEntryOutOctets',
+ 'ifHCOutUcastPkts' => $infineratype . 'StatisticsEntryOutPackets',
+ 'ifHighSpeed' => $infspeed * 1000,
];
foreach ($cg_stats as $index => $tmp_stats) {
diff --git a/includes/polling/ports/os/procera.inc.php b/includes/polling/ports/os/procera.inc.php
index 16289ff5da..0e9a84d573 100644
--- a/includes/polling/ports/os/procera.inc.php
+++ b/includes/polling/ports/os/procera.inc.php
@@ -47,7 +47,7 @@ $required = [
// Media Types as per PACKETLOGIC-CHANNEL-MIB
$mediaType = [
- 0 => ['ifDuplex' => null, 'ifSpeed' => 0, 'label'=> 'linkdown'],
+ 0 => ['ifDuplex' => null, 'ifSpeed' => 0, 'label' => 'linkdown'],
1 => ['ifDuplex' => 'halfDuplex', 'ifSpeed' => '10000000', 'label' => 'hd10'],
2 => ['ifDuplex' => 'fullDuplex', 'ifSpeed' => '10000000', 'label' => 'fd10'],
3 => ['ifDuplex' => 'halfDuplex', 'ifSpeed' => '100000000', 'label' => 'hd100'],
diff --git a/includes/polling/ports/os/timos.inc.php b/includes/polling/ports/os/timos.inc.php
index e8ab604b47..67dc5b50f5 100644
--- a/includes/polling/ports/os/timos.inc.php
+++ b/includes/polling/ports/os/timos.inc.php
@@ -45,16 +45,16 @@ foreach ($timos_vrf_stats as $vrf) {
unset($timos_vrf_stats);
$translate = [
- 'ifName' => 'vRtrIfName',
- 'ifAlias' => 'vRtrIfAlias',
- 'ifDescr' => 'vRtrIfDescription',
- 'ifSpeed' => 'vRtrIfSpeed',
- 'ifType' => 'vRtrIfType',
- 'ifMtu' => 'vRtrIfMtu',
- 'ifHCInOctets' => 'vRtrIfRxBytes',
- 'ifHCOutOctets' => 'vRtrIfTxBytes',
- 'ifHCInUcastPkts' => 'vRtrIfRxPkts',
- 'ifHCOutUcastPkts' => 'vRtrIfTxPkts',
+ 'ifName' => 'vRtrIfName',
+ 'ifAlias' => 'vRtrIfAlias',
+ 'ifDescr' => 'vRtrIfDescription',
+ 'ifSpeed' => 'vRtrIfSpeed',
+ 'ifType' => 'vRtrIfType',
+ 'ifMtu' => 'vRtrIfMtu',
+ 'ifHCInOctets' => 'vRtrIfRxBytes',
+ 'ifHCOutOctets' => 'vRtrIfTxBytes',
+ 'ifHCInUcastPkts' => 'vRtrIfRxPkts',
+ 'ifHCOutUcastPkts' => 'vRtrIfTxPkts',
];
$timos_ports = [];
diff --git a/includes/polling/ports/port-poe.inc.php b/includes/polling/ports/port-poe.inc.php
index 0bb1c4f862..79c630ab34 100644
--- a/includes/polling/ports/port-poe.inc.php
+++ b/includes/polling/ports/port-poe.inc.php
@@ -15,10 +15,10 @@ if ($device['os'] == 'vrp') {
$upd = "$polled:" . $this_port['hwPoePortReferencePower'] . ':' . $this_port['hwPoePortMaximumPower'] . ':' . $this_port['hwPoePortConsumingPower'] . ':' . $this_port['hwPoePortPeakPower'];
$fields = [
- 'PortPwrAllocated' => $this_port['hwPoePortReferencePower'],
- 'PortPwrAvailable' => $this_port['hwPoePortMaximumPower'],
- 'PortConsumption' => $this_port['hwPoePortConsumingPower'],
- 'PortMaxPwrDrawn' => $this_port['hwPoePortPeakPower'],
+ 'PortPwrAllocated' => $this_port['hwPoePortReferencePower'],
+ 'PortPwrAvailable' => $this_port['hwPoePortMaximumPower'],
+ 'PortConsumption' => $this_port['hwPoePortConsumingPower'],
+ 'PortMaxPwrDrawn' => $this_port['hwPoePortPeakPower'],
];
$tags = compact('ifName', 'rrd_name', 'rrd_def');
@@ -31,10 +31,10 @@ if ($device['os'] == 'vrp') {
$upd = "$polled:" . $this_port['rlPethPsePortPowerLimit'] . ':' . $this_port['rlPethPsePortOutputPower'];
$fields = [
- 'PortPwrAllocated' => $this_port['rlPethPsePortPowerLimit'],
- 'PortPwrAvailable' => $this_port['rlPethPsePortPowerLimit'],
- 'PortConsumption' => $this_port['rlPethPsePortOutputPower'],
- 'PortMaxPwrDrawn' => $this_port['rlPethPsePortPowerLimit'],
+ 'PortPwrAllocated' => $this_port['rlPethPsePortPowerLimit'],
+ 'PortPwrAvailable' => $this_port['rlPethPsePortPowerLimit'],
+ 'PortConsumption' => $this_port['rlPethPsePortOutputPower'],
+ 'PortMaxPwrDrawn' => $this_port['rlPethPsePortPowerLimit'],
];
$tags = compact('ifName', 'rrd_name', 'rrd_def');
@@ -49,10 +49,10 @@ if ($device['os'] == 'vrp') {
$port['cpeExtPsePortPwrConsumption'] . ':' . $port['cpeExtPsePortMaxPwrDrawn'];
echo "$this_port[cpeExtPsePortPwrAllocated],$this_port[cpeExtPsePortPwrAvailable],$this_port[cpeExtPsePortPwrConsumption],$this_port[cpeExtPsePortMaxPwrDrawn]\n";
$fields = [
- 'PortPwrAllocated' => $this_port['cpeExtPsePortPwrAllocated'],
- 'PortPwrAvailable' => $this_port['cpeExtPsePortPwrAvailable'],
- 'PortConsumption' => $this_port['cpeExtPsePortPwrConsumption'],
- 'PortMaxPwrDrawn' => $this_port['cpeExtPsePortMaxPwrDrawn'],
+ 'PortPwrAllocated' => $this_port['cpeExtPsePortPwrAllocated'],
+ 'PortPwrAvailable' => $this_port['cpeExtPsePortPwrAvailable'],
+ 'PortConsumption' => $this_port['cpeExtPsePortPwrConsumption'],
+ 'PortMaxPwrDrawn' => $this_port['cpeExtPsePortMaxPwrDrawn'],
];
$tags = compact('ifName', 'rrd_name', 'rrd_def');
@@ -63,10 +63,10 @@ if ($device['os'] == 'vrp') {
if (isset($this_port['tpPoePortStatus'])) {
// TP-Link uses .1W for their units; convert to milliwatts.
$fields = [
- 'PortPwrAllocated' => $this_port['tpPoePowerLimit'] * 100,
- 'PortPwrAvailable' => $this_port['tpPoePowerLimit'] * 100,
- 'PortConsumption' => $this_port['tpPoePower'] * 100,
- 'PortMaxPwrDrawn' => $this_port['tpPoePowerLimit'] * 100,
+ 'PortPwrAllocated' => $this_port['tpPoePowerLimit'] * 100,
+ 'PortPwrAvailable' => $this_port['tpPoePowerLimit'] * 100,
+ 'PortConsumption' => $this_port['tpPoePower'] * 100,
+ 'PortMaxPwrDrawn' => $this_port['tpPoePowerLimit'] * 100,
];
$tags = compact('ifName', 'rrd_name', 'rrd_def');
diff --git a/includes/polling/storage.inc.php b/includes/polling/storage.inc.php
index 6b3f353038..38e3c28192 100644
--- a/includes/polling/storage.inc.php
+++ b/includes/polling/storage.inc.php
@@ -26,8 +26,8 @@ foreach (dbFetchRows('SELECT * FROM storage WHERE device_id = ?', [$device['devi
echo $percent . '% ';
$fields = [
- 'used' => $storage['used'],
- 'free' => $storage['free'],
+ 'used' => $storage['used'],
+ 'free' => $storage['free'],
];
$tags = compact('mib', 'descr', 'rrd_name', 'rrd_def');
diff --git a/includes/polling/ucd-diskio.inc.php b/includes/polling/ucd-diskio.inc.php
index 6188b149b7..b6678909ae 100644
--- a/includes/polling/ucd-diskio.inc.php
+++ b/includes/polling/ucd-diskio.inc.php
@@ -18,20 +18,20 @@ if (count($diskio_data)) {
d_echo($entry);
$tags = [
- 'rrd_name' => ['ucd_diskio', $diskio['diskio_descr']],
- 'rrd_def' => RrdDefinition::make()
+ 'rrd_name' => ['ucd_diskio', $diskio['diskio_descr']],
+ 'rrd_def' => RrdDefinition::make()
->addDataset('read', 'DERIVE', 0, 125000000000)
->addDataset('written', 'DERIVE', 0, 125000000000)
->addDataset('reads', 'DERIVE', 0, 125000000000)
->addDataset('writes', 'DERIVE', 0, 125000000000),
- 'descr' => $diskio['diskio_descr'],
+ 'descr' => $diskio['diskio_descr'],
];
$fields = [
- 'read' => $entry['diskIONReadX'],
+ 'read' => $entry['diskIONReadX'],
'written' => $entry['diskIONWrittenX'],
- 'reads' => $entry['diskIOReads'],
- 'writes' => $entry['diskIOWrites'],
+ 'reads' => $entry['diskIOReads'],
+ 'writes' => $entry['diskIOWrites'],
];
data_update($device, 'ucd_diskio', $tags, $fields);
diff --git a/includes/polling/ucd-mib.inc.php b/includes/polling/ucd-mib.inc.php
index 49360b001d..01015bb708 100644
--- a/includes/polling/ucd-mib.inc.php
+++ b/includes/polling/ucd-mib.inc.php
@@ -135,9 +135,9 @@ if (is_numeric($load_raw[2]['laLoadInt'] ?? null)) {
->addDataset('15min', 'GAUGE', 0);
$fields = [
- '1min' => $load_raw[1]['laLoadInt'],
- '5min' => $load_raw[2]['laLoadInt'],
- '15min' => $load_raw[3]['laLoadInt'],
+ '1min' => $load_raw[1]['laLoadInt'],
+ '5min' => $load_raw[2]['laLoadInt'],
+ '15min' => $load_raw[3]['laLoadInt'],
];
$tags = compact('rrd_def');
diff --git a/includes/polling/unix-agent/munin-plugins.inc.php b/includes/polling/unix-agent/munin-plugins.inc.php
index d89d3fc6c4..7e9566b7e7 100644
--- a/includes/polling/unix-agent/munin-plugins.inc.php
+++ b/includes/polling/unix-agent/munin-plugins.inc.php
@@ -45,14 +45,14 @@ if (! empty($agent_data['munin'])) {
if (! is_array($plugins_db[$plugin_type])) {
$insert = [
- 'device_id' => $device['device_id'],
- 'mplug_type' => $plugin_type,
+ 'device_id' => $device['device_id'],
+ 'mplug_type' => $plugin_type,
'mplug_instance' => $instance,
'mplug_category' => ($plugin['graph']['category'] == null ? 'general' : strtolower($plugin['graph']['category'])),
- 'mplug_title' => $plugin['graph']['title'],
- 'mplug_vlabel' => $plugin['graph']['vlabel'],
- 'mplug_args' => $plugin['graph']['args'],
- 'mplug_info' => $plugin['graph']['info'],
+ 'mplug_title' => $plugin['graph']['title'],
+ 'mplug_vlabel' => $plugin['graph']['vlabel'],
+ 'mplug_args' => $plugin['graph']['args'],
+ 'mplug_info' => $plugin['graph']['info'],
];
$mplug_id = dbInsert($insert, 'munin_plugins');
} else {
@@ -93,32 +93,32 @@ if (! empty($agent_data['munin'])) {
];
$tags = [
- 'plugin' => $plugin_type,
- 'rrd_def' => RrdDefinition::make()->addDataset('val', $data['type']),
+ 'plugin' => $plugin_type,
+ 'rrd_def' => RrdDefinition::make()->addDataset('val', $data['type']),
'rrd_name' => $base_rrd_name . '_' . $name,
];
data_update($device, 'munin-plugins', $tags, $fields);
if (empty($ds_list[$ds_uniq])) {
$insert = [
- 'mplug_id' => $mplug_id,
- 'ds_name' => $name,
- 'ds_type' => $data['type'],
- 'ds_label' => $data['label'],
- 'ds_cdef' => $data['cdef'],
- 'ds_draw' => $data['draw'],
- 'ds_info' => $data['info'],
- 'ds_extinfo' => $data['extinfo'],
- 'ds_min' => $data['min'],
- 'ds_max' => $data['max'],
- 'ds_graph' => $data['graph'],
+ 'mplug_id' => $mplug_id,
+ 'ds_name' => $name,
+ 'ds_type' => $data['type'],
+ 'ds_label' => $data['label'],
+ 'ds_cdef' => $data['cdef'],
+ 'ds_draw' => $data['draw'],
+ 'ds_info' => $data['info'],
+ 'ds_extinfo' => $data['extinfo'],
+ 'ds_min' => $data['min'],
+ 'ds_max' => $data['max'],
+ 'ds_graph' => $data['graph'],
'ds_negative' => $data['negative'],
- 'ds_warning' => $data['warning'],
+ 'ds_warning' => $data['warning'],
'ds_critical' => $data['critical'],
- 'ds_colour' => $data['colour'],
- 'ds_sum' => $data['sum'],
- 'ds_stack' => $data['stack'],
- 'ds_line' => $data['line'],
+ 'ds_colour' => $data['colour'],
+ 'ds_sum' => $data['sum'],
+ 'ds_stack' => $data['stack'],
+ 'ds_line' => $data['line'],
];
$ds_id = dbInsert($insert, 'munin_plugins_ds');
}//end if
diff --git a/includes/rewrites.php b/includes/rewrites.php
index 6f4d2bb1f2..21f0974e7e 100644
--- a/includes/rewrites.php
+++ b/includes/rewrites.php
@@ -95,24 +95,24 @@ function cleanPort($interface, $device = null)
function makeshortif($if)
{
$rewrite_shortif = [
- 'tengigabitethernet' => 'Te',
+ 'tengigabitethernet' => 'Te',
'ten-gigabitethernet' => 'Te',
- 'tengige' => 'Te',
- 'gigabitethernet' => 'Gi',
- 'fastethernet' => 'Fa',
- 'ethernet' => 'Et',
- 'serial' => 'Se',
- 'pos' => 'Pos',
- 'port-channel' => 'Po',
- 'atm' => 'Atm',
- 'null' => 'Null',
- 'loopback' => 'Lo',
- 'dialer' => 'Di',
- 'vlan' => 'Vlan',
- 'tunnel' => 'Tunnel',
- 'serviceinstance' => 'SI',
- 'dwdm' => 'DWDM',
- 'bundle-ether' => 'BE',
+ 'tengige' => 'Te',
+ 'gigabitethernet' => 'Gi',
+ 'fastethernet' => 'Fa',
+ 'ethernet' => 'Et',
+ 'serial' => 'Se',
+ 'pos' => 'Pos',
+ 'port-channel' => 'Po',
+ 'atm' => 'Atm',
+ 'null' => 'Null',
+ 'loopback' => 'Lo',
+ 'dialer' => 'Di',
+ 'vlan' => 'Vlan',
+ 'tunnel' => 'Tunnel',
+ 'serviceinstance' => 'SI',
+ 'dwdm' => 'DWDM',
+ 'bundle-ether' => 'BE',
];
$if = \LibreNMS\Util\Rewrite::normalizeIfName($if);
@@ -126,8 +126,8 @@ function rewrite_generic_hardware($hardware)
{
$rewrite_GenericHW = [
' Computer Corporation' => '',
- ' Corporation' => '',
- ' Inc.' => '',
+ ' Corporation' => '',
+ ' Inc.' => '',
];
return str_replace(array_keys($rewrite_GenericHW), array_values($rewrite_GenericHW), $hardware);
@@ -138,10 +138,10 @@ function short_hrDeviceDescr($dev)
$rewrite_hrDevice = [
'GenuineIntel:' => '',
'AuthenticAMD:' => '',
- 'Intel(R)' => '',
- 'CPU' => '',
- '(R)' => '',
- ' ' => ' ',
+ 'Intel(R)' => '',
+ 'CPU' => '',
+ '(R)' => '',
+ ' ' => ' ',
];
$dev = str_replace(array_keys($rewrite_hrDevice), array_values($rewrite_hrDevice), $dev);
@@ -166,10 +166,10 @@ function short_port_descr($desc)
function rewrite_adslLineType($adslLineType)
{
$adslLineTypes = [
- 'noChannel' => 'No Channel',
- 'fastOnly' => 'Fastpath',
- 'interleavedOnly' => 'Interleaved',
- 'fastOrInterleaved' => 'Fast/Interleaved',
+ 'noChannel' => 'No Channel',
+ 'fastOnly' => 'Fastpath',
+ 'interleavedOnly' => 'Interleaved',
+ 'fastOrInterleaved' => 'Fast/Interleaved',
'fastAndInterleaved' => 'Fast+Interleaved',
];
@@ -297,7 +297,7 @@ function parse_entity_state($state, $value)
return $data[$state][$value];
}
- return ['text'=>'na', 'color'=>'default'];
+ return ['text' => 'na', 'color' => 'default'];
}
function parse_entity_state_alarm($bits)
diff --git a/includes/services.inc.php b/includes/services.inc.php
index 5f5c96b206..66fdff2f82 100644
--- a/includes/services.inc.php
+++ b/includes/services.inc.php
@@ -320,7 +320,7 @@ function check_service($command)
}
// We have a DS. Add an entry to the array.
d_echo('Perf Data - DS: ' . $ds . ', Value: ' . $value . ', UOM: ' . $uom . "\n");
- $metrics[$ds] = ['value'=>$value, 'uom'=>$uom];
+ $metrics[$ds] = ['value' => $value, 'uom' => $uom];
} else {
// No DS. Don't add an entry to the array.
d_echo("Perf Data - None.\n");
diff --git a/includes/syslog.php b/includes/syslog.php
index b7eceb21d3..b1c4e6188a 100644
--- a/includes/syslog.php
+++ b/includes/syslog.php
@@ -153,12 +153,12 @@ function process_syslog($entry, $update)
dbInsert(
[
'device_id' => $entry['device_id'],
- 'program' => $entry['program'],
- 'facility' => $entry['facility'],
- 'priority' => $entry['priority'],
- 'level' => $entry['level'],
- 'tag' => $entry['tag'],
- 'msg' => $entry['msg'],
+ 'program' => $entry['program'],
+ 'facility' => $entry['facility'],
+ 'priority' => $entry['priority'],
+ 'level' => $entry['level'],
+ 'tag' => $entry['tag'],
+ 'msg' => $entry['msg'],
'timestamp' => $entry['timestamp'],
],
'syslog'
diff --git a/scripts/manage_bills.php b/scripts/manage_bills.php
index 723bf6f2e6..bc65016e04 100755
--- a/scripts/manage_bills.php
+++ b/scripts/manage_bills.php
@@ -42,7 +42,7 @@ function create_bill($bill_name, $bill_type, $bill_cdr, $bill_day)
$insert = [
'bill_name' => $bill_name,
'bill_type' => $bill_type,
- 'bill_cdr' => $bill_cdr,
+ 'bill_cdr' => $bill_cdr,
'bill_day' => '1',
];
$create_bill = dbInsert($insert, 'bills');
diff --git a/scripts/removespikes.php b/scripts/removespikes.php
index 88d75877b3..4a6737a646 100755
--- a/scripts/removespikes.php
+++ b/scripts/removespikes.php
@@ -816,6 +816,7 @@ function removeComments(&$output)
}
}
}
+
/* transfer the new array back to the original array */
return $new_array;
}
diff --git a/tests/BasicApiTest.php b/tests/BasicApiTest.php
index 9cfb829a2c..bd9ce0ad66 100644
--- a/tests/BasicApiTest.php
+++ b/tests/BasicApiTest.php
@@ -46,7 +46,7 @@ class BasicApiTest extends DBTestCase
->assertJson([
'status' => 'ok',
'devices' => [$device->toArray()],
- 'count'=> 1,
+ 'count' => 1,
]);
}
}
diff --git a/tests/CommonFunctionsTest.php b/tests/CommonFunctionsTest.php
index 89bb12ab5e..72b41250b7 100644
--- a/tests/CommonFunctionsTest.php
+++ b/tests/CommonFunctionsTest.php
@@ -96,8 +96,8 @@ class CommonFunctionsTest extends TestCase
$this->assertEquals('<script>alert("test")</script>', Clean::html('', []));
$tmp_config = [
- 'HTML.Allowed' => 'b,iframe,i,ul,li,h1,h2,h3,h4,br,p',
- 'HTML.Trusted' => true,
+ 'HTML.Allowed' => 'b,iframe,i,ul,li,h1,h2,h3,h4,br,p',
+ 'HTML.Trusted' => true,
'HTML.SafeIframe' => true,
];
diff --git a/tests/SyslogTest.php b/tests/SyslogTest.php
index 869fdfa0be..8bc5a07ecf 100644
--- a/tests/SyslogTest.php
+++ b/tests/SyslogTest.php
@@ -72,74 +72,74 @@ class SyslogTest extends TestCase
// ---- IOS ----
$this->checkSyslog(
'1.1.1.1||user||info||info||0e||2016-02-28 00:23:34||%CARD-SEVERITY-MSG:SLOT %FACILITY-SEVERITY-MNEMONIC: Message-text||',
- ['device_id'=>1, 'program'=>'%CARD-SEVERITY-MSG:SLOT %FACILITY-SEVERITY-MNEMONIC', 'msg'=>'Message-text']
+ ['device_id' => 1, 'program' => '%CARD-SEVERITY-MSG:SLOT %FACILITY-SEVERITY-MNEMONIC', 'msg' => 'Message-text']
);
$this->checkSyslog(
'1.1.1.1||user||info||info||0e||2016-02-28 00:23:34||%FACILITY-SUBFACILITY-SEVERITY-MNEMONIC: Message-text||',
- ['device_id'=>1, 'program'=>'%FACILITY-SUBFACILITY-SEVERITY-MNEMONIC', 'msg'=>'Message-text']
+ ['device_id' => 1, 'program' => '%FACILITY-SUBFACILITY-SEVERITY-MNEMONIC', 'msg' => 'Message-text']
);
$this->checkSyslog(
'1.1.1.1||local7||info||info||be||2016-03-09 03:58:25||Mar 9 11:58:24.145 UTC: %SEC-6-IPACCESSLOGS: list MNGMNT denied 120.62.186.12 1 packet ||]',
- ['device_id'=>1, 'program'=>'%SEC-6-IPACCESSLOGS', 'msg'=>'list MNGMNT denied 120.62.186.12 1 packet']
+ ['device_id' => 1, 'program' => '%SEC-6-IPACCESSLOGS', 'msg' => 'list MNGMNT denied 120.62.186.12 1 packet']
);
$this->checkSyslog(
'1.1.1.1||local7||info||info||be||2016-04-27 021:12:28||Apr 27 21:12:28: %SYS-5-CONFIG_I: Configured from console by vty0||',
- ['device_id'=>1, 'program'=>'%SYS-5-CONFIG_I', 'msg'=>'Configured from console by vty0']
+ ['device_id' => 1, 'program' => '%SYS-5-CONFIG_I', 'msg' => 'Configured from console by vty0']
);
$this->checkSyslog(
'1.1.1.1||local7||info||info||be||2016-04-27 021:12:28||Mar 8 20:14:08.762: %FACILITY-SUBFACILITY-SEVERITY-MNEMONIC: Message-text||000956',
- ['device_id'=>1, 'program'=>'%FACILITY-SUBFACILITY-SEVERITY-MNEMONIC', 'msg'=>'Message-text']
+ ['device_id' => 1, 'program' => '%FACILITY-SUBFACILITY-SEVERITY-MNEMONIC', 'msg' => 'Message-text']
);
// ---- CatOS ----
$this->checkSyslog(
'1.1.1.1||user||info||info||0e||2016-02-28 00:23:34||%IP-3-UDP_SOCKOVFL:UDP socket overflow||',
- ['device_id'=>1, 'program'=>'%IP-3-UDP_SOCKOVFL', 'msg'=>'UDP socket overflow']
+ ['device_id' => 1, 'program' => '%IP-3-UDP_SOCKOVFL', 'msg' => 'UDP socket overflow']
);
$this->checkSyslog(
'1.1.1.1||user||info||info||0e||2016-02-28 00:23:34||DTP-1-ILGLCFG: Illegal config (on, isl--on,dot1q) on Port [mod/port]||',
- ['device_id'=>1, 'program'=>'DTP-1-ILGLCFG', 'msg'=>'Illegal config (on, isl--on,dot1q) on Port [mod/port]']
+ ['device_id' => 1, 'program' => 'DTP-1-ILGLCFG', 'msg' => 'Illegal config (on, isl--on,dot1q) on Port [mod/port]']
);
$this->checkSyslog(
'1.1.1.1||user||info||info||0e||2016-02-28 00:23:34||Cannot enable text mode config if ACL config is cleared from nvram||',
- ['device_id'=>1, 'program'=>'', 'msg'=>'Cannot enable text mode config if ACL config is cleared from nvram']
+ ['device_id' => 1, 'program' => '', 'msg' => 'Cannot enable text mode config if ACL config is cleared from nvram']
);
$this->checkSyslog(
'1.1.1.1||user||info||info||0e||2016-02-28 00:23:34||%PAGP-5-PORTFROMSTP / %PAGP-5-PORTTOSTP||',
- ['device_id'=>1, 'program'=>'%PAGP-5-PORTFROMSTP / %PAGP-5-PORTTOSTP']
+ ['device_id' => 1, 'program' => '%PAGP-5-PORTFROMSTP / %PAGP-5-PORTTOSTP']
);
$this->checkSyslog(
'1.1.1.1||user||info||info||0e||2016-02-28 00:23:34||%SYS-3-EOBC_CHANNELREINIT||',
- ['device_id'=>1, 'program'=>'%SYS-3-EOBC_CHANNELREINIT']
+ ['device_id' => 1, 'program' => '%SYS-3-EOBC_CHANNELREINIT']
);
$this->checkSyslog(
'1.1.1.1||user||info||info||0e||2016-02-28 00:23:34||%SYS-4-MODHPRESET:||',
- ['device_id'=>1, 'program'=>'%SYS-4-MODHPRESET', 'msg'=>'']
+ ['device_id' => 1, 'program' => '%SYS-4-MODHPRESET', 'msg' => '']
);
$this->checkSyslog(
'1.1.1.1||user||info||info||0e||2016-02-28 00:23:34||InbandPingProcessFailure:Module x not responding over inband||',
- ['device_id'=>1, 'program'=>'INBANDPINGPROCESSFAILURE', 'msg'=>'Module x not responding over inband']
+ ['device_id' => 1, 'program' => 'INBANDPINGPROCESSFAILURE', 'msg' => 'Module x not responding over inband']
);
$this->checkSyslog(
'1.1.1.1||user||info||info||0e||2016-02-28 00:23:34||RxSBIF_SEQ_NUM_ERROR:slot=x||',
- ['device_id'=>1, 'program'=>'RXSBIF_SEQ_NUM_ERROR', 'msg'=>'slot=x']
+ ['device_id' => 1, 'program' => 'RXSBIF_SEQ_NUM_ERROR', 'msg' => 'slot=x']
);
// With program from syslog
$this->checkSyslog(
'1.1.1.1||local7||notice||notice||bd||2016-04-04 15:18:43||Apr 4 13:18:42.670: %LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/32, changed state to up||345735',
- ['device_id'=>1, 'program'=>'%LINEPROTO-5-UPDOWN', 'msg'=>'Line protocol on Interface GigabitEthernet0/32, changed state to up']
+ ['device_id' => 1, 'program' => '%LINEPROTO-5-UPDOWN', 'msg' => 'Line protocol on Interface GigabitEthernet0/32, changed state to up']
);
// Incorrect time
$this->checkSyslog(
'1.1.1.1||user||info||info||0e||2016-04-06 15:20:35||*Apr 4 21:26:41.778 UTC: %LWAPP-3-REPLAY_ERR: 1 wcm: Received replay error on slot 1, WLAN ID 1, count 1 from AP xxxx.xxxx.xxxx||',
- ['device_id'=>1, 'program'=>'%LWAPP-3-REPLAY_ERR', 'msg'=>'1 wcm: Received replay error on slot 1, WLAN ID 1, count 1 from AP xxxx.xxxx.xxxx']
+ ['device_id' => 1, 'program' => '%LWAPP-3-REPLAY_ERR', 'msg' => '1 wcm: Received replay error on slot 1, WLAN ID 1, count 1 from AP xxxx.xxxx.xxxx']
);
$this->checkSyslog(
'1.1.1.1||user||info||info||0e||2016-04-06 15:20:35||.Apr 4 21:26:41.778 UTC: %LWAPP-3-REPLAY_ERR: 1 wcm: Received replay error on slot 1, WLAN ID 1, count 1 from AP xxxx.xxxx.xxxx||',
- ['device_id'=>1, 'program'=>'%LWAPP-3-REPLAY_ERR', 'msg'=>'1 wcm: Received replay error on slot 1, WLAN ID 1, count 1 from AP xxxx.xxxx.xxxx']
+ ['device_id' => 1, 'program' => '%LWAPP-3-REPLAY_ERR', 'msg' => '1 wcm: Received replay error on slot 1, WLAN ID 1, count 1 from AP xxxx.xxxx.xxxx']
);
}
@@ -152,45 +152,45 @@ class SyslogTest extends TestCase
// ---- PAM ----
$this->checkSyslog(
'1.1.1.1||authpriv||info||info||56||2016-02-28 00:23:34||pam_unix(cron:session): session opened for user librenms by (uid=0)||CRON',
- ['device_id'=>1, 'program'=>'CRON', 'msg'=>'pam_unix(cron:session): session opened for user librenms by (uid=0)']
+ ['device_id' => 1, 'program' => 'CRON', 'msg' => 'pam_unix(cron:session): session opened for user librenms by (uid=0)']
);
$this->checkSyslog(
'1.1.1.1||authpriv||info||info||55||2016-02-28 00:23:34||pam_unix(sudo:session): session opened for user librenms by root (uid=0)||sudo',
- ['device_id'=>1, 'program'=>'SUDO', 'msg'=>'pam_unix(sudo:session): session opened for user librenms by root (uid=0)']
+ ['device_id' => 1, 'program' => 'SUDO', 'msg' => 'pam_unix(sudo:session): session opened for user librenms by root (uid=0)']
);
$this->checkSyslog(
'1.1.1.1||auth||info||info||0e||2016-02-28 00:23:34||pam_krb5(sshd:auth): authentication failure; logname=root uid=0 euid=0 tty=ssh ruser= rhost=123.213.132.231||sshd',
- ['device_id'=>1, 'program'=>'SSHD', 'msg'=>'pam_krb5(sshd:auth): authentication failure; logname=root uid=0 euid=0 tty=ssh ruser= rhost=123.213.132.231']
+ ['device_id' => 1, 'program' => 'SSHD', 'msg' => 'pam_krb5(sshd:auth): authentication failure; logname=root uid=0 euid=0 tty=ssh ruser= rhost=123.213.132.231']
);
$this->checkSyslog(
'1.1.1.1||auth||info||info||0e||2016-02-28 00:23:34||pam_krb5[sshd:auth]: authentication failure; logname=root uid=0 euid=0 tty=ssh ruser= rhost=123.213.132.231||sshd',
- ['device_id'=>1, 'program'=>'SSHD', 'msg'=>'pam_krb5[sshd:auth]: authentication failure; logname=root uid=0 euid=0 tty=ssh ruser= rhost=123.213.132.231']
+ ['device_id' => 1, 'program' => 'SSHD', 'msg' => 'pam_krb5[sshd:auth]: authentication failure; logname=root uid=0 euid=0 tty=ssh ruser= rhost=123.213.132.231']
);
// ---- Postfix ----
$this->checkSyslog(
'1.1.1.1||mail||info||info||16||2016-02-28 00:23:34||5C62E329EF: to=
, relay=mail.example.com[127.0.0.1]:25, delay=0.11, delays=0.04/0.01/0/0.06, dsn=2.0.0, status=sent (250 2.0.0 Ok: queued as 5362E6A670E)||postfix/smtp',
- ['device_id'=>1, 'program'=>'POSTFIX/SMTP', 'msg'=>'5C62E329EF: to=, relay=mail.example.com[127.0.0.1]:25, delay=0.11, delays=0.04/0.01/0/0.06, dsn=2.0.0, status=sent (250 2.0.0 Ok: queued as 5362E6A670E)']
+ ['device_id' => 1, 'program' => 'POSTFIX/SMTP', 'msg' => '5C62E329EF: to=, relay=mail.example.com[127.0.0.1]:25, delay=0.11, delays=0.04/0.01/0/0.06, dsn=2.0.0, status=sent (250 2.0.0 Ok: queued as 5362E6A670E)']
);
$this->checkSyslog(
'1.1.1.1||mail||info||info||16||2016-02-28 00:23:34||D7256400EF: from=, size=882, nrcpt=1 (queue active)||postfix/qmgr',
- ['device_id'=>1, 'program'=>'POSTFIX/QMGR', 'msg'=>'D7256400EF: from=, size=882, nrcpt=1 (queue active)']
+ ['device_id' => 1, 'program' => 'POSTFIX/QMGR', 'msg' => 'D7256400EF: from=, size=882, nrcpt=1 (queue active)']
);
// ---- No program ----
$this->checkSyslog(
'1.1.1.1||user||info||info||0e||2016-02-28 00:23:34||some random message||',
- ['device_id'=>1, 'program'=>'USER', 'msg'=>'some random message']
+ ['device_id' => 1, 'program' => 'USER', 'msg' => 'some random message']
);
// ---- Other ----
$this->checkSyslog(
'1.1.1.1||cron||info||info||4e||2016-02-28 00:23:34||(librenms) CMD ( /opt/librenms/alerts.php >> /var/log/librenms_alert.log 2>&1)||CRON',
- ['device_id'=>1, 'program'=>'CRON', 'msg'=>'(librenms) CMD ( /opt/librenms/alerts.php >> /var/log/librenms_alert.log 2>&1)']
+ ['device_id' => 1, 'program' => 'CRON', 'msg' => '(librenms) CMD ( /opt/librenms/alerts.php >> /var/log/librenms_alert.log 2>&1)']
);
$this->checkSyslog(
'1.1.1.1||authpriv||notice||notice||55||2016-02-28 00:23:34|| root : TTY=pts/1 ; PWD=/opt/librenms ; USER=librenms ; COMMAND=/usr/bin/git status||sudo',
- ['device_id'=>1, 'program'=>'SUDO', 'msg'=>'root : TTY=pts/1 ; PWD=/opt/librenms ; USER=librenms ; COMMAND=/usr/bin/git status']
+ ['device_id' => 1, 'program' => 'SUDO', 'msg' => 'root : TTY=pts/1 ; PWD=/opt/librenms ; USER=librenms ; COMMAND=/usr/bin/git status']
);
}
@@ -203,29 +203,29 @@ class SyslogTest extends TestCase
// ---- 2900/2910/3800/5400 ----
$this->checkSyslog(
'1.1.1.1||user||info||info||0e||2016-02-28 00:23:34||chassis: Slot A Ready||00422',
- ['device_id'=>1, 'program'=>'CHASSIS', 'msg'=>'Slot A Ready [00422]']
+ ['device_id' => 1, 'program' => 'CHASSIS', 'msg' => 'Slot A Ready [00422]']
);
$this->checkSyslog(
'1.1.1.1||user||info||info||0e||2016-02-28 00:23:34||ports: port 21 is now on-line||00076',
- ['device_id'=>1, 'program'=>'PORTS', 'msg'=>'port 21 is now on-line [00076]']
+ ['device_id' => 1, 'program' => 'PORTS', 'msg' => 'port 21 is now on-line [00076]']
);
$this->checkSyslog(
'1.1.1.1||user||info||info||0e||2016-02-28 00:23:34||ports: port 21 is now off-line||00077',
- ['device_id'=>1, 'program'=>'PORTS', 'msg'=>'port 21 is now off-line [00077]']
+ ['device_id' => 1, 'program' => 'PORTS', 'msg' => 'port 21 is now off-line [00077]']
);
$this->checkSyslog(
'1.1.1.1||user||warning||warning||0c||2016-02-28 00:23:34||FFI: port 21-High collision or drop rate. See help.||00331',
- ['device_id'=>1, 'program'=>'FFI', 'msg'=>'port 21-High collision or drop rate. See help. [00331]']
+ ['device_id' => 1, 'program' => 'FFI', 'msg' => 'port 21-High collision or drop rate. See help. [00331]']
);
// ---- 2610 ----
$this->checkSyslog(
'1.1.1.1||user||warning||warning||0c||2016-02-28 00:23:34||port 21-Excessive undersized/giant packets. See help.||FFI',
- ['device_id'=>1, 'program'=>'FFI', 'msg'=>'port 21-Excessive undersized/giant packets. See help.']
+ ['device_id' => 1, 'program' => 'FFI', 'msg' => 'port 21-Excessive undersized/giant packets. See help.']
);
$this->checkSyslog(
'1.1.1.1||user||info||info||0e||2016-02-28 00:23:34||updated time by -4 seconds||SNTP',
- ['device_id'=>1, 'program'=>'SNTP', 'msg'=>'updated time by -4 seconds']
+ ['device_id' => 1, 'program' => 'SNTP', 'msg' => 'updated time by -4 seconds']
);
}
@@ -238,7 +238,7 @@ class SyslogTest extends TestCase
// ---- USG60W ----
$this->checkSyslog(
'1.1.1.1||local1||info||info||8e||2017-06-14 17:51:25||0" dst="0.0.0.0:0" msg="DHCP server assigned 195.159.132.109 to Chromecast(6C:AD:F8:B1:10:1D)" note="DHCP ACK" user="unknown" devID="a0e4cb7d7f52" cat="DHCP"||src="0.0.0.0',
- ['device_id'=>1, 'program'=>'DHCP', 'msg'=>'src="0.0.0.0:0" dst="0.0.0.0:0" msg="DHCP server assigned 195.159.132.109 to Chromecast(6C:AD:F8:B1:10:1D)" note="DHCP ACK" user="unknown" devID="a0e4cb7d7f52" cat="DHCP"']
+ ['device_id' => 1, 'program' => 'DHCP', 'msg' => 'src="0.0.0.0:0" dst="0.0.0.0:0" msg="DHCP server assigned 195.159.132.109 to Chromecast(6C:AD:F8:B1:10:1D)" note="DHCP ACK" user="unknown" devID="a0e4cb7d7f52" cat="DHCP"']
);
}
}