Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

What does `utmp' stand for?

443 views
Skip to first unread message

James Jensen

unread,
Sep 8, 2000, 10:19:08 AM9/8/00
to
For what does the utmp or wtmp file structure stand? Is it a
historical acronymn?

utmp(5) and wtmp(5) just say ``login records.'' Well, duh. However,
does utmp stand for user temporary table or something?

Thanks

--
3lixy...@iname.com

Bill Wilson

unread,
Sep 18, 2000, 9:24:48 PM9/18/00
to

Pulling out my Bell Laboratories UNIX System V User's Manual (Issue 1 -
June 1982),
I find the following:

utmp(4)
utmp(4)

NAME
utmp, wtmp - utmp and wtmp entry formats

SYNOPSIS
#include <sys/types.h>
#include <utmp.h>

DESCRIPTION
These files, which hold user and accounting information for such
com-
mands as who(1), write(1), and login(1), have the following
structure as
defined by <utmp.h>:

etc., etc., file structure definitions, etc.


If Thompson and Ritchie had any other names for these files (/etc/utmp
and
/etc/wtmp), they did not put them in the User's Manual. Or the System
Administrator's Guide, I checked that too. ;)


Bill

Steve Ketcham

unread,
Sep 19, 2000, 3:00:00 AM9/19/00
to
James Jensen wrote:
>
> For what does the utmp or wtmp file structure stand? Is it a
> historical acronymn?

I found my sixth edition documentation the other day:

UTMP(V) 9/10/73 UTMP(V)

NAME
utmp - user information

DESCRIPTION

This file allows one to discover information about who is currently
using UNIX. The file is binary; each entry is 16(10) bytes long. The
first eight bytes contain a user's login name or are null if the table
slot is unused. The low order byte of the next word contains the last
character of a typewriter name. The next two words contain the user's
login time. The last word is unused.

FILES
/etc/utmp

SEE ALSO

init (VIII) and login(I), which maintain the file; who(I) which
interprets it.


WTMP(V) 2/22/74 WTMP(V)

NAME
wtmp - user login history

DESCRIPTION

This file records all logins and logouts. Its format is exactly like
utmp(V) except that a null user name indicates a logout on the
associated
typewriter. Furthermore, the typewriter name '~' indicates the system
was rebooted at the indicated time; the adjacent pair of entries with
typewriter names '|' and '}' indicate the system-maintained time just
before
and just after a date command has changed the system's idea of the
time.

Wtmp is maintained by login(I) and init(VIII). Neither of these
programs
creates the file, so if it is removed record-keeping is turned off.
It is
summarized by ac(VIII).

FILES
/usr/adm/wtmp

SEE ALSO
utmp(V), login(I), init(VIII), ac(VIII), who(I)



Steve Ketcham Steve_...@stratus.com
Stratus Computer, Inc Project Manager, Professional Services
111 Powdermill Rd Telephone: (978) 461-7406
Maynard, MA 01754 Not speaking for Stratus Computer.

James Jensen

unread,
Sep 20, 2000, 3:00:00 AM9/20/00
to
Steve Ketcham <Steve_...@stratus.com> wrote:

: James Jensen wrote:
:> For what does the utmp or wtmp file structure stand? Is it a
:> historical acronymn?

: utmp - user information
: wtmp - user login history

My Linux/BSD man pages only state ``login records.'' The reason that I
am asking is that I am doing a /very/ Unix-like (of course) database
architecture design for a product. I have an user audit table that I
am structuring osimilar to the utmp/wtmp record layout, and have righly
named that table `wtmp' :-)

Got me thinking, what in the world is that name supposed to mean. BTW,
do you know how exactly the login times are calculated upon a
terminating `typewriter' or terminal? If one doesn't explicitly
logout, and say the shell is kill 9ed, how does this keep track.

In my database I am using a `terminal' hash number that I relate when I
join the table onto itself and calculate the sum of the differences in
timestamps.

--
J. S. Jensen
mailto:jsje...@iname.com


James Jensen

unread,
Sep 20, 2000, 3:00:00 AM9/20/00
to
Bill Wilson <bill...@enter.net> wrote:

: If Thompson and Ritchie had any other names for these files (/etc/utmp


: and
: /etc/wtmp), they did not put them in the User's Manual. Or the System
: Administrator's Guide, I checked that too. ;)

I checked a few SA guides, and nothing comes close. With your manual
there, I can only speculate, it seems as though this may be one of the
great Unix mysteries to me. :-)

Thanks.

--
J. S. Jensen
maito:jsje...@iname.com


Bill Vermillion

unread,
Sep 21, 2000, 3:00:00 AM9/21/00
to
In article <8qamnp$1e...@holly.ColoState.EDU>,
James Jensen <jpje...@holly.ColoState.EDU> wrote:
>Steve Ketcham <Steve_...@stratus.com> wrote:

>: James Jensen wrote:
>:> For what does the utmp or wtmp file structure stand? Is it a
>:> historical acronymn?

>: utmp - user information


>: wtmp - user login history

>My Linux/BSD man pages only state ``login records.'' The reason that I
>am asking is that I am doing a /very/ Unix-like (of course) database
>architecture design for a product. I have an user audit table that I
>am structuring osimilar to the utmp/wtmp record layout, and have righly
>named that table `wtmp' :-)

>Got me thinking, what in the world is that name supposed to mean. BTW,
>do you know how exactly the login times are calculated upon a
>terminating `typewriter' or terminal? If one doesn't explicitly
>logout, and say the shell is kill 9ed, how does this keep track.

Well I don't know HOW it does it, but I just killed a session that
I saw using who utmp, and it disappeared from utmp. utmp is
supposed to be currently logged in users. Now what about all those
unamed users who have been logged in since December 31 :-)


--
Bill Vermillion - bv @ wjv . com

0 new messages