Files
librenms-librenms/html/pages/apps.inc.php
VVelox 6cf5add528 feature: add fail2ban application support (#5924)
* add single pool based poller for php-fpm

* add the page for php-fpm

* add graph for php-fpm

* I agree to the conditions of the Contributor Agreement contained in doc/General/Contributing.md.

* use named OID as suggest by @laf

* document PHP-FPM monitoring

* link it in the index

* clean up the named oid

* add how to grab the script in question

* add f2b poller

* add f2b app page

* add f2b graph

* add fail2ban notes

* minor formatting cleanup

* ...more formatting cleanup

* rename it so it can be called via the app page

* Revert "rename it so it can be called via the app page"

This reverts commit 0bde88a038.

* *rename it so it can be called via the apps page
*setup the apps page to call it

* renamed the graph

* now include fail2ban in the apps properly

* correct the wget command so it does not stomp on phpfpm-sp

* update the fail2ban poller for the newest fail2ban script and now build multiple RRDs

* update for now graphing firewalled and banned

* update fail2ban docs to match the newest snmpd extend method

* search automatically for jails and graph them

* graphs the currently banned for a fail2ban jail

* change the tital of the graph for the total banned to make it more descriptive

* Add a explanation of the two variables in the total graph.

* misc. white space cleans ups

* misc. white space cleanup

* minor white space cleanup

* correct descr lenght

* correct descr lenght

* Update fail2ban.inc.php

* Use rrd_name properly

* note the cache file bits

* make caching optional and note why

* Update to new RrdDefinition class

* And the use statement ;/

* Messed the second rrd_def

* correct two minor errors that did not seem to be causing issues

* don't use $vars as per pull #5994

* don't use $vars as per pull #5994

* fix jails graphs

* Remove loops and temp variables

* whitespace

* Change graph so we don't get fractions
2017-02-24 11:50:33 -06:00

183 lines
2.7 KiB
PHP

<?php
$graphs['apache'] = array(
'bits',
'hits',
'scoreboard',
'cpu',
);
$graphs['drbd'] = array(
'disk_bits',
'network_bits',
'queue',
'unsynced',
);
$graphs['mysql'] = array(
'network_traffic',
'connections',
'command_counters',
'select_types',
);
$graphs['memcached'] = array(
'bits',
'commands',
'data',
'items',
);
$graphs['nginx'] = array(
'connections',
'req',
);
$graphs['powerdns-recursor'] = array(
'questions',
'answers',
'cache_performance',
'outqueries'
);
$graphs['rrdcached'] = array(
'queue_length',
'events',
'tree',
'journal'
);
$graphs['bind'] = array('queries');
$graphs['tinydns'] = array(
'queries',
'errors',
'dnssec',
'other',
);
$graphs['powerdns'] = array(
'latency',
'fail',
'packetcache',
'querycache',
'recursing',
'queries',
'queries_udp',
);
$graphs['ntp-client'] = array(
'stats',
'freq',
);
$graphs['ntp-server'] = array(
'stats',
'freq',
'stratum',
'buffer',
'bits',
'packets',
'uptime',
);
$graphs['nfs-v3-stats'] = array(
'stats',
'io',
'fh',
'rc',
'ra',
'net',
'rpc',
);
$graphs['os-updates'] = array(
'packages',
);
$graphs['dhcp-stats'] = array(
'stats',
);
$graphs['fail2ban'] = array(
'banned',
);
$graphs['freeswitch'] = array(
'peak',
'callsIn',
'callsOut',
);
$graphs['ups-nut'] = array(
'remaining',
'load',
'voltage_battery',
'charge',
'voltage_input',
);
$graphs['ups-apcups'] = array(
'remaining',
'load',
'voltage_battery',
'charge',
'voltage_input',
);
$graphs['gpsd'] = array(
'satellites',
'dop',
'mode',
);
$graphs['exim-stats'] = array(
'frozen',
'queue'
);
$graphs['php-fpm'] = array(
'stats'
);
print_optionbar_start();
echo "<span style='font-weight: bold;'>Apps</span> &#187; ";
unset($sep);
$link_array = array(
'page' => 'device',
'device' => $device['device_id'],
'tab' => 'apps',
);
foreach ($app_list as $app) {
echo $sep;
if ($vars['app'] == $app['app_type']) {
echo "<span class='pagemenu-selected'>";
}
echo generate_link(nicecase($app['app_type']), array('page' => 'apps', 'app' => $app['app_type']));
if ($vars['app'] == $app['app_type']) {
echo '</span>';
}
$sep = ' | ';
}
print_optionbar_end();
if ($vars['app']) {
if (is_file('pages/apps/'.mres($vars['app']).'.inc.php')) {
include 'pages/apps/'.mres($vars['app']).'.inc.php';
} else {
include 'pages/apps/default.inc.php';
}
} else {
include 'pages/apps/overview.inc.php';
}
$pagetitle[] = 'Apps';