Monit Configuration Example

#1
Does anyone here have a configuration example for Openlitespeed to use in the Linux monitoring app Monit?

I will answer my own question for others.

check process OpenLitespeed with pidfile /tmp/lshttpd/lshttpd.pid
start program = "/usr/local/lsws/bin/lswsctrl start"
stop program = "/usr/local/lsws/bin/lswsctrl stop"
if cpu usage > 25% for 5 cycles then alert
if failed host MyDomainName.com port 80 protocol http then alert
 
Last edited:
#3
Does anyone here have a configuration example for Openlitespeed to use in the Linux monitoring app Monit?

I will answer my own question for others.
Hi TexasGreg,
Do you have any other OLS relevant Monit config you can share? I'd like to ensure I've got all bases covered re Monit and OLS but have found very little info on this.
 
#4
nice. thanks! I know this was a while ago, but any idea how to check mysql also?
Hi ftsor,
As far as I know, the following will keep an eye on MySQL (mariadb, in our case):

Code:
# check mariadb
check host mymariadb with address 127.0.0.1
 if failed ping then alert
 if failed port 3306 protocol mysql then alert
 

h87

New Member
#5
Does anyone here have a configuration example for Openlitespeed to use in the Linux monitoring app Monit?

I will answer my own question for others.

check process OpenLitespeed with pidfile /tmp/lshttpd/lshttpd.pid
start program = "/usr/local/lsws/bin/lswsctrl start"
stop program = "/usr/local/lsws/bin/lswsctrl stop"
if cpu usage > 25% for 5 cycles then alert
if failed host MyDomainName.com port 80 protocol http then alert
does this only monitor lsws admin web portal? how about lsws php ?

what does 'alert' do ? does it send an email ? ssh message ?
 
Top