-
Notifications
You must be signed in to change notification settings - Fork 0
gm06120219/service_monitor
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
README These python scripts are used to monitor the Ubuntu Server Service. How it works: 1.get the result of ubuntu command: ps aux 2.filtering the keyword of the service like: "apache" 3.if it's still have data after filtering, the service was alive, else send e-mail with the log file to your e-mail address. How to use it: $sudo vi /etc/init/smonitor.conf start on started networking exec sh -c "python /your_unzip_directory/monitor.py > /var/log/smonitor/log.log 2>&1" $mkdir /var/log/smonitor $sudo service smonitor start Config file ----------------------------------- [monitor] # service item of monitor add service information format like "service_name = service_log_file_path" PS: Please don't send too large log file. For example: "nginx = /var/log/nginx/access.log" [disk] # file system add file system item for monitor its capacity [loop] # sleep time for check loop
About
Monitoring Ubuntu server service program
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published