Systemd Application Code Cleanup and new Systemd Unit State Metrics. (#15848)

This commit is contained in:
bnerickson 2024-03-04 14:58:28 -08:00 committed by GitHub
parent c83d362e59
commit 0998592e1f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
13 changed files with 508 additions and 264 deletions

View File

@ -30,7 +30,7 @@ if (Rrd::checkRrdExists($rrd_filename)) {
];
}
} else {
d_echo('RRD ' . $rrd_filename . ' not found');
graph_error('No Data file ' . basename($rrd_filename), 'No Data');
}
require 'includes/html/graphs/generic_multi_line_exact_numbers.inc.php';

View File

@ -16,12 +16,16 @@ if (isset($vars['sn'])) {
$rrd_list = [];
if (! $sn_list) {
graph_error('No Data to Display', 'No Data');
}
$i = 0;
$j = 0;
while (isset($sn_list[$i])) {
$sn = $sn_list[$i];
$rrd_filename = Rrd::name($device['hostname'], ['app', $name, $app->app_id, $sn]);
$j = 0;
if (Rrd::checkRrdExists($rrd_filename)) {
foreach ($rrdArray as $ds => $var) {
$rrd_list[$j]['filename'] = $rrd_filename;
@ -29,6 +33,8 @@ while (isset($sn_list[$i])) {
$rrd_list[$j]['ds'] = $ds;
$j++;
}
} else {
graph_error('No Data file ' . basename($rrd_filename), 'No Data');
}
$i++;
}

View File

@ -11,8 +11,13 @@ $smalldescrlen = 20;
$rrd_list = [];
if (! $rrdArray) {
graph_error('No Data to Display', 'No Data');
}
$i = 0;
foreach (array_keys($rrdArray) as $state_type) {
$rrd_filename = Rrd::name($device['hostname'], [
$shared_rrd_filename = Rrd::name($device['hostname'], [
$polling_type,
$name,
$app->app_id,
@ -20,15 +25,25 @@ foreach (array_keys($rrdArray) as $state_type) {
]);
if (Rrd::checkRrdExists($rrd_filename)) {
$i = 0;
foreach ($rrdArray[$state_type] as $state_status => $state_status_desc) {
$rrd_list[$i]['filename'] = $rrd_filename;
$rrd_list[$i]['descr'] = $state_status_desc['descr'];
foreach ($rrdArray[$state_type] as $state_status => $state_status_aa) {
if ($state_status_aa['rrd_location'] === 'individual') {
$individual_rrd_filename = Rrd::name($device['hostname'], [
$polling_type,
$name,
$app->app_id,
$state_type,
$state_status,
]);
$rrd_list[$i]['filename'] = $individual_rrd_filename;
} else {
$rrd_list[$i]['filename'] = $shared_rrd_filename;
}
$rrd_list[$i]['descr'] = $state_status_aa['descr'];
$rrd_list[$i]['ds'] = $state_status;
$i++;
}
} else {
d_echo('RRD ' . $rrd_filename . ' not found');
graph_error('No Data file ' . basename($rrd_filename), 'No Data');
}
}

View File

@ -3,8 +3,13 @@
require_once 'includes/systemd-shared.inc.php';
$rrdArray = [];
foreach ($systemd_mapper['active'] as $state_status) {
$rrdArray['active'][$state_status] = ['descr' => $state_status];
$state_type = 'active';
foreach ($systemd_mapper[$state_type] as $state_status => $rrd_location) {
$rrdArray[$state_type][$state_status] = [
'descr' => $state_status,
'rrd_location' => $rrd_location,
];
}
require 'systemd-common.inc.php';

View File

@ -0,0 +1,19 @@
<?php
require_once 'includes/systemd-shared.inc.php';
$rrdArray = [];
foreach ($systemd_mapper as $flattened_type => $state_statuses) {
foreach (
$systemd_mapper[$flattened_type]
as $state_status => $rrd_location
) {
$rrdArray[$flattened_type][$state_status] = [
'descr' => $flattened_type . '_' . $state_status,
'rrd_location' => $rrd_location,
];
}
}
require 'systemd-common.inc.php';

View File

@ -3,8 +3,13 @@
require_once 'includes/systemd-shared.inc.php';
$rrdArray = [];
foreach ($systemd_mapper['load'] as $state_status) {
$rrdArray['load'][$state_status] = ['descr' => $state_status];
$state_type = 'load';
foreach ($systemd_mapper[$state_type] as $state_status => $rrd_location) {
$rrdArray[$state_type][$state_status] = [
'descr' => $state_status,
'rrd_location' => $rrd_location,
];
}
require 'systemd-common.inc.php';

View File

@ -3,19 +3,44 @@
require_once 'includes/systemd-shared.inc.php';
$rrdArray = [];
$state_type = 'sub';
// This pulls the service sub state type
// given by the opened page. Otherwise, 'service'
// is the default for the Application overview
// pages.
$sub_state_type = $vars['sub_state_type'] ?? 'service';
if (isset($vars['sub_state_type'])) {
// This section draws the individual graphs in the device application page
// displaying the SPECIFIED service type's sub states.
$flattened_type = $vars['sub_state_type'];
$sub_flattened_name = 'sub_' . $sub_state_type;
foreach (
$systemd_mapper[$flattened_type]
as $sub_state_status => $rrd_location
) {
$rrdArray[$flattened_type][$sub_state_status] = [
'descr' => $sub_state_status,
'rrd_location' => $rrd_location,
];
}
} else {
// This section draws the graph for the application-specific pages
// displaying ALL of the service type's sub states.
foreach ($systemd_mapper as $flattened_type => $state_statuses) {
// Ternary-depth systemd type check.
if (! preg_match('/^(.+)_(.+)$/', $flattened_type, $regex_matches)) {
continue;
}
if ($regex_matches[1] !== $state_type) {
continue;
}
foreach ($systemd_mapper['sub'][$sub_state_type] as $sub_state_status) {
$rrdArray[$sub_flattened_name][$sub_state_status] = [
'descr' => $sub_state_status,
];
foreach (
$systemd_mapper[$flattened_type]
as $sub_state_status => $rrd_location
) {
$rrdArray[$flattened_type][$sub_state_status] = [
'descr' => $flattened_type . '_' . $sub_state_status,
'rrd_location' => $rrd_location,
];
}
}
}
require 'systemd-common.inc.php';

View File

@ -450,6 +450,7 @@ $graphs['pwrstatd'] = [
'minutes',
];
$graphs['systemd'] = [
'all',
'sub',
'active',
'load',

View File

@ -11,17 +11,32 @@ require_once 'includes/systemd-shared.inc.php';
* @param array $graphs
* @return $graphs
*/
function systemd_graph_builder($state_type, $systemd_mapper, $state_type_ternary_depth, $graphs)
{
function systemd_graph_builder(
$state_type,
$systemd_mapper,
$state_type_ternary_depth,
$graphs
) {
$graph_name = 'systemd_' . $state_type;
$graphs[$graph_name]['type'] = $state_type;
if (! in_array($state_type, $state_type_ternary_depth)) {
$graph_descr = ucfirst($state_type . ' State');
$graphs[$graph_name]['desc'] = $graph_descr;
} else {
foreach ($systemd_mapper[$state_type] as $sub_state_type => $sub_state_statuses) {
$graph_descr = ucfirst($state_type) . ' ' . ucfirst($sub_state_type) . ' State';
$graphs[$graph_name]['sub_states'][$sub_state_type]['desc'] = $graph_descr;
foreach ($systemd_mapper as $flattened_type => $state_statuses) {
// Ternary-depth systemd type check.
if (! preg_match('/^(.+)_(.+)$/', $flattened_type, $regex_matches)) {
continue;
}
if ($regex_matches[1] !== $state_type) {
continue;
}
$graph_descr = ucfirst($flattened_type) . ' State';
$graphs[$graph_name]['sub_states'][$flattened_type][
'desc'
] = $graph_descr;
}
}
@ -36,8 +51,12 @@ function systemd_graph_builder($state_type, $systemd_mapper, $state_type_ternary
* @param null|string $sub_state_type
* @param string $graph_desc
*/
function systemd_graph_printer($state_type, $app_id, $sub_state_type, $graph_desc)
{
function systemd_graph_printer(
$state_type,
$app_id,
$sub_state_type,
$graph_desc
) {
$graph_type = $state_type;
$graph_array['height'] = '100';
$graph_array['width'] = '215';
@ -73,11 +92,15 @@ print_optionbar_start();
echo generate_link('All Unit States', $link_array) . ' | ';
$i = 0;
foreach ($systemd_mapper as $state_type => $state_statuses) {
echo generate_link(ucfirst($state_type) . ' State', $link_array, ['section' => $state_type]);
if ($i < count($systemd_mapper) - 1) {
foreach ($systemd_state_types as $state_type) {
echo generate_link(ucfirst($state_type) . ' State', $link_array, [
'section' => $state_type,
]);
if ($i < count($systemd_state_types) - 1) {
echo ', ';
}
$i++;
}
@ -88,11 +111,21 @@ $graphs = [];
// Build graphs variable
if (isset($vars['section'])) {
// Build graphs for the individual state sections (load, active, or sub).
$graphs = systemd_graph_builder($vars['section'], $systemd_mapper, $state_type_ternary_depth, $graphs);
$graphs = systemd_graph_builder(
$vars['section'],
$systemd_mapper,
$state_type_ternary_depth,
$graphs
);
} else {
// Build graphs for the combined states section (load, active, and sub).
foreach ($systemd_mapper as $state_type => $state_status) {
$graphs = systemd_graph_builder($state_type, $systemd_mapper, $state_type_ternary_depth, $graphs);
foreach ($systemd_state_types as $state_type) {
$graphs = systemd_graph_builder(
$state_type,
$systemd_mapper,
$state_type_ternary_depth,
$graphs
);
}
}
@ -100,9 +133,19 @@ if (isset($vars['section'])) {
foreach ($graphs as $state_type => $values) {
if (in_array($values['type'], $state_type_ternary_depth)) {
foreach ($values['sub_states'] as $sub_state_type => $text) {
systemd_graph_printer($state_type, $app['app_id'], $sub_state_type, $text['desc']);
systemd_graph_printer(
$state_type,
$app['app_id'],
$sub_state_type,
$text['desc']
);
}
} else {
systemd_graph_printer($state_type, $app['app_id'], null, $values['desc']);
systemd_graph_printer(
$state_type,
$app['app_id'],
null,
$values['desc']
);
}
}

View File

@ -27,10 +27,31 @@ if (! function_exists('systemd_data_update_helper')) {
* @param string $state_type
* @return $metrics
*/
function systemd_data_update_helper($device, $app_id, $fields, $metrics, $name, $polling_type, $rrd_def, $state_type)
{
$rrd_name = [$polling_type, $name, $app_id, $state_type];
$metrics[$state_type] = $fields;
function systemd_data_update_helper(
$device,
$app_id,
$fields,
$metrics,
$name,
$polling_type,
$rrd_def,
$state_type,
$rrd_flattened_name
) {
$rrd_flattened_name = is_null($rrd_flattened_name)
? $state_type
: $rrd_flattened_name;
$rrd_name = [$polling_type, $name, $app_id, $rrd_flattened_name];
// This if block allows metric names to be kept consistent
// regardless of whether the metric is stored in an shared
// or individual RRD.
if (isset($metrics[$state_type])) {
$metrics[$state_type] = array_merge($metrics[$state_type], $fields);
} else {
$metrics[$state_type] = $fields;
}
$tags = [
'name' => $name,
'app_id' => $app_id,
@ -50,7 +71,13 @@ try {
} catch (JsonAppMissingKeysException $e) {
$systemd_data = $e->getParsedJson();
} catch (JsonAppException $e) {
echo PHP_EOL . $name . ':' . $e->getCode() . ':' . $e->getMessage() . PHP_EOL;
echo PHP_EOL .
$name .
':' .
$e->getCode() .
':' .
$e->getMessage() .
PHP_EOL;
update_application($app, $e->getCode() . ':' . $e->getMessage(), $metrics);
return;
@ -59,62 +86,85 @@ try {
// Use the mapping variable in systemd-shared.inc.php to parse
// the json data received from the systemd.py script.
foreach ($systemd_mapper as $state_type => $state_statuses) {
if (! in_array($state_type, $state_type_ternary_depth)) {
// Process systemd states that do not have three
// levels of depth (load and active)
$shared_rrd_def = RrdDefinition::make();
$shared_fields = [];
$sub_state_type = null;
$flattened_type = $state_type;
$rrd_def = RrdDefinition::make();
$fields = [];
// Iterate through unit state type's statuses.
foreach ($systemd_mapper[$state_type] as $state_status) {
$field_name = $state_status;
$field_value = $systemd_data[$state_type][$state_status] ?? null;
// Verify data passed by application script is valid.
// Update fields and rrd definition.
if (is_int($field_value) || is_null($field_value)) {
$fields[$field_name] = $field_value;
} else {
$log_message = 'Systemd Polling Warning: Invalid data returned by application for systemd unit ' .
$state_type . ' state with' . $state_status . ' state status: ' . $field_value;
log_event($log_message, $device, 'application');
continue;
}
$rrd_def->addDataset($field_name, 'GAUGE', 0);
}
$metrics = systemd_data_update_helper($device, $app->app_id, $fields, $metrics, $name, $polling_type, $rrd_def, $state_type);
} else {
// Process systemd states that have three
// levels of depth (sub)
// Iterate through unit sub state types.
foreach ($systemd_mapper[$state_type] as $sub_state_type => $sub_state_statuses) {
$rrd_def = RrdDefinition::make();
$fields = [];
// Iterate through unit sub state type's statuses.
foreach ($sub_state_statuses as $sub_state_status) {
$field_name = $sub_state_status;
$field_value = $systemd_data[$state_type][$sub_state_type][$sub_state_status] ?? null;
// Verify data passed by application script is valid.
// Update fields and rrd definition.
if (is_int($field_value) || is_null($field_value)) {
$fields[$field_name] = $field_value;
} else {
$log_message = 'Systemd Polling Warning: Invalid data returned by application for systemd unit ' .
$state_type . ' state with ' . $sub_state_type . ' sub state type with ' . $sub_state_status .
' sub state status: ' . $field_value;
log_event($log_message, $device, 'application');
continue;
}
$rrd_def->addDataset($field_name, 'GAUGE', 0);
}
$flat_type = $state_type . '_' . $sub_state_type;
$metrics = systemd_data_update_helper($device, $app->app_id, $fields, $metrics, $name, $polling_type, $rrd_def, $flat_type);
// Ternary-depth systemd type check.
if (preg_match('/^(.+)_(.+)$/', $state_type, $regex_matches)) {
if (! in_array($regex_matches[1], $state_type_ternary_depth)) {
continue;
}
$state_type = $regex_matches[1];
$sub_state_type = $regex_matches[2];
}
// Iterate through unit state type's statuses.
foreach ($state_statuses as $state_status => $rrd_location) {
$field_value = null;
$field_name = $state_status;
if (is_null($sub_state_type)) {
$field_value = $systemd_data[$state_type][$state_status] ?? null;
} else {
$field_value =
$systemd_data[$state_type][$sub_state_type][$state_status] ??
null;
}
// Verify data passed by application script is valid.
if (! is_int($field_value) && ! is_null($field_value)) {
$log_message =
'Systemd Polling Warning: Invalid data returned by application for systemd unit ' .
$flattened_type .
' state with' .
$state_status .
' state status: ' .
$field_value;
log_event($log_message, $device, 'application');
continue;
}
// New metrics MUST use the 'individual' type because
// it is not possible to automatically update 'shared'
// RRDs with new metrics.
if ($rrd_location === 'individual') {
$individual_fields = [];
$individual_rrd_def = RrdDefinition::make();
$individual_fields[$field_name] = $field_value;
$individual_rrd_def->addDataset($field_name, 'GAUGE', 0);
$rrd_flattened_type = $flattened_type . '-' . $field_name;
$metrics = systemd_data_update_helper(
$device,
$app->app_id,
$individual_fields,
$metrics,
$name,
$polling_type,
$individual_rrd_def,
$flattened_type,
$rrd_flattened_type
);
continue;
}
// Update shared_fields and rrd definition.
$shared_fields[$field_name] = $field_value;
$shared_rrd_def->addDataset($field_name, 'GAUGE', 0);
}
$metrics = systemd_data_update_helper(
$device,
$app->app_id,
$shared_fields,
$metrics,
$name,
$polling_type,
$shared_rrd_def,
$flattened_type,
null
);
}
update_application($app, $output, $metrics);

View File

@ -1,157 +1,184 @@
<?php
// The 'load' and 'active' states only have
// two layers of depth in the systemd_mapper
// associative array. The 'sub' state has three
// two layers of depth in the systemd data returned
// by the snmp script. The 'sub' state has three
// layers. If another state type is introduced
// with three layers it must be added here.
// with three layers it must be added to the list
// here.
$state_type_ternary_depth = ['sub'];
// Global variable used by the systemd application to
// build graphs, rrd names and descripts, and parse
// the systemd.py script results.
// Any new systemd state types MUST be added to this list.
$systemd_state_types = ['load', 'active', 'sub'];
// Associative array used by the systemd application to
// build graphs, rrd names and descriptions, and parse
// the systemd.py script results. Currently "load",
// "active", and "sub" are valid systemd state types.
// Originally, this application used a shared RRD file
// for each systemd state type. However, LibreNMS does
// not support adding new metrics to existing RRDs.
// Therefore, existing metrics are now associated with
// the "shared" string and any NEW metrics/state statuses
// added to the associative array below MUST specify the
// "individual" moniker. This will create a NEW RRD file
// for the new metric. For example, the "start" sub
// service state status was added originally and the
// metric is stored in the following RRD:
// app-systemd-132-sub_service.rrd
// However the "dead-before-auto-restart" sub service
// state status was added after the fact and a new RRD
// file name is stored with the new format:
// app-systemd-132-sub_service-dead-before-auto-restart.rrd
//
$systemd_mapper = [
'load' => [
'stub',
'loaded',
'not-found',
'bad-setting',
'error',
'merged',
'masked',
'total',
'stub' => 'shared',
'loaded' => 'shared',
'not-found' => 'shared',
'bad-setting' => 'shared',
'error' => 'shared',
'merged' => 'shared',
'masked' => 'shared',
'total' => 'shared',
],
'active' => [
'active',
'reloading',
'inactive',
'failed',
'activating',
'deactivating',
'maintenance',
'total',
'active' => 'shared',
'reloading' => 'shared',
'inactive' => 'shared',
'failed' => 'shared',
'activating' => 'shared',
'deactivating' => 'shared',
'maintenance' => 'shared',
'total' => 'shared',
],
'sub' => [
'automount' => [
'dead',
'waiting',
'running',
'failed',
'total',
],
'device' => [
'dead',
'tentative',
'plugged',
'total',
],
'freezer' => [
'running',
'freezing',
'frozen',
'thawing',
'total',
],
'mount' => [
'dead',
'mounting',
'mounting-done',
'mounted',
'remounting',
'unmounting',
'remounting-sigterm',
'remounting-sigkill',
'unmounting-sigterm',
'unmounting-sigkill',
'failed',
'cleaning',
'total',
],
'path' => [
'dead',
'waiting',
'running',
'failed',
'total',
],
'scope' => [
'dead',
'start-chown',
'running',
'abandoned',
'stop-sigterm',
'stop-sigkill',
'failed',
'total',
],
'service' => [
'dead',
'condition',
'start-pre',
'start',
'start-post',
'running',
'exited',
'reload',
'stop',
'stop-watchdog',
'stop-sigterm',
'stop-sigkill',
'stop-post',
'final-watchdog',
'final-sigterm',
'final-sigkill',
'failed',
'auto-restart',
'cleaning',
'total',
],
'slice' => [
'dead',
'active',
'total',
],
'socket' => [
'dead',
'start-pre',
'start-chown',
'start-post',
'listening',
'running',
'stop-pre',
'stop-pre-sigterm',
'stop-pre-sigkill',
'stop-post',
'final-sigterm',
'final-sigkill',
'failed',
'cleaning',
'total',
],
'swap' => [
'dead',
'activating',
'activating-done',
'active',
'deactivating',
'deactivating-sigterm',
'deactivating-sigkill',
'failed',
'cleaning',
'total',
],
'target' => [
'dead',
'active',
'total',
],
'timer' => [
'dead',
'waiting',
'running',
'elapsed',
'failed',
'total',
],
'sub_automount' => [
'dead' => 'shared',
'waiting' => 'shared',
'running' => 'shared',
'failed' => 'shared',
'total' => 'shared',
],
'sub_device' => [
'dead' => 'shared',
'tentative' => 'shared',
'plugged' => 'shared',
'total' => 'shared',
],
'sub_freezer' => [
'running' => 'shared',
'freezing' => 'shared',
'freezing-by-parent' => 'individual',
'frozen' => 'shared',
'frozen-by-parent' => 'individual',
'thawing' => 'shared',
'total' => 'shared',
],
'sub_mount' => [
'dead' => 'shared',
'mounting' => 'shared',
'mounting-done' => 'shared',
'mounted' => 'shared',
'remounting' => 'shared',
'unmounting' => 'shared',
'remounting-sigterm' => 'shared',
'remounting-sigkill' => 'shared',
'unmounting-sigterm' => 'shared',
'unmounting-sigkill' => 'shared',
'failed' => 'shared',
'cleaning' => 'shared',
'total' => 'shared',
],
'sub_path' => [
'dead' => 'shared',
'waiting' => 'shared',
'running' => 'shared',
'failed' => 'shared',
'total' => 'shared',
],
'sub_scope' => [
'dead' => 'shared',
'start-chown' => 'shared',
'running' => 'shared',
'abandoned' => 'shared',
'stop-sigterm' => 'shared',
'stop-sigkill' => 'shared',
'failed' => 'shared',
'total' => 'shared',
],
'sub_service' => [
'dead' => 'shared',
'condition' => 'shared',
'start-pre' => 'shared',
'start' => 'shared',
'start-post' => 'shared',
'running' => 'shared',
'exited' => 'shared',
'reload' => 'shared',
'reload-signal' => 'individual',
'reload-notify' => 'individual',
'stop' => 'shared',
'stop-watchdog' => 'shared',
'stop-sigterm' => 'shared',
'stop-sigkill' => 'shared',
'stop-post' => 'shared',
'final-watchdog' => 'shared',
'final-sigterm' => 'shared',
'final-sigkill' => 'shared',
'failed' => 'shared',
'dead-before-auto-restart' => 'individual',
'failed-before-auto-restart' => 'individual',
'dead-resources-pinned' => 'individual',
'auto-restart' => 'shared',
'auto-restart-queued' => 'individual',
'cleaning' => 'shared',
'total' => 'shared',
],
'sub_slice' => [
'dead' => 'shared',
'active' => 'shared',
'total' => 'shared',
],
'sub_socket' => [
'dead' => 'shared',
'start-pre' => 'shared',
'start-chown' => 'shared',
'start-post' => 'shared',
'listening' => 'shared',
'running' => 'shared',
'stop-pre' => 'shared',
'stop-pre-sigterm' => 'shared',
'stop-pre-sigkill' => 'shared',
'stop-post' => 'shared',
'final-sigterm' => 'shared',
'final-sigkill' => 'shared',
'failed' => 'shared',
'cleaning' => 'shared',
'total' => 'shared',
],
'sub_swap' => [
'dead' => 'shared',
'activating' => 'shared',
'activating-done' => 'shared',
'active' => 'shared',
'deactivating' => 'shared',
'deactivating-sigterm' => 'shared',
'deactivating-sigkill' => 'shared',
'failed' => 'shared',
'cleaning' => 'shared',
'total' => 'shared',
],
'sub_target' => [
'dead' => 'shared',
'active' => 'shared',
'total' => 'shared',
],
'sub_timer' => [
'dead' => 'shared',
'waiting' => 'shared',
'running' => 'shared',
'elapsed' => 'shared',
'failed' => 'shared',
'total' => 'shared',
],
];

View File

@ -5,9 +5,9 @@
{
"sysName": "<private>",
"sysObjectID": ".1.3.6.1.4.1.8072.3.2.10",
"sysDescr": "Linux enemess 4.18.0-408.el8.x86_64 #1 SMP Mon Jul 18 17:42:52 UTC 2022 x86_64",
"sysDescr": "Linux server 3.10.0-693.5.2.el7.x86_64 #1 SMP Fri Oct 20 20:32:50 UTC 2017 x86_64",
"sysContact": "<private>",
"version": "4.18.0-408.el8.x86_64",
"version": "3.10.0-693.5.2.el7.x86_64",
"hardware": "Generic x86 64-bit",
"features": null,
"location": "<private>",
@ -57,7 +57,7 @@
},
{
"metric": "active_active",
"value": 148,
"value": 160,
"value_prev": null,
"app_type": "systemd"
},
@ -93,7 +93,7 @@
},
{
"metric": "active_total",
"value": 148,
"value": 160,
"value_prev": null,
"app_type": "systemd"
},
@ -111,7 +111,7 @@
},
{
"metric": "load_loaded",
"value": 148,
"value": 160,
"value_prev": null,
"app_type": "systemd"
},
@ -141,7 +141,7 @@
},
{
"metric": "load_total",
"value": 148,
"value": 160,
"value_prev": null,
"app_type": "systemd"
},
@ -159,7 +159,7 @@
},
{
"metric": "sub_automount_running",
"value": 0,
"value": 1,
"value_prev": null,
"app_type": "systemd"
},
@ -171,7 +171,7 @@
},
{
"metric": "sub_automount_waiting",
"value": 1,
"value": 0,
"value_prev": null,
"app_type": "systemd"
},
@ -183,7 +183,7 @@
},
{
"metric": "sub_device_plugged",
"value": 22,
"value": 24,
"value_prev": null,
"app_type": "systemd"
},
@ -195,7 +195,7 @@
},
{
"metric": "sub_device_total",
"value": 22,
"value": 24,
"value_prev": null,
"app_type": "systemd"
},
@ -205,12 +205,24 @@
"value_prev": null,
"app_type": "systemd"
},
{
"metric": "sub_freezer_freezing-by-parent",
"value": 0,
"value_prev": null,
"app_type": "systemd"
},
{
"metric": "sub_freezer_frozen",
"value": 0,
"value_prev": null,
"app_type": "systemd"
},
{
"metric": "sub_freezer_frozen-by-parent",
"value": 0,
"value_prev": null,
"app_type": "systemd"
},
{
"metric": "sub_freezer_running",
"value": 0,
@ -249,7 +261,7 @@
},
{
"metric": "sub_mount_mounted",
"value": 12,
"value": 19,
"value_prev": null,
"app_type": "systemd"
},
@ -285,7 +297,7 @@
},
{
"metric": "sub_mount_total",
"value": 12,
"value": 19,
"value_prev": null,
"app_type": "systemd"
},
@ -391,6 +403,12 @@
"value_prev": null,
"app_type": "systemd"
},
{
"metric": "sub_service_auto-restart-queued",
"value": 0,
"value_prev": null,
"app_type": "systemd"
},
{
"metric": "sub_service_cleaning",
"value": 0,
@ -409,9 +427,21 @@
"value_prev": null,
"app_type": "systemd"
},
{
"metric": "sub_service_dead-before-auto-restart",
"value": 0,
"value_prev": null,
"app_type": "systemd"
},
{
"metric": "sub_service_dead-resources-pinned",
"value": 0,
"value_prev": null,
"app_type": "systemd"
},
{
"metric": "sub_service_exited",
"value": 24,
"value": 21,
"value_prev": null,
"app_type": "systemd"
},
@ -421,6 +451,12 @@
"value_prev": null,
"app_type": "systemd"
},
{
"metric": "sub_service_failed-before-auto-restart",
"value": 0,
"value_prev": null,
"app_type": "systemd"
},
{
"metric": "sub_service_final-sigkill",
"value": 0,
@ -445,9 +481,21 @@
"value_prev": null,
"app_type": "systemd"
},
{
"metric": "sub_service_reload-notify",
"value": 0,
"value_prev": null,
"app_type": "systemd"
},
{
"metric": "sub_service_reload-signal",
"value": 0,
"value_prev": null,
"app_type": "systemd"
},
{
"metric": "sub_service_running",
"value": 36,
"value": 35,
"value_prev": null,
"app_type": "systemd"
},
@ -501,13 +549,13 @@
},
{
"metric": "sub_service_total",
"value": 60,
"value": 56,
"value_prev": null,
"app_type": "systemd"
},
{
"metric": "sub_slice_active",
"value": 9,
"value": 11,
"value_prev": null,
"app_type": "systemd"
},
@ -519,7 +567,7 @@
},
{
"metric": "sub_slice_total",
"value": 9,
"value": 11,
"value_prev": null,
"app_type": "systemd"
},
@ -555,7 +603,7 @@
},
{
"metric": "sub_socket_listening",
"value": 5,
"value": 7,
"value_prev": null,
"app_type": "systemd"
},
@ -609,7 +657,7 @@
},
{
"metric": "sub_socket_total",
"value": 11,
"value": 13,
"value_prev": null,
"app_type": "systemd"
},
@ -675,7 +723,7 @@
},
{
"metric": "sub_target_active",
"value": 23,
"value": 25,
"value_prev": null,
"app_type": "systemd"
},
@ -687,7 +735,7 @@
},
{
"metric": "sub_target_total",
"value": 23,
"value": 25,
"value_prev": null,
"app_type": "systemd"
},
@ -717,13 +765,13 @@
},
{
"metric": "sub_timer_total",
"value": 4,
"value": 5,
"value_prev": null,
"app_type": "systemd"
},
{
"metric": "sub_timer_waiting",
"value": 4,
"value": 5,
"value_prev": null,
"app_type": "systemd"
}

View File

@ -1,4 +1,4 @@
1.3.6.1.2.1.1.1.0|4|Linux enemess 4.18.0-408.el8.x86_64 #1 SMP Mon Jul 18 17:42:52 UTC 2022 x86_64
1.3.6.1.2.1.1.1.0|4|Linux server 3.10.0-693.5.2.el7.x86_64 #1 SMP Fri Oct 20 20:32:50 UTC 2017 x86_64
1.3.6.1.2.1.1.2.0|6|1.3.6.1.4.1.8072.3.2.10
1.3.6.1.2.1.1.3.0|67|77550514
1.3.6.1.2.1.1.4.0|4|<private>
@ -7,4 +7,4 @@
1.3.6.1.2.1.25.1.1.0|67|77552962
1.3.6.1.4.1.8072.1.3.2.2.1.21.6.100.105.115.116.114.111|2|1
1.3.6.1.4.1.8072.1.3.2.2.1.21.7.115.121.115.116.101.109.100|2|1
1.3.6.1.4.1.8072.1.3.2.3.1.2.7.115.121.115.116.101.109.100|4x|7b226572726f72537472696e67223a2022222c20226572726f72223a20302c202276657273696f6e223a20312c202264617461223a207b226c6f6164223a207b226c6f61646564223a203134382c2022746f74616c223a203134387d2c2022616374697665223a207b22616374697665223a203134382c2022746f74616c223a203134387d2c2022737562223a207b226175746f6d6f756e74223a207b2277616974696e67223a20312c2022746f74616c223a20317d2c2022646576696365223a207b22706c7567676564223a2032322c2022746f74616c223a2032327d2c20226d6f756e74223a207b226d6f756e746564223a2031322c2022746f74616c223a2031327d2c202270617468223a207b2277616974696e67223a20322c2022746f74616c223a20327d2c202273636f7065223a207b2272756e6e696e67223a20332c2022746f74616c223a20337d2c202273657276696365223a207b2272756e6e696e67223a2033362c2022746f74616c223a2036302c2022657869746564223a2032347d2c2022736c696365223a207b22616374697665223a20392c2022746f74616c223a20397d2c2022736f636b6574223a207b2272756e6e696e67223a20362c2022746f74616c223a2031312c20226c697374656e696e67223a20357d2c202273776170223a207b22616374697665223a20312c2022746f74616c223a20317d2c2022746172676574223a207b22616374697665223a2032332c2022746f74616c223a2032337d2c202274696d6572223a207b2277616974696e67223a20342c2022746f74616c223a20347d7d7d7d0a
1.3.6.1.4.1.8072.1.3.2.3.1.2.7.115.121.115.116.101.109.100|4x|7b226572726f72537472696e67223a2022222c20226572726f72223a20302c202276657273696f6e223a20312c202264617461223a207b226c6f6164223a207b226c6f61646564223a203136302c2022746f74616c223a203136307d2c2022616374697665223a207b22616374697665223a203136302c2022746f74616c223a203136307d2c2022737562223a207b226175746f6d6f756e74223a207b2272756e6e696e67223a20312c2022746f74616c223a20317d2c2022646576696365223a207b22706c7567676564223a2032342c2022746f74616c223a2032347d2c20226d6f756e74223a207b226d6f756e746564223a2031392c2022746f74616c223a2031397d2c202270617468223a207b2277616974696e67223a20322c2022746f74616c223a20327d2c202273636f7065223a207b2272756e6e696e67223a20332c2022746f74616c223a20337d2c202273657276696365223a207b2272756e6e696e67223a2033352c2022746f74616c223a2035362c2022657869746564223a2032317d2c2022736c696365223a207b22616374697665223a2031312c2022746f74616c223a2031317d2c2022736f636b6574223a207b226c697374656e696e67223a20372c2022746f74616c223a2031332c202272756e6e696e67223a20367d2c202273776170223a207b22616374697665223a20312c2022746f74616c223a20317d2c2022746172676574223a207b22616374697665223a2032352c2022746f74616c223a2032357d2c202274696d6572223a207b2277616974696e67223a20352c2022746f74616c223a20357d7d7d7d0a