Hello to All,
does anyone nows a Ansible Playbook to remove a Check (Service) from a Nagios (Thruk) Portal.
Thanks for your Help
Ansible Playbook Remove Check
Re: Ansible Playbook Remove Check
I'm probably missing something here but checks typically exist on the Nagios host in a file, which is pretty easy to remove. Then the nagios service would need a restart. Maybe you have checks defined in monitored hosts that send status info to the nagios host?
Re: Ansible Playbook Remove Check
Consider using the NagiosExternalCommands and this will get you close.
https://assets.nagios.com/downloads/nag ... mands.html
https://assets.nagios.com/downloads/nag ... ernalcmds/
Write your playbook to use the external commands as the primary actor or create a POST request that can be handled via NRDP
DISABLE_HOST_SVC_CHECKS(STOPS THEM ALL)
https://assets.nagios.com/downloads/nag ... mand_id=34
DISABLE_SVC_CHECK(SINGLE)
https://assets.nagios.com/downloads/nag ... mmand_id=6
You can also utilize the Deadpool functions within XI to handle the toil of host/service removal.
https://assets.nagios.com/downloads/nag ... ios-XI.pdf
--SN
https://assets.nagios.com/downloads/nag ... mands.html
https://assets.nagios.com/downloads/nag ... ernalcmds/
Write your playbook to use the external commands as the primary actor or create a POST request that can be handled via NRDP
DISABLE_HOST_SVC_CHECKS(STOPS THEM ALL)
https://assets.nagios.com/downloads/nag ... mand_id=34
DISABLE_SVC_CHECK(SINGLE)
https://assets.nagios.com/downloads/nag ... mmand_id=6
You can also utilize the Deadpool functions within XI to handle the toil of host/service removal.
https://assets.nagios.com/downloads/nag ... ios-XI.pdf
--SN