Usenet comp.unix.tru64 (2000-2013)
 help / color / mirror / Atom feed
From: Frank J. Perricone <frank@dlc.state.vt.us>
Subject: Re: "top" utility
Date: Wed, 20 Dec 2000 17:32:12 -0500	[thread overview]
Message-ID: <bcf14ts96bpmtqckqkq8jvqns46fhjida3@4ax.com> (raw)
In-Reply-To: 3A3F90DB.EEF62589@ford.com

On Tue, 19 Dec 2000 11:46:19 -0500, Jack Patteeuw <jpatteeu@ford.com>
wrote:

> KISS ... and it works for multiple CPUs !!!
> 
> echo %CPU "USER        PID   PPID TTY      %MEM S     STARTED       
> TIME PSR COMMAND"
> ps -e -opcpu= -ouser= -opid= -oppid= -otty= -opmem= -ostate= -ostart=
> -otime= -opsr= -ocommand= | sort -rn | head -n 20

In ksh, replace the 20 with ${1:-20} and it allows you to type "top 5" or
"top 10" or whatever, while still allowing just "top".

-- 
Frank J. Perricone                               frank@dlc.state.vt.us
IT Manager                                                802-828-4926
Vermont Department of Liquor Control                 Fax: 802-828-2803
http://www.state.vt.us/dlc/            http://www.sover.net/~hawthorn/




  reply	other threads:[~2000-12-20 22:32 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-12-08 17:37 "top" utility Vimal Mohindra
2000-12-08 18:26 ` James Hanway
2000-12-09  8:08 ` Adam Price
2000-12-19 15:00 ` Anders Grund
2000-12-19 16:46 ` Jack Patteeuw
2000-12-20 22:32   ` Frank J. Perricone [this message]
2000-12-26 14:17 ` Adriano Prado
2000-12-27 10:13   ` Bourrel
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox