Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

On a Ubuntu 9.10 system:

$ uname -a
Linux ionut-laptop 2.6.31-14-generic #48-Ubuntu SMP Fri Oct 16 14:04:26 UTC 2009 i686 GNU/Linux

the files /var/log/wtmp and /var/log/btmp are empty:

$ ls -la /var/log/?tmp
-rw-rw---- 1 root utmp 0 2010-04-10 16:54 /var/log/btmp
-rw-rw-r-- 1 root utmp 0 2010-04-10 16:54 /var/log/wtmp

Because of this, the last(1) command is not working.

What to do?

share|improve this question

I'd suggest your problem is that it's being rotated. What does ls -la /var/log/?tmp* show?

Does your /etc/logrotate.conf have entries for wtmp and btmp?

share|improve this answer

You must log in to answer this question.