Hi,
I'm trying to set up actions to restart some systemd services when they are down, and the command seems to be executed (confirmed in Action Log and agent log) on the server but services aren't restarting.
On the agent side, I enabled command logging and debugging at level 5. Here's what the log says:
The script command I'm using to restart MariaDB (in this case) is:
Is the script command correct to restart services? Or is there something else?
I'm using:
I'm trying to set up actions to restart some systemd services when they are down, and the command seems to be executed (confirmed in Action Log and agent log) on the server but services aren't restarting.
On the agent side, I enabled command logging and debugging at level 5. Here's what the log says:
Code:
2/04/05 05:12:54.969098 received passive check request: 'system.run[/etc/init.d/mariadb restart,nowait]' from 'xx.xx.xx.xx' 2022/04/05 05:12:54.969160 [1] processing update request (1 requests) 2022/04/05 05:12:54.969179 [1] adding new request for key: 'system.run[/etc/init.d/mariadb restart,nowait]' 2022/04/05 05:12:54.969192 [1] created direct exporter task for plugin 'SystemRun' itemid:0 key 'system.run[/etc/init.d/mariadb restart,nowait]' 2022/04/05 05:12:54.969243 executing direct exporter task for key 'system.run[/etc/init.d/mariadb restart,nowait]' 2022/04/05 05:12:54.969249 [SystemRun] Executing command:'/etc/init.d/mariadb restart' 2022/04/05 05:12:54.969483 executed direct exporter task for key 'system.run[/etc/init.d/mariadb restart,nowait]' 2022/04/05 05:12:54.969544 sending passive check response: '1' to 'xx.xx.xx.xx'
Code:
/etc/init.d/mariadb restart
I'm using:
- Zabbix 6.0.2
- Zabbix_agent2
- Debian 11
- MariaDB 10.5.13
Comment