SUMMARYOn help on accounting

From: Noam Kaminer (
Date: Mon Jun 05 1995 - 05:37:27 CDT

Help on understanding accounting.

The question was:

I am looking for a yardstick or a way to determine the relative usage of
different commands/applications by users of the same machine. The unit is
not so important. What is important is that I will be able to say that in a
certain period of time X used ftp x units while Y used it only y units and
that will mean that X spent more real time than Y on the application.

I am thinking of using the accounting system to do that. The daily pacct
files give me (through the acctcom comand) among other things the
"elapsed time" a user used a command.
I could not find a good explanation of what elapsed time is.
In the literature it is explained that elapsed time is the REAL (SECS)
column. Which is the difference between START TIME and END TIME.

#accton root ? 03:00:15 03:00:15 0.05 0.04 102.00
turnacct adm ? 03:00:14 03:00:14 0.38 0.02 100.00
mv adm ? 03:00:15 03:00:15 0.08 0.04 119.00

But what do these numbers really mean?

sed 570 pts/2 05:24:14 05:24:14 0.14 0.05 91.20
What does it mean that user 570 had elapsed time of using sed for 0.14
seconds? What does this mean in terms of the user's time?


elm 190 pts/3 05:29:27 05:29:27 0.01 0.01 1412.00
elm 190 pts/3 05:29:51 05:30:25 34.29 0.01 4.00
elm 190 pts/3 05:30:28 05:30:31 3.60 0.01 1428.00
elm 190 pts/3 05:30:38 05:30:44 6.69 0.01 104.00
elm 190 pts/3 05:30:47 05:30:50 3.46 0.01 128.00
elm 190 pts/3 05:29:27 05:30:56 89.92 0.56 25.50

What does each line represent? Or , if I will add all these seconds will this
be the time from when the users entered elm at the prompt till the time
s/he quitted from elm?

Another question:
In O'Leary & Wood "Advanced System Administration" and other books
the authors mention the daily and monthly summary usage reports as files
that can be used for accounting. But in those files as far as I could
understand you can not get a break down by user and command. Is it


Stephen Waelder explains:
(Voice: 817 378 2590; Fax: 817 378 2593; Email: )

Elapsed time is the amount of time that a user sits there waiting for
a command to finish. Try it with:

        sleep 60

You'll see that very little CPU time is consumed to perform the
command but the elapsed time will be, wow even a stopwatch can tell,
60 seconds.

In a multitasking system, processes or tasks are executed one at a
time. If your system has multiple processors, that the same number
are executed at a given time. But when your processes share of the
processor is consuled or requires the system to wait for i/o the CPU
time clock stops ( it does not count when the process is not being
worked on ) but the elapsed time continues to be counted just like a
stopwatch or a clock on the wall.

Just keep in mind that elapsed time is how long it takes for the
command to complete and CPU time is how much time the CPU
applied to completing the task.

I also found in "Unix Power Tools" p. 758:

"Elapsed time is the wall clock time from the moment you enter
the command until it terminates including time spent waiting for
other users, I/O time etc. By definition, the elapsed time is greater
then your total CPU time and can even be several times larger."

>From Roderick W. Failing III Phone: (810) 624-5200 ext. 1930
 Fax: (810) 669-5018
For JobAcct contact:

There are at least two third party products that will do what you want.
better of the two is called JobAcct from UniSolutions, the other is from
GEJAC. We treid GEJACs product several years ago and it had several
falls that were unacceptable. They maybe fixed now. JobAcct we have not
tried, but the write up on Suns Sep-Dec 94 Catalyst CD make it look better
and it did not have the short falls of GEJACs product.

UNISOL Utilities run on most UNIX systems and are available from:
In the United States and worldwide:

        UniSolutions Associates
        Tel. 310-542-0068
        Fax 310-370-4024
        2103 Mathews Avenue, Suite 1
        Redondo Beach, CA 90278

In Scandinavia:

        TT-ProSolution Oy
        Tel. +358-41-638 911
        Fax +358-41-620 766
        Matarankatu 2
        FIN-40100 JYVASKYLA

In Australia and New Zealand:

        Prophecy Technologies Pty Ltd.
        Tel. +61 3 550-1863
        Fax +61 3 561-3202
        Suite 22, 21 Aristoc Road,
        Glen Waverley, Victoria 3150

GEJAC can be contacted at:

GEJAC Incorporated
8643 Cherry Lane
(301)725-2500 or (800)432-7727
FAX (301)725-7196
These are per Sun Catalyst CD

>From Kevin Sheehan (

I have a summary package that works on the accounting files and gives you
a summary by user/command and command/user sorted on various metrics.

If you're intrested, I can send a copy.

Thanks to all of you.

Summary by Noam Kaminer

This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:10:26 CDT