xymon client startup on OS X

Richard L. Hamilton rlhamil at smart.net
Tue Feb 9 08:35:11 PST 2016


An embedded and charset-unspecified text was scrubbed...
Name: warning1.txt
URL: <https://lists.macosforge.org/pipermail/macports-users/attachments/20160209/64fa194b/attachment.txt>
-------------- next part --------------
Here's something I posted to the xymon list, suggesting they extend their runclient.sh script a bit to allow passing additional args that would make it behave well when invoked with a straightforward launchd plist that didn't need daemondo.  I tried to cc it over here, but I'm subscribed there using a different email than I use here, so it bounced here.

It seems straightforward enough to me, aside from needing to change the pathnames in the plist for some other installation location.

I'm probably going to use my own builds, since I have to do them for Solaris and Linux anyway.  But if they accept this (so you don't have to patch runclient.sh), you might look at the plist that doesn't need daemondo - which I think I tried ages ago and never had much luck with.  Absent the xymonlaunch --no-daemon option, either some trickery like daemondo or a StartupItem would be needed; but StartupItems, simple though they were, no longer work as of Yosemite I think - definitely not as of El Capitan, since some of the pieces are missing to run them.

Regardless, you might want to update xymon soon, since they just released an update for it to address CVE-2016-2054, 2056, 2057, and 2058; and for initial installations, mitigation for CVE-2016-2055 (which might require a bit of manual intervention to tighten permissions in existing installations).  See http://lists.xymon.com/archive/2016-February/042986.html for the full info.

================================= begin quoted message ==================================

Ok, what I wanted to do seems to work fine.  Attached are the modified runclient.sh and my launchd plist file.  The latter would need the account name, group name, and pathnames modified as necessary (I installed in /Users/xymon/client, which may not be typical).

The modified runclient.sh will also exec xymonlaunch rather than run it and wait for it, if --no-daemon is passed; might as well save one shell process. :-)  It also allows passing --debug and --verbose options through to xymonlaunch.  None of which should affect its conventional use.


> On Feb 9, 2016, at 09:35, Richard L. Hamilton <rlhamil2 at gmail.com <mailto:rlhamil2 at gmail.com>> wrote:
> 
> Older tricks for this included StartupItems, which apparently no longer work as of Yosemite, let alone El Capitan.
> 
> MacPorts has a really strange solution, but I'm not impressed at all with it.
> 
> I see that xymonlaunch has a --no-daemon option, which would allow the sort of behavior that launchd expects.  An old post mentions an approach using that:
> http://lists.xymon.com/oldarchive/2009/05/msg00244.html <http://lists.xymon.com/oldarchive/2009/05/msg00244.html>
> 
> Seems to me that if runclient.sh handled an extra command line option to pass --no-daemon through to the xymonlaunch command line, it would simplify matters somewhat, not requiring people to check that their modified script was updated as needed; all that would be needed extra would be a com.xymon.client.plist file to put in /Library/LaunchDaemons; and that shouldn't vary from one update to the next.
> 
> What I'm suggesting should probably work at least as far back as Snow Leopard (OS X 10.6) if not further.  I haven't tried it yet, but I'm on my way to doing so.
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-users/attachments/20160209/64fa194b/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: com.xymon.client.plist
Type: application/octet-stream
Size: 1242 bytes
Desc: not available
URL: <https://lists.macosforge.org/pipermail/macports-users/attachments/20160209/64fa194b/attachment.obj>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-users/attachments/20160209/64fa194b/attachment-0001.html>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-users/attachments/20160209/64fa194b/attachment-0002.html>


More information about the macports-users mailing list