Icinga/Nagios plugin to check status of a Livestatus socket
Go to file
Benjamin Renard 6cb7f8cfe9
ci/woodpecker/push/woodpecker Pipeline was successful Details
Ensure to set peer variable before using it when catchin exception
2022-12-17 00:58:49 +01:00
.pylintrc Clone cleaning and configure CI to run tests 2022-12-17 00:55:31 +01:00
.woodpecker.yml Clone cleaning and configure CI to run tests 2022-12-17 00:55:31 +01:00
README.md Initial version 2022-03-01 19:50:44 +01:00
check_livestatus Ensure to set peer variable before using it when catchin exception 2022-12-17 00:58:49 +01:00

README.md

Icinga/Nagios plugin to check status of a Livestatus socket

This script could be used as Icinga/Nagios check plugin to check Livestatus socket status.

Installation

git clone https://gogs.zionetrix.net/bn8/check_livestatus.git /usr/local/src/check_livestatus
mkdir -p /usr/local/lib/nagios/plugins
ln -s /usr/local/src/check_livestatus/check_livestatus /usr/local/lib/nagios/plugins/

Usage

usage: check_livestatus [-h] [-d] [-v] [-l LOGFILE] [-C] [-U UNIX_SOCKET_PATH]
                        [-H HOST] [-p PORT] [-t TIMEOUT]

Icinga/Nagios plugin to check status of a Livestatus socket

optional arguments:
  -h, --help            show this help message and exit
  -d, --debug           Show debug messages
  -v, --verbose         Show verbose messages
  -l LOGFILE, --log-file LOGFILE
                        Log file path
  -C, --console         Also log on console (even if log file is provided)
  -U UNIX_SOCKET_PATH, --unix-socket-path UNIX_SOCKET_PATH
                        Livestatus UNIX socket path
  -H HOST, --host HOST  Livestatus host (default: 127.0.0.1)
  -p PORT, --port PORT  Livestatus port (default: 6557)
  -t TIMEOUT, --timeout TIMEOUT
                        Livestatus timeout in second (default: 2)

Copyright (c) 2022 Benjamin Renard

License

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2 as published by the Free Software Foundation.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.