wtmp problem YDL 2.1


Subject: wtmp problem YDL 2.1
From: Erik Poelmans (p.erik@pandora.be)
Date: Mon Mar 18 2002 - 09:59:49 MST


Hi all.
I have a weird problem.
it seems like wtmp doesn't logg all user logouts.
sometimes its like
6 active users when there are only 2 active.
4 ghost users.
example ( user user user user user root) 6 users only 1 user and root is active (2 users) 4 ghost (user user user user)
i found a fix.. but its not very good i guess :

[ -f /var/run/utmpx -o -f /var/log/wtmpx ] && _NEED_XFILES=1

# Clean up utmp/wtmp
>/var/run/utmp
touch /var/log/wtmp
chgrp utmp /var/run/utmp /var/log/wtmp
chmod 0664 /var/run/utmp /var/log/wtmp
if [ -n "$_NEED_XFILES" ]; then
>/var/run/utmpx
  touch /var/log/wtmpx
  chgrp utmp /var/run/utmpx /var/log/wtmpx
  chmod 0664 /var/run/utmpx /var/log/wtmpx
fi

(code from /etc/rc.sysinit)

that will erase all user logins and you need to login again..
so the ghost users are gone..
i hope somebody could help thanks.



This archive was generated by hypermail 2a24 : Mon Mar 18 2002 - 10:16:24 MST