[Xymon] XYMONNETWORK environment variable
Henrik Størner
henrik at hswn.dk
Thu Jan 5 21:52:11 CET 2012
On 05-01-2012 21:46, Root, Paul wrote:
> So a follow up.
>
> I’m guessing I need a new section for an additional xymonnet?
Yes.
> [xymonnet]
> ENVFILE /usr/lib64/xymon/server/etc/xymonserver.cfg
> NEEDS xymond
> CMD xymonnet --report --ping --checkresponse
> LOGFILE $XYMONSERVERLOGS/xymon-network.log
> INTERVAL 5m
>
> [xymonnet2]
> ENVFILE /usr/lib64/xymon/server/etc/xymonserver.cfg
> NEEDS xymond
> CMD XYMONNETWORK=IAD xymonnet --report --ping --checkresponse
> LOGFILE $XYMONSERVERLOGS/xymon-network.log
> INTERVAL 5m
>
> Is that right? And it’s ok to use the same log file?
Not quite right, because the CMD setting doesn't permit you to set
environment variables that way (the command isn't passed to a shell, but
executed directly). So the easiest thing to do is to have a shell-script
"wrapper" around the xymonnet command, that sets the XYMONNET
environment variable.
> Should I have another xymonnetagain then too?
Good question - off the top of my head, I'd say "yes, you should".
Regards,
Henrik
More information about the Xymon
mailing list