[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Memory vs Total memory usage (incl. children)

From: Lapa Vikentsi
Subject: Memory vs Total memory usage (incl. children)
Date: Mon, 23 May 2011 12:09:02 +0300

Hello, all

I use  monit 5.2.3 on my CentOS 5.4 system to monitor apache server
and many other processes.

Main question:
Why Monit display different memory consumption on System and Proccess
status on http page?
I try search similar questions in maillist arhcive but it have only
half answer to my question

Below I explain details. My http page looks like

Monit Service Manager
System Status Load CPU Memory Swap
                       893436 kB
Process Status Uptime CPU     Memory
httpd                         22748 kB

Total sum of all processes is 402276 kB and system is  893436 kB

>From main page I can quickly found which process consume more memory.
But I need  go over all processes to find one with largest

I go to link http://localhost/monit/httpd and view following

httpd   running 7d 9h 0m        0.0%    2.1% [22748 kB]
Memory usage    2.1% [22748kB]k
Total memory usage (incl. children)     14.0% [147508kB]

Why on main page monit show Memory usage and not Total memory usage
(incl. children) ?

I look in code and found that output differ on one line of code
          "<td align=\"right\"><font%s>%.1f%% [%ld&nbsp;kB]</font></td></tr>",
          (s->error & Event_Resource)?" color='#ff0000'":"",

-          s->inf->priv.process.mem_percent/10.0,

+          s->inf->priv.process.total_mem_percent/10.0,

But I am not developer and can't  predict effect of such changes.
Please, tell thoughts about such "improvement".

reply via email to

[Prev in Thread] Current Thread [Next in Thread]