make CC='diet -Os gcc -W' rm ngetty make CC='diet -Os gcc -W' LDFLAGS='-s -Wl,-N' make ngetty.i386 # on i386 hostsIt uses then only two pages memory; one for text + data and one for stack.
riemann$ size /sbin/ngetty text data bss dec hex filename 1072 0 24 1096 448 /sbin/ngetty
cd /sbin cp ngetty-helper ngetty-helper.large install ngetty-helper.tiny ngetty-helper ls -la ngetty*
dumputmp /var/run/utmp dumputmp /var/log/wtmpWARNING: There is a program utmpdump in sysvinit package. My used different name to avoid conflicts.
who nwho -a nwho -aq nwho -a /var/log/wtmp nwho -aq /var/log/wtmpWARNING: I wrote nwho from scratch. May be its options are deffernt from the options of the standard who.
-rw-rw-r-- root utmp 4224 Dec 19 08:53 /var/run/utmpinstall cleanutmp with the same UID:GID and mode 2711. Then every user can execute cleanutmp before who, finger... Cron daemon can also start cleanutmp on every six hours.
On my box I can make/test bad utmp-entries with:
xterm & kill -9 %1 sleep 1 --- see the result --- dumputmp /var/run/utmp cleanutmp dumputmp /var/run/utmpTry to start who, finger before/after cleanutmp to see the difference.
Last modified: 25 May 2008