You can display formatted reports about the CPU usage by process or by user with a combination of the acctprc1, acctprc2, and prtacct commands.
The acctprc1 command requires input in the total accounting record form (acct file format). This implies that you have process accounting turned on or that you have run process accounting in the past. See "Setting Up an Accounting System" for guidelines.
To produce a formatted report of CPU usage by process, enter:
acctprc1 </var/adm/pacct
This information will be useful in some situations, but you will probably also want to summarize the CPU usage by user. The output from this command is used in the next procedure to produce that summary.
acctprc1 </var/adm/pacct >out.fileThe /var/adm/pacct file is the default output for process accounting records. You may want to specify an archive pacct file instead.
acctprc2 <out.file >/var/adm/acct/nite/daytacct
Note: The daytacct file is merged with other total accounting records by the acctmerg command to produce the daily summary record, /var/adm/acct/sum/tacct.
prtacct </var/adm/acct/nite/daytacct