I've created a plugin which basically tells agents to check my Hyperic server for other plugins via a simple shell script. The script itself works fine, as does the control plugin, with one catch: the last part of the script attempts to restart the hyperic agent, which fails. The agent stops, but never restarts. I'm guessing that once the agent process dies there's nothing left to send the 'start' command.
Any advice on a workaround? I thought of maybe using cron to schedule a 1 time 'start' job 1 minute after the 'stop' job completes but perhaps someone here thought of something more elegant.
Maybe I'm approaching this wrong? How are others managing custom plugins on their agents? I have over 300 servers and will need to deploy at least 1 or 2 custom plugins to all of them, I'd really hate to have to redeploy my plugin files by hand if I fix/improve them.
Well the "best" way to do this would be to use the EE version of HQ as it has features to make this process easy. However, I do understand that this isn't an option for everyone.
You would need to wrap the agent with something that will automatically restart it once it stops. The best way would depend on your OS. I'm sure there's some others on here that have done this. I personally used DJBs daemontools once to have the agent automatically restarted if it stopped.
Cool, I didn't realize EE had automated plugin deployment functionality. I am pushing for it, but unfortunately I'm not the one who writes the checks. At least this gives me another point to argue with.