Skip to content

check_cdot_metrocluster_state: "use of uninitialized value [...]" #80

@tectumopticum

Description

@tectumopticum

If you run the plugin against a system which is not a metrocluster you'll get this output:

Use of uninitialized value $local_mode in concatenation (.) or string at /usr/lib/nagios/plugins/contrib/check_cdot_metrocluster_state.pl line 78.
Use of uninitialized value $local_check in concatenation (.) or string at /usr/lib/nagios/plugins/contrib/check_cdot_metrocluster_state.pl line 78.
Use of uninitialized value $remote_config in concatenation (.) or string at /usr/lib/nagios/plugins/contrib/check_cdot_metrocluster_state.pl line 78.
Use of uninitialized value $remote_mode in concatenation (.) or string at /usr/lib/nagios/plugins/contrib/check_cdot_metrocluster_state.pl line 78.
Use of uninitialized value $remote_check in concatenation (.) or string at /usr/lib/nagios/plugins/contrib/check_cdot_metrocluster_state.pl line 78.
CRITICAL: Local-Config: not_configured, Local-Mode: , Local-Periodic-Check: , Remote-Config: , Remote-Mode: , Remote-Periodic-Check:

Of course, you wouldn't normally do that ;)
But the other metrocluster-plugins (e.g. check_cdot_metrocluster_check.pl) do a better error-handling in this case.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions