예제 #1
0
파일: hmib.php 프로젝트: Cacti/plugin_hmib
 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the           |
 | GNU General Public License for more details.                            |
 +-------------------------------------------------------------------------+
 | Cacti: The Complete RRDTool-based Graphing Solution                     |
 +-------------------------------------------------------------------------+
 | This code is designed, written, and maintained by the Cacti Group. See  |
 | about.php and/or the AUTHORS file for specific developer information.   |
 +-------------------------------------------------------------------------+
 | http://www.cacti.net/                                                   |
 +-------------------------------------------------------------------------+
*/
chdir('../../');
include './include/auth.php';
set_default_action('summary');
if (get_request_var('action') == 'ajax_hosts') {
    get_allowed_ajax_hosts(true, false, 'h.id IN (SELECT host_id FROM plugin_hmib_hrSystem)');
    exit;
}
$hmib_hrSWTypes = array(0 => __('Error'), 1 => __('Unknown'), 2 => __('Operating System'), 3 => __('Device Driver'), 4 => __('Application'));
$hmib_hrSWRunStatus = array(1 => __('Running'), 2 => __('Runnable'), 3 => __('Not Runnable'), 4 => __('Invalid'));
$hmib_hrDeviceStatus = array(0 => __('Present'), 1 => __('Unknown'), 2 => __('Running'), 3 => __('Warning'), 4 => __('Testing'), 5 => __('Down'));
$hmib_types = array_rekey(db_fetch_assoc('SELECT *
	FROM plugin_hmib_types
	ORDER BY description'), 'id', 'description');
general_header();
hmib_tabs();
switch (get_request_var('action')) {
    case 'summary':
        hmib_summary();
        break;
    case 'running':
예제 #2
0
chdir('../../');
include_once './include/auth.php';
include_once $config['base_path'] . '/plugins/thold/thold_functions.php';
include_once $config['base_path'] . '/plugins/thold/setup.php';
include_once $config['base_path'] . '/plugins/thold/includes/database.php';
include $config['base_path'] . '/plugins/thold/includes/arrays.php';
thold_initialize_rusage();
plugin_thold_upgrade();
delete_old_thresholds();
set_default_action('thold');
switch (get_request_var('action')) {
    case 'ajax_hosts':
        get_allowed_ajax_hosts(true, false, 'h.id IN (SELECT host_id FROM thold_data)');
        break;
    case 'ajax_hosts_noany':
        get_allowed_ajax_hosts(false, false, 'h.id IN (SELECT host_id FROM thold_data)');
        break;
    case 'thold':
        general_header();
        thold_tabs();
        tholds();
        bottom_footer();
        break;
    case 'disable':
        thold_threshold_disable(get_filter_request_var('id'));
        header('Location: thold_graph.php');
        exit;
    case 'enable':
        thold_threshold_enable(get_filter_request_var('id'));
        header('Location: thold_graph.php');
        exit;
예제 #3
0
 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the           |
 | GNU General Public License for more details.                            |
 +-------------------------------------------------------------------------+
 | Cacti: The Complete RRDTool-based Graphing Solution                     |
 +-------------------------------------------------------------------------+
 | This code is designed, written, and maintained by the Cacti Group. See  |
 | about.php and/or the AUTHORS file for specific developer information.   |
 +-------------------------------------------------------------------------+
 | http://www.cacti.net/                                                   |
 +-------------------------------------------------------------------------+
*/
chdir('../../');
include './include/auth.php';
set_default_action('devices');
if (isset_request_var('action') && get_request_var('action') == 'ajax_hosts') {
    get_allowed_ajax_hosts();
    exit;
}
general_header();
$mikrotik_hrDeviceStatus = array(0 => __('Present'), 1 => __('Unknown'), 2 => __('Running'), 3 => __('Warning'), 4 => __('Testing'), 5 => __('Down'));
mikrotik_tabs();
switch (get_request_var('action')) {
    case 'devices':
        mikrotik_devices();
        break;
    case 'trees':
        mikrotik_trees();
        break;
    case 'queues':
        mikrotik_queues();
        break;