/usr/sbin/acct/ac [ -d ] [ -p ] [ -w File ] [ User ... ]
The ac command prints the total connect time for all users or the connect time for specified users. Records are based on who logged in during the life of the current wtmp data file.
Connect-time records are created by the init and the login programs and are collected in the /var/adm/wtmp file, if that file exists. The root user or a member of the adm group should create the /var/adm/wtmp file with an initial record length of 0 (zero). Records should be processed periodically to keep the file from becoming too full. If the file has not been created, the following error message is returned:
No /var/adm/wtmp
If the file becomes too full, additional wtmp files are created. These files can be printed, if specified with the -w flag.
Access Control: This command should grant execute (x) access to all users.
/usr/sbin/acct/ac
/usr/sbin/acct/ac smith jones
/usr/sbin/acct/ac -p smith jones
/usr/sbin/acct/ac | Contains the ac command. |
/var/adm/wtmp | Contains the active data file for the collection of connect-time records. |
For more information about the Accounting System, the preparation of daily and monthly reports, and the accounting files, see Accounting Overview in AIX Version 4.3 System Management Guide: Operating System and Devices.
Setting Up an Accounting System in AIX Version 4.3 System Management Guide: Operating System and Devices explains the steps you must take to establish an accounting system.