Jump to content United States-English
HP.com Home Products and Services Support and Drivers Solutions How to Buy
» Contact HP
More options
HP.com home
HP-UX Reference > R

rwhod(1M)

HP-UX 11i Version 3: February 2007
» 

Technical documentation

» Feedback
Content starts here

 » Table of Contents

 » Index

NAME

rwhod — system status server

SYNOPSIS

/usr/sbin/rwhod [-s] [-r]

DESCRIPTION

rwhod is the server that maintains the database used by rwho and ruptime (see rwho(1) and ruptime(1)). rwhod sends status information to and receives status information from other nodes on the local network that are running rwhod.

rwhod is started at system boot time if the RWHOD variable is set to 1 in the file /etc/rc.config.d/netdaemons.

As an information sender, it periodically queries the state of the system and constructs status messages that are broadcast on a network.

As an information receiver, it listens for other rwhod servers' status messages, validates them, then records them in a collection of files located in the /var/spool/rwho directory.

By default, rwhod both sends and receives information. rwhod also supports the following options:

-s

Configures server to be an information sender only.

-r

Configures server to be an information receiver only.

Status messages are generated approximately once every three minutes. rwhod transmits and receives messages at the port indicated in the who service specification (see services(4)). The messages sent and received, are of the form:

struct outmp { char out_line[8]; /* tty name */ char out_name[8]; /* user id */ long out_time; /* time on */ }; struct whod { char wd_vers; char wd_type; char wd_fill[2]; int wd_sendtime; int wd_recvtime; char wd_hostname[32]; int wd_loadav[3]; int wd_boottime; struct whoent { struct outmp we_utmp; int we_idle; } wd_we[1024 / sizeof (struct whoent)]; };

All fields are converted to network byte order before transmission. System load averages are calculated from the number of jobs in the run queue over the last 1-, 5- and 15-minute intervals. The host name included is the one returned by the gethostname() system call (see gethostname(2)). The array at the end of the message contains information about the users logged in on the sending machine. This information includes the contents of the utmp entry for each non-idle terminal line and a value indicating the time since a character was last received on the terminal line (see utmp(4)).

rwhod discards received messages if they did not originate at a rwho server's port, or if the host's name, as specified in the message, contains any unprintable ASCII characters.

Valid messages received by rwhod are placed in files named whod.hostname in the /var/spool/rwho directory. These files contain only the most recent message in the format described above.

WARNINGS

rwhod does not relay status information between networks. Users often incorrectly interpret the server dying as a machine going down.

AUTHOR

rwhod was developed by the University of California, Berkeley.

FILES

/var/spool/rwho/whod.*

Information about other machines.

SEE ALSO

rwho(1), ruptime(1), gethostname (2), services (4), utmp (4).

Printable version
Privacy statement Using this site means you accept its terms Feedback to webmaster
© 1983-2007 Hewlett-Packard Development Company, L.P.