Hi all,
Here's a sample of a /etc/monitrc config file of
mine.------------------------------------------------------set daemon 10 #
check services at 10 second intervals
set logfile syslog facility log_daemon
set httpd port 2812 and use address 10.1.1.150 # only accept connection from
localhost allow 0.0.0.0/0.0.0.0 # allow localhost to connect to the
server and allow admin:monit # require user 'admin' with password 'monit'
check process smbd with pidfile /var/run/smbd.pid start program =
"/usr/local/etc/init.d/samba start" stop program = "/usr/local/etc/init.d/samba
stop"
check process sshd with pidfile /var/run/sshd.pid start program =
"/usr/local/etc/init.d/openssh start" stop program =
"/usr/local/etc/init.d/openssh
stop"------------------------------------------------------
If I start monit with this file, i get the following errors./etc/monitrc:11:
Warning: Program is not executable:
'/usr/local/etc/init.d/samba'/etc/monitrc:12: Warning: Program is not
executable: '/usr/local/etc/init.d/samba'
So I had a look and the /usr/local/etc/init.d/samba file has ownership
root.rootAnd the /usr/local/etc/init.d/samba file has permissions of -rwxr-xr--
my /etc/monitrc file has ownership tc.staffand I run monit as my standard tc
user.
I get around this by running 'sudo monit' to start monit and no more problems.
I guess I could change permissions of the /usr/local/etc/init.d/samba, or
change its ownership to root.staff
I would really appreciate some advice on the best way to go forward with this.
Thanks,Stephen.
--
To unsubscribe:
https://lists.nongnu.org/mailman/listinfo/monit-general