diff --git a/README.md b/README.md index d78d771..da49456 100644 --- a/README.md +++ b/README.md @@ -35,12 +35,16 @@ There is also an InfluxDB dashboard for some metrics included. ## HELP ``` -usage: check_redfish.py [-H HOST] [-u USERNAME] [-p PASSWORD] [-f AUTHFILE] [--sessionfile SESSIONFILE] - [--sessionfiledir SESSIONFILEDIR] [--nosession] [-h] [-w WARNING] [-c CRITICAL] [-v] [-d] - [-m MAX] [-r RETRIES] [-t TIMEOUT] [--log_exclude LOG_EXCLUDE] [--ignore_missing_ps] - [--enable_bmc_security_warning] [--storage] [--proc] [--memory] [--power] [--temp] [--fan] - [--nic] [--bmc] [--info] [--firmware] [--sel] [--mel] [--all] [-i] - [--inventory_id INVENTORY_ID] [--inventory_name INVENTORY_NAME] +usage: check_redfish.py [-H HOST] [-u USERNAME] [-p PASSWORD] [-f AUTHFILE] + [--sessionfile SESSIONFILE] + [--sessionfiledir SESSIONFILEDIR] [--nosession] [-h] + [-w WARNING] [-c CRITICAL] [-v] [-d] [-m MAX] + [-r RETRIES] [-t TIMEOUT] [--log_exclude LOG_EXCLUDE] + [--ignore_missing_ps] [--enable_bmc_security_warning] + [--storage] [--proc] [--memory] [--power] [--temp] + [--fan] [--nic] [--bmc] [--info] [--firmware] [--sel] + [--mel] [--all] [-i] [--inventory_id INVENTORY_ID] + [--inventory_name INVENTORY_NAME] [--inventory_file INVENTORY_FILE] This is a monitoring/inventory plugin to check components and @@ -49,10 +53,11 @@ It will also create a inventory of all components of a system. R.I.P. IPMI -Version: 1.4.1 (2022-05-16) +Version: 1.5.0 (2023-02-24) mandatory arguments: - -H HOST, --host HOST define the host to request. To change the port just add ':portnumber' to this parameter + -H HOST, --host HOST define the host to request. To change the port just + add ':portnumber' to this parameter authentication arguments: -u USERNAME, --username USERNAME @@ -65,7 +70,8 @@ authentication arguments: define name of session file --sessionfiledir SESSIONFILEDIR define directory where the plugin saves session files - --nosession Don't establish a persistent session and log out after check is finished + --nosession Don't establish a persistent session and log out after + check is finished optional arguments: -h, --help show this help message and exit @@ -73,19 +79,24 @@ optional arguments: set warning value -c CRITICAL, --critical CRITICAL set critical value - -v, --verbose this will add all https requests and responses to output, also adds inventory source data to - all inventory objects + -v, --verbose this will add all https requests and responses to + output, also adds inventory source data to all + inventory objects -d, --detailed always print detailed result -m MAX, --max MAX set maximum of returned items for --sel or --mel -r RETRIES, --retries RETRIES set number of maximum retries (default: 3) -t TIMEOUT, --timeout TIMEOUT - set number of request timeout per try/retry (default: 7) + set number of request timeout per try/retry (default: + 7) --log_exclude LOG_EXCLUDE - a comma separated list of log lines (regex) to exclude from log status checks (--sel, --mel) - --ignore_missing_ps ignore the fact that no power supplies are present and report the status of the power subsystem + a comma separated list of log lines (regex) to exclude + from log status checks (--sel, --mel) + --ignore_missing_ps ignore the fact that no power supplies are present and + report the status of the power subsystem --enable_bmc_security_warning - return status WARNING if BMC security issues are detected (HPE iLO only) + return status WARNING if BMC security issues are + detected (HPE iLO only) query status/health information (at least one is required): --storage request storage health @@ -103,13 +114,17 @@ query status/health information (at least one is required): --all request all of the above information at once query inventory information (no health check): - -i, --inventory return inventory in json format instead of regular plugin output + -i, --inventory return inventory in json format instead of regular + plugin output --inventory_id INVENTORY_ID - set an ID which can be used to identify this host in the destination inventory + set an ID which can be used to identify this host in + the destination inventory --inventory_name INVENTORY_NAME - set a name which can be used to identify this host in the destination inventory + set a name which can be used to identify this host in + the destination inventory --inventory_file INVENTORY_FILE - set file to write the inventory output to. Otherwise stdout will be used. + set file to write the inventory output to. Otherwise + stdout will be used. ``` diff --git a/check_redfish.py b/check_redfish.py index 1b54719..728afe9 100755 --- a/check_redfish.py +++ b/check_redfish.py @@ -1,6 +1,6 @@ #!/usr/bin/env python3 # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # @@ -16,8 +16,8 @@ R.I.P. IPMI """ -__version__ = "1.4.1" -__version_date__ = "2022-05-16" +__version__ = "1.5.0" +__version_date__ = "2023-02-24" __author__ = "Ricardo Bartels " __description__ = "Check Redfish Plugin" __license__ = "MIT" diff --git a/cr_module/bmc.py b/cr_module/bmc.py index f0c93d8..927a2bd 100644 --- a/cr_module/bmc.py +++ b/cr_module/bmc.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # diff --git a/cr_module/classes/__init__.py b/cr_module/classes/__init__.py index 4cfd35c..fa5d379 100644 --- a/cr_module/classes/__init__.py +++ b/cr_module/classes/__init__.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # diff --git a/cr_module/classes/inventory.py b/cr_module/classes/inventory.py index c7f3c46..3b39afa 100644 --- a/cr_module/classes/inventory.py +++ b/cr_module/classes/inventory.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # diff --git a/cr_module/classes/plugin.py b/cr_module/classes/plugin.py index d87ee0b..f08ac57 100644 --- a/cr_module/classes/plugin.py +++ b/cr_module/classes/plugin.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # diff --git a/cr_module/classes/redfish.py b/cr_module/classes/redfish.py index a35a5bc..509379d 100644 --- a/cr_module/classes/redfish.py +++ b/cr_module/classes/redfish.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # diff --git a/cr_module/classes/vendor.py b/cr_module/classes/vendor.py index 02b68d3..5b7fe8b 100644 --- a/cr_module/classes/vendor.py +++ b/cr_module/classes/vendor.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # diff --git a/cr_module/common.py b/cr_module/common.py index 53de8dc..44892eb 100644 --- a/cr_module/common.py +++ b/cr_module/common.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # diff --git a/cr_module/event.py b/cr_module/event.py index 15efa9d..7cdf6c5 100644 --- a/cr_module/event.py +++ b/cr_module/event.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # diff --git a/cr_module/fan.py b/cr_module/fan.py index c27bcc4..b4fe942 100644 --- a/cr_module/fan.py +++ b/cr_module/fan.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # diff --git a/cr_module/firmware.py b/cr_module/firmware.py index 5b6013a..0b57ea7 100644 --- a/cr_module/firmware.py +++ b/cr_module/firmware.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # diff --git a/cr_module/firmware_issues.py b/cr_module/firmware_issues.py index 65b10e7..ae6dcd2 100644 --- a/cr_module/firmware_issues.py +++ b/cr_module/firmware_issues.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # diff --git a/cr_module/mem.py b/cr_module/mem.py index 944fc20..3536bf4 100644 --- a/cr_module/mem.py +++ b/cr_module/mem.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # diff --git a/cr_module/nic.py b/cr_module/nic.py index c818805..aff918e 100644 --- a/cr_module/nic.py +++ b/cr_module/nic.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # diff --git a/cr_module/power.py b/cr_module/power.py index df345f7..f062d6d 100644 --- a/cr_module/power.py +++ b/cr_module/power.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # diff --git a/cr_module/proc.py b/cr_module/proc.py index 7e5d292..fe91909 100644 --- a/cr_module/proc.py +++ b/cr_module/proc.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # diff --git a/cr_module/storage.py b/cr_module/storage.py index 1ceaa69..110c106 100644 --- a/cr_module/storage.py +++ b/cr_module/storage.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # diff --git a/cr_module/system_chassi.py b/cr_module/system_chassi.py index beee276..c98d5de 100644 --- a/cr_module/system_chassi.py +++ b/cr_module/system_chassi.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py # diff --git a/cr_module/temp.py b/cr_module/temp.py index afb1456..082ac29 100644 --- a/cr_module/temp.py +++ b/cr_module/temp.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright (c) 2020 - 2022 Ricardo Bartels. All rights reserved. +# Copyright (c) 2020 - 2023 Ricardo Bartels. All rights reserved. # # check_redfish.py #