diff --git a/checkpoint_fw_connections.mkp b/checkpoint_fw_connections.mkp index 55f0fb181169aecd8bc35109f729c00c7e1e24fc..80e5fdddd3db714940edf33bb858ad717f5dbdcf 100644 Binary files a/checkpoint_fw_connections.mkp and b/checkpoint_fw_connections.mkp differ diff --git a/checks/checkpoint_fw_connections b/checks/checkpoint_fw_connections index 459d333c1378721e11b9a161163b7d4fb07a2480..a37baca1414ad36bcabc9c447d389186b4fea26f 100644 --- a/checks/checkpoint_fw_connections +++ b/checks/checkpoint_fw_connections @@ -52,14 +52,6 @@ def check_checkpoint_fw_connections(item, params, info): if fwConnTableLimit == 0: fwConnTableLimit = 'automatically adjusted' - perfdata = [('fwconnectionstcp', fwConnectionsTcp), - ('fwconnectionsudp', fwConnectionsUdp), - ('fwconnectionsicmp', fwConnectionsIcmp), - ('fwconnectionsother', fwConnectionsOther), - ('fwconnectionssum', fwConnectionsSum), - ('fwpeaknumconn', fwPeakNumConn) - ] - for info, unit, counter, value, warncrit in [ ('current: ', '', 'fwcurrentnumconn', fwCurrnetNumConn, 'warncritcurrent'), ('rate: ', '/s', 'fwconnectionrate', fwConnectionRate, 'warncritrate') @@ -69,15 +61,25 @@ def check_checkpoint_fw_connections(item, params, info): else: warn = None crit = None - perfdata.append((counter, value, warn, crit)) + infotext = info + '%d' % value + unit + perfdata = [(counter, value, warn, crit)] if crit != None and value >= crit: - yield 2, info + '%d' % value + unit + ' (>=%d)' % crit + yield 2, infotext + ' (>=%d)' % crit, perfdata elif warn != None and value >= warn: - yield 1, info + '%d' % value + unit + ' (>=%d)' % warn + yield 1, infotext + ' (>=%d)' % warn, perfdata else: - yield 0, info + '%d' % value + unit + yield 0, infotext, perfdata infotext = 'peak: %d, table limit: %s' % (fwPeakNumConn, fwConnTableLimit) + + perfdata = [('fwconnectionstcp', fwConnectionsTcp), + ('fwconnectionsudp', fwConnectionsUdp), + ('fwconnectionsicmp', fwConnectionsIcmp), + ('fwconnectionsother', fwConnectionsOther), + ('fwconnectionssum', fwConnectionsSum), + ('fwpeaknumconn', fwPeakNumConn) + ] + yield 0, infotext , perfdata diff --git a/web/plugins/metrics/checkpoint_fw_connections.py b/web/plugins/metrics/checkpoint_fw_connections.py index d14cfb0cd88d55c146a0b0784822c01a6b1c0097..a6dcbc4ed4f66d06e0887c51f86012bf2522f13d 100644 --- a/web/plugins/metrics/checkpoint_fw_connections.py +++ b/web/plugins/metrics/checkpoint_fw_connections.py @@ -31,17 +31,17 @@ metric_info['checkpoint_fw_connections_fwconnectionstcp'] = { metric_info['checkpoint_fw_connections_fwconnectionsudp'] = { 'title': _('UDP connections'), 'unit': '1/s', - 'color': '14/a', + 'color': '12/a', } metric_info['checkpoint_fw_connections_fwconnectionsicmp'] = { 'title': _('ICMP connections'), 'unit': '1/s', - 'color': '31/a', + 'color': '13/a', } metric_info['checkpoint_fw_connections_fwconnectionsother'] = { 'title': _('Other connections'), 'unit': '1/s', - 'color': '34/a', + 'color': '14/a', } metric_info['checkpoint_fw_connections_fwconnectionssum'] = { 'title': _('Total connections'), @@ -62,7 +62,7 @@ metric_info['checkpoint_fw_connections_fwcurrentnumconn'] = { metric_info['checkpoint_fw_connections_fwpeaknumconn'] = { 'title': _('Peak Connections'), 'unit': 'count', - 'color': '13/a', + 'color': '15/a', }