Re: ps performance sucks

Bill Davidsen (davidsen@tmr.com)
Fri, 8 Nov 2002 16:05:53 -0500 (EST)


This message is in MIME format. The first part should be readable text,
while the remaining parts are likely unreadable without MIME-aware tools.
Send mail to mime@docserver.cac.washington.edu for more info.

--1170656797-2036164466-1036789553=:4445
Content-Type: TEXT/PLAIN; charset=US-ASCII

On Thu, 7 Nov 2002, Albert D. Cahalan wrote:

> Are you a vmstat user? Suggestions are needed; it's getting a rewrite.
> I may even change the default format, assuming people don't all
> have scripts that parse the output. How do you like this?
>
> procs ------------memory----------- ---swap-- ----io--- --system-- ----cpu----
> r b swpd free buff cache act !act si so bi bo in cs us sy id wa
> 0 0 304k 14m 2.5m 27m 16m 23m 0 0 0 0 33 4 0 0 90 9
> 0 0 304k 14m 2.5m 27m 16m 23m 0 0 0 0 114 12 1 0 88 11
> 0 0 304k 14m 2.5m 27m 16m 23m 0 0 0 0 104 6 0 1 91 8

The reason I maintain vmstat2 (NOT based on any of your code AFAIK) is
that I want to see data rates on the non-loopback NICs. I also have a
timestamp every line option and after 2.5 settles a bit and I get the time
to find where things are I want optional stats by individual NIC, and
individual drive and partition if I can find it. It isn't in partitions
any more, and the file I was told to use doesn't exist. Maybe in devicefs?
Oh, and -M starts the output with memory sizes, for a package to generate
usage graphs with a line at physical memory size.

An option to flush the buffers after each line even when writing to a
pipe.

Line length: the w option in ps doesn't worry about it, why should vmstat?
If the user tells you to show more, do it.

vmstat2 output attached (it's wide).

-- 
bill davidsen <davidsen@tmr.com>
  CTO, TMR Associates, Inc
Doing interesting things with little computers since 1979.

--1170656797-2036164466-1036789553=:4445 Content-Type: TEXT/PLAIN; charset=US-ASCII; name="x.tmp" Content-Transfer-Encoding: BASE64 Content-ID: <Pine.LNX.3.96.1021108160553.4445B@gatekeeper.tmr.com> Content-Description:

U2NyaXB0IHN0YXJ0ZWQgb24gRnJpIE5vdiAgOCAxNTo0OTo1NiAyMDAyDQpu ZXdzY29uMDI6ZWFydGhxdWFrZSQgdm1zdGF0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from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/