Installing M/Monit
Download the latest version from here http://mmonit.com/download/
$ sudo wget https://mmonit.com/dist/mmonit-3.7.1-linux-x86.tar.gz
Extract tar file and start mmonit
$ sudo tar zxvf mmonit-3.7.1-linux-x86.tar.gz
$ sudo mv mmonit* /usr/local/mmonit/
$ cd /usr/local/mmonit/
$ sudo ./bin/mmonit
Open URL http://ServerIP:9050/
$ sudo wget https://mmonit.com/dist/mmonit-3.7.1-linux-x86.tar.gz
Extract tar file and start mmonit
$ sudo tar zxvf mmonit-3.7.1-linux-x86.tar.gz
$ sudo mv mmonit* /usr/local/mmonit/
$ cd /usr/local/mmonit/
$ sudo ./bin/mmonit
Open URL http://ServerIP:9050/
Default Login: admin
Default Password: swordfish
Set M/Monit Connector Port :
$ sudo vi /usr/local/mmonit/conf/server.xml
<Connector address="*" port="8080" processors="10" />
Set connector port 9050 :
<Connector address="*" port="9050" processors="10" />
Set M/Monit Configuration :
$ sudo vi /etc/monit/monitrc
Add one line only :
set mmonit http://monit:monit@<ServerIP>:9050/collector
set eventqueue basedir /var/monit slots 1000
# Specify the URL for posting events to M/Monit. The auth. part of
# the URL, that is, monit:monit, specify a username and password
# registered in M/Monit. If you change the password for the monit
# user in M/Monit it must be changed here as well.
set mmonit http://monit:monit@127.0.0.1:9050/collector
set httpd port 2812 and use address 127.0.0.1
allow localhost
allow 127.0.0.1
allow username:password
MySQL M/Monit Configuration :
Create mmonit database:
Create the mmonit user and grant access to the mmonit database:
mysqladmin create mmonit -u root -p
Create the mmonit user and grant access to the mmonit database:
mysql> GRANT ALL ON mmonit.* to mmonit@localhost identified by 'MmonitPassword';
Automatic startup M/Monit :
Register M/Monit as Monit service in the Monit configuration file (/etc/monit/monitrc):
Replace MmonitUID and MmonitGID by the respective ID.
Reload monit
Open URL http://ServerIP:9050/
Default Login: admin
Default Password: swordfish
check process mmonit with pidfile /usr/local/mmonit/logs/mmonit.pid
start program = "/usr/local/mmonit/bin/mmonit -d" as uid MmonitUID and gid MmonitGID
stop program = "/usr/local/mmonit/bin/mmonit stop" as uid MmonitUID and gid MmonitGID
Replace MmonitUID and MmonitGID by the respective ID.
Reload monit
monit reload
Open URL http://ServerIP:9050/
Default Login: admin
Default Password: swordfish
Note :
monit is a free, open source process supervision tool for Unix and Linux. With monit, system status can be viewed directly from the command line, or via the native HTTP(S) web server.M/Monit, a purchased software distributed by the creators of monit (Tildeslash LTD) expands upon the capabilities of monit, providing multi-host monitoring and analysis from within one web interface.
Comments
Post a Comment