[ Previous | Next | Contents | Glossary | Home | Search ]
AIX Version 4.3 Commands Reference, Volume 3

lastcomm Command

Purpose

Displays information about the last commands executed.

Syntax

lastcommCommand ] [ Name ] [ Terminal ]

Description

The lastcomm command displays information, in reverse chronological order, about all previously executed commands that are still recorded in the summary files in the /var/adm/pacct directory. You need to run the /usr/sbin/acct/startup command before you can execute the lastcomm command.

The list the lastcomm command displays can be restricted to:

For each process, the following information is displayed:

Examples

  1. To display information about all previously executed commands recorded in the /var/adm/pacct file, enter:
    lastcomm
  2. To display information about commands named a.out executed by the root user on the ttyd0 terminal, enter:
    lastcomm a.out root ttyd0

Files

/usr/bin/lastcomm Contains the lastcomm command.
/var/adm/pacct The directory that contains the current accounting summary files.

Related Information

The acctcms command.

For more information about the Accounting System, the preparation of daily and monthly reports, and the accounting files, see the 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 describes the steps you must take to establish an accounting system.


[ Previous | Next | Contents | Glossary | Home | Search ]