Return to BSD News archive
Path: euryale.cc.adfa.oz.au!newshost.carno.net.au!harbinger.cc.monash.edu.au!news.cs.su.oz.au!metro!metro!munnari.OZ.AU!uunet!in1.uu.net!160.45.4.4!fu-berlin.de!irz401!orion.sax.de!uriah.heep!news From: j@uriah.heep.sax.de (J Wunsch) Newsgroups: comp.unix.bsd.freebsd.misc Subject: Re: Q: Is there something wrong with the 'ac' command Date: 19 May 1997 09:44:40 GMT Organization: Private BSD site, Dresden Lines: 32 Message-ID: <5lp7e8$42v@uriah.heep.sax.de> References: <337F45E3.7A97@xxsnet.net> Reply-To: joerg_wunsch@uriah.heep.sax.de (Joerg Wunsch) NNTP-Posting-Host: localhost.heep.sax.de Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Newsreader: knews 0.9.6 X-Phone: +49-351-2012 669 X-PGP-Fingerprint: DC 47 E6 E4 FF A6 E9 8F 93 21 E0 7D F9 12 D6 4E Xref: euryale.cc.adfa.oz.au comp.unix.bsd.freebsd.misc:41242 Sonya and Jeffrey Metcalf <metcalf@XXsnet.net> wrote: > I was recently experimenting with the FreeBSD accounting capabilities > and was attempting to use the 'ac' command. From the manual page > I see that 'ac' reads from the 'wtmp' file in the var directory > (sorry I don't recall the default path). The file is nonempty and > from looking at it from a binary editor, I can see that it contains > the type of information that ac is supposed to give. However whenever > I use that 'ac' command (as a regular user or as root), all I ever get > is > > Total 0.00 j@uriah 155% ac total 1001.49 The normal tools to examine the utmp file are who(1), and w(1). The regular tool to examine wtmp is last(1). ac(8) is a fairly complex accounting command, and you need to RTFM well in order to use it the way you actually intend. The default display is a little silly: If no arguments are given, ac displays the total connect time for all ac- counts with login sessions recorded in wtmp. -- cheers, J"org joerg_wunsch@uriah.heep.sax.de -- http://www.sax.de/~joerg/ -- NIC: JW11-RIPE Never trust an operating system you don't have sources for. ;-)