|
From: | Tom O'Brien |
Subject: | RE: Running monit from a "shell less" userid -- odd behaviour |
Date: | Fri, 18 Feb 2005 10:47:14 -0500 |
-----Original Message-----
From: address@hidden [mailto:address@hidden On Behalf Of Tom O'Brien
Sent: Thursday, February 17, 2005 6:30 PM
To: 'This is the general mailing list for monit'
Subject: Running monit from a "shell less" userid -- odd behaviourHi all:
I'm running monit in daemon mode on RH Linux as a special user id that does not have a login shell (it's only there to run daemons). I create the user as follows (I'll call it "myuser"):useradd -d /home/myuser -g nobody -m -n -r -s /sbin/nologin myuser
The odd behaviour happens when I want to send commands to monit running on the system. Some commands work:
<run as myuser> monit -c <config file> reload
<run as myuser> monit -c <config file> statusHowever many commands fail:
<run as myuser> monit -c <config file> restart <service>
<run as myuser> monit -c <config file> stop all<Run as myuser> = su -s /bin/bash - myuser -c "/usr/sbin/monit..."
OR
setuidgid myuser /usr/sbin/monit... (djb's daemontools utility)Both <Run as myuser> options produce the same result. Running monit with the -v option shows NO output in response to the restart or stop commands, but regular output in response to reload/status commands.
Anyone have any idea why this would be the case? Any way I can make this work?
Thanks for any assistance.
Tom.
[Prev in Thread] | Current Thread | [Next in Thread] |