dump-acct
dump-acct
dumps some of the contents of one or more acct
files in human readable form. Usage:
dump-acct [opts] files
Unless called with the --raw
option, it prints a table with the
following fields, separated by vertical bars(|
):
ac_comm
name of the executed program
ac_version
version of the acct
file format
ac_utime
user time
ac_stime
system time
ac_etime
elapsed time
ac_uid
user id
ac_gid
group id
ac_mem
(average) memory usage
ac_io
number of characters transferred on input/output
ac_pid
process id
ac_ppid
parent’s process id
All times will be given in platform dependent units (“AHZ
”).
Not all of the above columns will actually appear, depending on what
information your operating system provides in it’s struct acct
.
--ahz hz
Use this flag to tell the program what AHZ
should be (in Hertz).
This option is useful if you are trying to view an acct
file
created on another machine which has a different value for AHZ
.
--byteswap
Swap the bytes (relative to your system’s native byte order) in
--raw
output.
--format
Set output format with --raw
option.
-n num
--num num
Limit the number of lines (or records with --raw
) to print.
-r
--reverse
Read the accounting file backwards (print latest record first).
-R
--raw
Don’t print human readable output, dump the raw record instead. Useful to convert between different Linux file formats (see below).
-h
--help
Print dump-acct
’s usage string and default location of
the accouning file to standard output.
--byteswap
and --format
options are only available with
Linux multiformat support. They only affect output with
the --raw
option, format and byte order of the input are
automatically detected.
Thus they are useful to convert between different file formats.
The --ahz
option affects input and output (except for v3 file
format, which by definition is fixed to AHZ=100
).
If you ever need to convert between different AHZ
values,
use a two-step process:
First convert to v3 format with the old AHZ
value, then
convert to the desired output format with the new AHZ
setting.