[文章作者:张宴 本文版本:v1.1 最后修改:2007.08.31 转载请注明出处:http://blog.zyan.cc]

  8月3日,我写了“Linux服务器监控系统 ServMon V1.0”,今天,ServMon V1.1 版本亮相。

  ServMon的原理是用shell脚本定时抓取被监控Linux服务器上的信息,再用curl POST到监控机的PHP接口程序上,由PHP接口程序对信息进行分析,如果存在异常,则发送报警邮件给管理员。报警邮件演示页面请见:http://blog.zyan.cc/read.php/276.htm

  点击在新窗口中浏览此图片

  ServMon V1.1 在 1.0 的基础上,增加了对Linux系统负载的监控,并编写了客户端自动安装包:

  1、被监控端服务器(Linux)
  (1)、下载并安装ServMon Client
引用
wget http://blog.zyan.cc/soft/linux/servmon/servmon-1.1.linux.tar.gz
tar zxvf servmon-1.1.linux.tar.gz
cd servmon-1.1
./install -i http://yourdomain/servmon/interface.php password

  注:此处的password为interface.php程序中设置的数据传输验证密码。

  客户端安装包源码:
  │
  ├─install
  ├─[src]
  │  ├─[bin]
  │  │  ├─diskstat_send
  │  │  ├─loadstat_send
  │  │  └─swapstat_send
  │  ├─[cron]
  │  │  └─servmon
  │  └─[data]

  屏幕演示:
  点击在新窗口中浏览此图片




  2、监控端服务器配置(Linux)
  (1)、启动sendmail
  /usr/sbin/sendmail -bd -q30m
  -b:指定Sendmail在后台运行,并且监听端口25的请求。
  -d:指定Sendmail以Daemon方式运行(守护进程)。
  -q:当Sendmail无法将邮件成功地发送到目的地时,它会将邮件保存在队列里。该参数指定邮件在队列里保存的时间。其中的30m表示保留30分钟。

  (2)、修改php.ini的[mail function]部分为以下内容,然后重启Apache,使PHP能够使用mail()函数发送电子邮件
引用
[mail function]
; For Win32 only.
;SMTP = localhost
;smtp_port = 25

; For Win32 only.
;sendmail_from = me@example.com

; For Unix only.  You may supply arguments as well (default: "sendmail -t -i").
sendmail_path = /usr/sbin/sendmail -t -i


  (4)、在MySQL上创建一个数据库servmon,然后在该数据库中执行以下SQL语句创建表:
引用
CREATE TABLE `tb_diskstat` (
 `ip` varchar(128) NOT NULL default '',
 `date` int(10) NOT NULL default '0',
 UNIQUE KEY `ip` (`ip`)
) TYPE=MyISAM;

  备注:这张表是PHP接口程序用来记录发送磁盘分区报警邮件的时间,避免在一段时间内重复发送大量报警邮件的。

  (3)、PHP接口程序
  http://yourdomain/servmon/interface.php


Tags:



技术大类 » 其他Unix技术 | 评论(1105) | 引用(0) | 阅读(153042)
girl chd Email
2023-12-8 14:16
The girls are really flexible in their attitude being the heartthrobs of their clients ready to entice with all their energy and enthusiasm. It would be an all-time profit for men belonging to any age group or social background level to keep these ravishing individuals by your side. No complaints would be found which might distract the minds of the customers thus urging them to look out for an alternative option. https://girlchd.in
shalinikapoor Email
2023-12-8 17:57
Whether you are seeking a companion for intimate pleasure, a dinner date, a party, a long drive, or even corporate meetings, our Chandigarh Escorts can fulfill your desires. These women possess not only seductive skills but also beauty, intelligence, knowledge, and an enchanting personality.https://www.shalinikapoor.comChandigarh Escortshttps://www.shalinikapoor.com
Sonam Shah Email
2023-12-8 19:13
Men from all walks of life dream of being with Zirakpur Escort Service. These women are experts in the art of lovemaking and possess a captivating charm that can satisfy any man's desires. Even if you are shy or inexperienced, these individuals are well-equipped to make you feel comfortable and uplift your mood. Their exceptional methods of pampering and affection will make you feel like a king, rejuvenating your mundane state of mind. With their sensual prowess and willingness to explore various positions, these beloved darlings will leave you physically and mentally exhilarated. You can trust that your cherished companion will fulfill all of your fantasies and yearnings.http://www.cutepai.com
xcotpage Email Homepage
2023-12-11 13:41
Looking for escorts service in Delhi and call girl in Delhi? Xcotpage is a free adult classifieds for escorts and call girl services in Delhi.Delhi Escorts Service
Girl Dehradun Email Homepage
2023-12-11 13:46
Amidst the monotony of daily life and the burdens it brings, it is natural to yearn for excitement and rejuvenation. Our Dehradun Escort Service presents an opportunity to infuse thrill into your existence.https://girlsdehradun.in
Cute Daisy Email
2023-12-11 15:38
Spend lonely nights when you can have the company of our stunning Jammu Escort? Say goodbye to loneliness and stress by getting along with one of these remarkable women. Their exceptional allure and seductiveness will mesmerize you and ignite your erotic desire effortlessly..http://www.sargunmehta.in/jammu-escorts.php
Mumbai Call Girls Email
2023-12-14 11:07
We offer high class service with beautiful and intelligent girls. If you have been planning for a vacation in Mumbai, we assure that you will enjoy your time there. We are providing the best of the best female escorts in Mumbai  to make your holiday an unforgettable one.Mumbai Call Girls | Mumbai Escorts | Mumbai Call Girls Price | Mumbai Call Girls contact | Andheri East Call Girls | Bandra Call Girls Service | Booking a Call Girls in Mumbai | Russian Call Girls in Mumbai | Navi Mumbai Call Girls | Vashi Call Girls Whatsapp Number | Mira Road call girls | Call Girls in Thane Mumbai | Call Girls in Chembur | Call Girl Service in Powai | Call Girls in Goregaon | Call Girls Nerul | Call Girl Service Malad | Kurla Call Girls | Call Girls Service in Juhu | Call Girls Agency in Sakinaka | Call Girls in Dahisar | Call Girls in Dombivali |
tom Email Homepage
2023-12-14 21:27
What a fantastic post! Your sharing of valuable information regarding assignment writing services in Australia is truly appreciated. The insights you provide are invaluable, and it's evident that you've compiled a wealth of knowledge. For those grappling with academic challenges, the recommendation to contact your expert team at Assignment Help in Australia is a reassuring beacon. Your commitment to offering support and solutions is commendable, making it clear that students don't have to navigate the complexities alone. I'm thankful for the helpful guidance and will certainly keep Assignment Help in Australia in mind for any future academic assistance. Keep up the excellent work!https://www.assignmenthelppro.com/au/
ritukaur Email Homepage
2023-12-20 18:00
Hello......am Ritu Kaur From Chandigarh Escorts always give their customer an excellent means to find erotic pleasure. These babes are sexually tempting and know the ways of giving high-fi sexual time to their customers. <a href="http://www.ritukaur.in">Chandigarh Escorts</a>http://www.ritukaur.in
kavyasharma Email Homepage
2023-12-20 20:36
i am Kavya sharma from Lucknow Independent Escorts are meant to work out really<a href="http://kavyasharma.in/">Lucknow Escorts</a>http://kavyasharma.in/
kavyasharma Email Homepage
2023-12-20 20:37
Escorts in Lucknow pose hardly any risk to their customers Regarding the personal identities of the clients, the ladies connected to our agency are the real gems performing their level best. As these babes are matured enough to understand their customers fully, there would be no issues aroused while you decide to stay in close touch with Lucknow Escorts. http://kavyasharma.in/
kudilo Email
2023-12-21 04:23
Welcome to VIP Chandigarh Escort Service! Most genuine & authentic Escort agency in Chandigarh where you get the best mind boggling orgasm 24/7 unlimited fun.
Mumbai Escorts Email Homepage
2023-12-21 11:15
Mumbai Escorts girls are incredibly hot and glamorous. They always keep their look decant due to which clients get more interacted, maximum enjoyment while having the best time spending with them.https://www.nearmeescorts.in
PAKISTANI BEAUTY Email
2024-1-2 01:24
If you want only the best Escort Service in Islamabad then our website is the only destination. We have collaborated with only the best Call Girls In Islamabad from all over the world. Yeah, you heard us right; we don’t just deal with Pakistani girls; we have girls from other countries too. Whatever you want, you will get it from our website. Clients call us the best in class because we are indeed the best in class. There are lots of women in this world, but nothing is better than Call Girls In Islamabad. If you haven’t hired them before, then you are making a big mistake, for sure.https://pakistanibeauty.com/call-girls-in-islamabad/
SONIA NAEEM Email
2024-1-4 04:43
Specifically, it's indispensable for revolve around thriving and amenability while seeking out <a title="Escort service in Pakistan" href="https://pakcallgirls.com/">Escort service in Pakistan</a>. Search for affiliations that have an outrageous screening process for their escorts, ensuring that they are of genuine age and are providing their administrations willingly. Furthermore, a genuine affiliation will focus in on the security of their clients, ensuring that all interactions are kept secret.
model escort in Amritsar Email Homepage
2024-1-17 13:29
We take pride in providing a seamless booking process and ensuring our clients have an unforgettable experience with our Call girls Amritsar. Our rates are competitive, and we offer flexible payment options to suit your needs Escort in Amritsar .
Haridwar Escorts Email
2024-1-20 18:04
The escort industry has been a controversial topic for many years, with debates surrounding its legality and morality.https://www.streetgirls.in/Haridwar-escorts
EdhaCare Email
2024-1-22 14:44
Limb Lengthening Surgery cost in India varies depending on several factors, including the type of procedure, the complexity of the case, and the hospital or clinic chosen for the surgery.https://www.edhacare.com/blogs/limb-lengthening-surgery-cost-in-india/
Escorts in Lahore Email Homepage
2024-1-24 17:48
Get 100% Satisfied Escort Service in Lahore at Discounted Prices You must work with our agency if you want the most dashing and stunning Escort Service in Lahore. Our Lahore escorts service and ability to match escort profiles to your choices have won us recognition. You are probably satisfying your hidden urges if you are using our services. Giving our girls a love bite increases their quality tenfold visit our website:- https://lahorecelebrity.com/https://lahorecelebrity.com/
Karachi Escorts Email Homepage
2024-1-24 17:49
Get 100% Satisfied Escort Service in Karachi at Discounted Prices You must work with our agency if you want the most dashing and stunning Escort Service in Karachi. Our Karachi escorts service and ability to match escort profiles to your choices have won us recognition. You are probably satisfying your hidden urges if you are using our services. Giving our girls a love bite increases their quality tenfold visit our website:- https://karachimodelss.com/https://karachimodelss.com/
分页: 53/56 第一页 上页 48 49 50 51 52 53 54 55 56 下页 最后页
发表评论
表情
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
打开HTML
打开UBB
打开表情
隐藏
记住我
昵称   密码   游客无需密码
网址   电邮   [注册]