The file /var/account/pacct can not be used directly as it does not store accounting data in clear text format. Each time a process terminates a record for this process is appended to the accounting file.
In order to use this file to generate customize report from perl or shell script you need to convert this file in text format. You need to use dump-acct command which print an acct/pacct file in human-readable format.
# dump-acct /var/account/pacct
All fields are separated by vertical line. Fields are: command, user time, system time, effective time, uid, gid, memory, io, time. To print username and command you can use awk command in pipe as follows:
# dump-acct /var/account/pacct | awk -F'|' '{ print $1 " = " $5 }'
Please note that to print an utmp file in human-readable format use command dump-utmp as follows:
# dump-utmp /var/log/wtmp
- 30 Handy Bash Shell Aliases For Linux / Unix / Mac OS X
- Top 30 Nmap Command Examples For Sys/Network Admins
- 25 PHP Security Best Practices For Sys Admins
- 20 Linux System Monitoring Tools Every SysAdmin Should Know
- 20 Linux Server Hardening Security Tips
- Linux: 20 Iptables Examples For New SysAdmins
- Top 20 OpenSSH Server Best Security Practices
- Top 20 Nginx WebServer Best Security Practices
- 20 Examples: Make Sure Unix / Linux Configuration Files Are Free From Syntax Errors
- 15 Greatest Open Source Terminal Applications Of 2012

- My 10 UNIX Command Line Mistakes
- Top 10 Open Source Web-Based Project Management Software
- Top 5 Email Client For Linux, Mac OS X, and Windows Users
- The Novice Guide To Buying A Linux Laptop












{ 2 comments… read them below or add one }
Great command ….
Many Thanks
In my X86 – the file size is too large can any one tell me how can i reduce the size…
4.8 G pacct
1.5 G pacct.1