OCF_HEARTBEAT_NAGIOS(7)

πŸ’– ocf_heartbeat_nagios β€” the Nagios resource agent, explained bestie-style πŸ’–

okay so this is OCF_HEARTBEAT_NAGIOS(7), aka the manual page for ocf_heartbeat_nagios β€” the Nagios resource agent. yes it's from the OCF resource agents collection, and yes we're gonna go through every single line together. grab a snack. πŸ“


🌸 NAME 🌸

ocf_heartbeat_nagios β€” Nagios resource agent. that's it, that's the name, she's iconic and she knows it. πŸ‘‘


✨ SYNOPSIS ✨

nagios [start | stop | status | monitor | meta-data | validate-all]

so you call her like that, pick one of those actions, and she does the thing. periodt.


πŸ¦‹ DESCRIPTION πŸ¦‹

it's an OCF resource script for Nagios 3.x or 4.x. it manages a Nagios instance as a HA resource. like, it babysits your Nagios so the cluster knows what's up. no cap, that's the whole job. πŸ’…


πŸŽ€ SUPPORTED PARAMETERS πŸŽ€

these are the knobs you get to turn. all of them are optional, all of them are strings, and every single one has a default so you don't have to touch anything (but you can, bestie, you can).

  • user β€” the user running the Nagios daemon, used for file permissions. (optional, string, default "nagios")
  • group β€” the group running the Nagios daemon, also for file permissions. (optional, string, default "nagios")
  • binary β€” where the Nagios binary lives. (optional, string, default "/usr/sbin/nagios")
  • config β€” the configuration file. (optional, string, default "/etc/nagios/nagios.cfg")
  • log β€” where the Nagios log goes. (optional, string, default "/var/log/nagios/nagios.log")
  • retention β€” the location of the Nagios retention file. (optional, string, default "/var/log/nagios/retention.dat")
  • command β€” the location of the Nagios external command file. (optional, string, default "/var/log/nagios/rw/nagios.cmd")
  • pid β€” where the Nagios pid/lock lives. (optional, string, default "/var/run/nagios.pid")

that's eight parameters, all accounted for, none skipped. slay. ✨


πŸ’œ SUPPORTED ACTIONS πŸ’œ

this resource agent supports the following actions (operations). she's got range, fr fr:

  • start β€” starts the resource. suggested minimum timeout: 20s.
  • stop β€” stops the resource. suggested minimum timeout: 20s.
  • status β€” performs a status check. suggested minimum timeout: 20s.
  • monitor β€” performs a detailed status check. suggested minimum timeout: 20s. suggested interval: 10s.
  • validate-all β€” performs a validation of the resource configuration. suggested minimum timeout: 20s.
  • meta-data β€” retrieves resource agent metadata (internal use only, don't touch it unless you know what you're doing bestie πŸ™ˆ). suggested minimum timeout: 20s.

🌈 EXAMPLE CRM SHELL 🌈

here's what a nagios resource looks like using the crm(8) shell. copy it, love it, run it:

primitive p_nagios ocf:heartbeat:nagios \
  op monitor depth="0" timeout="20s" interval="10s" start-delay="10s"

🧚 EXAMPLE PCS 🧚

and here's the same energy but for pcs(8):

pcs resource create p_nagios ocf:heartbeat:nagios \
  op monitor OCF_CHECK_LEVEL="0" timeout="20s" interval="10s" start-delay="10s"

both ate, honestly. pick your fave. πŸ’…


⭐ SEE ALSO ⭐

go peek at this when you want more:


🫢 AUTHOR 🫢

ClusterLabs contributors β€” and if you want to know about individual authors, the resource agent source has the receipts. (see the resource agent source for information about individual authors) πŸ’–


ok that's the whole page, every parameter, every action, every timeout, every example, untouched. nothing skipped. that's the vibe check passed. βœ…

signing off, bestie β€” this was resource-agents, version UNKNOWN, dated 04/08/2026. iykyk. go manage your Nagios. bye!! πŸ’–βœ¨πŸŽ€πŸ¦‹πŸŒΈπŸ’…

πŸ“¦ where this page comes from