If you are running a heartbeat/pacemaker cluster with built-in monitoring, you will not want your monitoring agents to restart the services. Whether or not you decide to implement corrective action on events will depend upon your systems architecture. License is a one-time payment (non-reccuring cost) and does not expire. The MMonit package is proprietary software, with support licenses of Basic (eu: 129 - 10 clients), Professional (eu: 229 - unlimited clients), Premium (eu: 998 - unlimited clients - source access). The MMonit package extends the basic (free) monit program by adding a central monitoring service, with historical tracking of events. Monit provides a web interface that can be used to not just query monitor status but to also control the monitoring of configured services. You also noticed that the monitoring program will take corrective action either in the form of restarting the service, or generating an alert. This says that we generate an alert if the load average is greater than 4 for 5 polling cycles.Īs you can see, the configuration file is easy to interpret, human readable. If loadavg (1min) > 4 for 5 cycles then alert This says to timeout the service if it had to be restarted 2 times within 3 polling intervals. One of the features I liked was the ability to use "conditional logic" in determining the alert action. If failed checksum then exec "/watch/dog" # Run /watch/dog in the case that the binary was changed Then exec "/usr/local/apache/bin/apachectl graceful" # Reload apache if the nf file was changed If failed port 80 protocol http then restart If cpu usage > 95% for 3 cycles then restart If 2 restarts within 3 cycles then timeout Start program = "/etc/init.d/httpd start" with timeout 60 seconds With pidfile "/usr/local/apache/logs/httpd.pid" Set alert httpd port 2812 and use address localhostĪllow localhost # Allow localhost to connect Set daemon 120 # Poll at 2-minute intervals What got me interested in monit, besides the fact that it's FOSS, was the easy configuration. You may then install mmonit on a central monitoring management server, who will track all targets and report in the form of a nice "green-light/red-light" web interface. It's not an IPMI or SNMP aware monitoring package, but it's simplicity in setup, and built-in services monitoring is appealing for the situations I needed to track. Check the monit configuration, start the monit service and verify run levels.I've been using a very simple monitoring package called Monit.Upgrade monit with the following command.If there is a newer version, perform the upgrade procedure as follows: To check if there is a newer version of monit in the repository, log in to the console and get root privileges. Set eventqueue basedir /var/monit slots 50 Upgrade procedure Message: Monit $ACTION $SERVICE at $DATE on $HOST: $DESCRIPTION. Stop program = "/etc/init.d/syncp-storage stop" Start program = "/etc/init.d/syncp-storage start" The monit utility generates email alerts if the service is not running and when the service is started.'Ĭheck process syncp-storage with pidfile /var/run/syncp-storage/syncp-storage.pid If the service is started 5 times in last 7 cycles then monit no longer starts the service. The monit utility checks if the syncp-storage service is running if not, monit starts the service. For example:Īdd the following configuration to the /etc/monit.d/nf file. Issue the following command to create and/or open /etc/monit.d/nf with the vi editor.Īlternatively, you can specify the control file directly by using the -c command line switch to monit. You can create a new config file under the /etc/monit.d/ directory and it is included automatically in config. By default, it includes all files under the /etc/monit.d/ directory as config files. The default configuration file is located at /etc/nf. You can configure monit to monitor and recover the Storage Connector. Install monit using the following command in the console window: Get root privileges using the su command. Make sure you have the root password then use SSH to log in to the Storage Connector. NOTE: You may have the monit utility already installed on your Storage Connector. You can also use the monit utility to send email alerts if you have an SMTP server in your environment. This article describes the monit utility and how to use it to monitor and automatically restart the Storage Connector service. Monit logs to syslog or to its own log file and notifies you about error conditions via customizable alert messages. Monit is controlled via an easy to configure control file based on a free-format, token-oriented syntax. The monit utility is a simple lightweight monitoring Open Source tool for managing and monitoring processes, programs, files, directories and filesystems on a Unix system.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |