I have a problem with nagios supervision. I would like to check that MariaDB is running on my web server, but Nagios returns "CRITICAL PROCESSES: 0 processes with command name 'mariadbd'".
Here is my Nagios configuration:
define service { use generic-service host_name p8_client service_description Checking MariaDB check_command chk_procs!1:!mariadbd } define command { command_name chk_procs command_line $USER1$/check_procs -c $ARG1$ -C $ARG2$ } And here is what my web server returns to me:
user@debian11:~$ ps aux | grep mariadbd mysql 606 0.0 4.8 1544548 98320 ? Ssl 17:32 0:00 /usr/sbin/mariadbd user 3193 0.0 0.0 6284 640 pts/0 S+ 17:38 0:00 grep mariadbd Thank you in advance for your help.
check_procs -c 1: -C mariadbdand check the result. Also-vin above command may give more informationp8_client? Because you run this check on your nagios host. You would neednrpeor something other way to query other servers if your mariadb is not on nagios host.