Debian – lastcomm command shows no results

accountsdebianlogging

I'm trying to monitor a user's activities on my Debian server.
I found, after Googling that the acct package should help me log all commands and let me filter them by user.

I installed the package, some features seem to work (like the ac command). But the most important one for me: lastcomm shows no results:

root@myserver:~# ac
    total        7.75
root@myserver:~# sa
root@myserver:~# lastcomm
root@myserver:~#

I believe it logs all activities in /var/log/account/pacct am I right?

root@myserver:~# ls -l /var/log/account/     
total 0
-rw-r----- 1 root adm 0 Aug 23 14:33 pacct
-rw-r----- 1 root adm 0 Aug 23 14:23 pacct.0

I also found sources saying it logs in /var/account/pacct but that file/directory doesn't exist.

I'm out of ideas here, so anyone?

Best Answer

As you can see from the above output, pacct size is 0 byte. Start the psacct/acct service, doing something and try again.