
512
|
Chapter 3: Linux Commands
This is the Title of the Book, eMatter Edition
Copyright © 2006 O’Reilly & Associates, Inc. All rights reserved.
-t, --time
Print the last system clock change.
-u, --users
Print a list of the users who are logged in.
--version
Print version information and then exit.
-w, -T, --mesg, --message, --writable
Include user’s message status in the output:
+ mesg y (write messages allowed)
- mesg n (write messages refused)
? Cannot find terminal device
-H, --heading
Print headings.
Example
This sample output was produced at 8 a.m. on April 17:
$ who -uH
NAME LINE TIME IDLE PID COMMENTS
Earvin ttyp3 Apr 16 08:14 16:25 2240
Larry ttyp0 Apr 17 07:33 . 15182
Since Earvin has been idle since yesterday afternoon (16 hours), it
appears that he isn’t at work yet. He simply left himself logged in.
Larry’s terminal is currently in use.
whoami
whoami
Print current user ID. Equivalent to id -un.
whois
whois[options] query[@server[:port]]
jwhois [options] query[@server[:port]]
Search a whois database for a domain name, IP address, or NIC
name. The information returned varies, but usually contains
administrative and technical contacts so that you can find a person
to handle problems at that domain. By default, the command
returns information on .com, .net, and .edu domains, but other
hosts can be queried for other domains using host or the -h option.
Options
-- Indicate the end of options. A subsequent string ...