From owner-freebsd-hackers Sat Oct 4 01:10:20 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id BAA05560 for hackers-outgoing; Sat, 4 Oct 1997 01:10:20 -0700 (PDT) Received: from word.smith.net.au (ppp20.portal.net.au [202.12.71.120]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id BAA05549 for ; Sat, 4 Oct 1997 01:10:15 -0700 (PDT) Received: from word.smith.net.au (localhost.smith.net.au [127.0.0.1]) by word.smith.net.au (8.8.7/8.8.5) with ESMTP id DAA04089; Sat, 4 Oct 1997 03:52:07 +0930 (CST) Message-Id: <199710031822.DAA04089@word.smith.net.au> X-Mailer: exmh version 2.0zeta 7/24/97 To: Zoltan Sebestyen cc: FreeBSD hackers mailinglist Subject: Re: cpu/memory monitoring In-reply-to: Your message of "Fri, 03 Oct 1997 19:11:38 +0200." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Sat, 04 Oct 1997 03:52:06 +0930 From: Mike Smith Sender: owner-freebsd-hackers@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk > I'd like to know if there's any other any other program than top, which > monitors the REAL cpu and memory load, but have more simple source code. What is "REAL cpu and memory load"? The problem here is, I think, that you have seen what Microsoft (and some other vendors) pass off as a "simple" CPU/memory monitor and think that there is some simple value that is "CPU load" or "memory load". In reality, things aren't so simple. What do you consider "memory load"? Do you mean all pages that have been recently referenced? All pages that are accounted for (ie. not "free")? Do you classify pages into degrees of "freeness"? And how do you propose to accumulate this figure? Traversing all of the memory information isn't cheap. If you want to get a feel for memory usage, and to give you some idea of the complexity involved, try looking at the output of 'vmstat -m'. And that's just the _kernel_. As for CPU load, again: what is "CPU load"? The amount of CPU time "not idle"? How about otherwise-idle time that is consumed in speculative makework? Is that "free but better-used"? How about interrupt time? The only way to present this sort of information is either to dumb it down Microsoft-style, or present it all and be generous enough to assume the user isn't completely stupid. mike