NAME#名稱
who - show who is logged on#顯示現在誰在登入這台機器上
SYNOPSIS#概要
who [OPTION]... [ FILE | ARG1 ARG2 ]
DESCRIPTION#描述
-H, --heading
print line of column headings#列出每一行的所代表的意思 EX:USER LINE LOGIN-TIME FROM Erif pts/0 Oct 5 11:41 yckuo pts/1 Oct 5 14:29 yckuo pts/2 Oct 5 14:36
-i, -u, --idle
add user idle time as HOURS:MINUTES, . or old#額外顯示使用者閒置的時間 EX:Erif pts/0 Oct 5 11:41 02:33 yckuo pts/1 Oct 5 14:29 00:12 yckuo pts/2 Oct 5 14:36 .
-l, --lookup
attempt to canonicalize hostnames via DNS#藉由DNS查出標準的來源主機名稱
EX:Erif pts/0 Oct 5 11:41 (Erif.Dorm13.NCTU.edu.tw)
yckuo pts/1 Oct 5 15:00 (yuki.Dorm8.NCTU.edu.tw)
yckuo pts/2 Oct 5 15:00 (yuki.Dorm8.NCTU.edu.tw)-m only hostname and user associated with stdin#只顯示來源主機名稱以及使用者資訊
intel4.csie.nctu.edu.tw!yckuo pts/2 Oct 5 15:00
-q, --count
all login names and number of users logged on#列出所有登入的使用者和總數 EX:Erif yckuo yckuo
# users=3
-s (ignored)#就跟who一樣,內定的參數值
-T, -w, --mesg
add user's message status as +, - or ?#顯示使用者訊息狀態 EX:Erif + pts/0 Oct 5 11:41 yckuo + pts/1 Oct 5 15:00 yckuo + pts/2 Oct 5 15:00
--message
same as -T#和參數-w, -T一樣的用法
--writable
same as -T#和參數-w, -T一樣的用法
--help display this help and exit#顯示說明文件
--version
output version information and exit#查詢版本資訊
REPORTING BUGS#回報臭蟲
Report bugs to
.
SEE ALSO#額外參考文件
The full documentation for who is maintained as a Texinfo manual. If the info and who programs are
installed at your site, the commandproperly
info who
should give you access to the complete manual.
COPYRIGHT#版權資訊
Copyright ?1999 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
GNU sh-utils 2.0 August 1999
who
ami 只列出與自己相關的登入資訊
-H or --heading 顯示各欄位的標題列
-I or –u or –idle
顯示閒置時間,若該使用著在前一分鐘錢之內有進行任何行動,將標示成”.”,如果該使用者已超過24
小時沒有任何動作,則標示出”old”字串
-m 此參數之效果和指定”ami”字串相同
-q or –count 只顯示出登入系統的帳號行稱和M總人數,使用本參數將忽略其它參數
-s 此參數忽略不予處理,僅負責解決who指令其孕扛岩貌漪萛e性問題
-w –T –mesg –message –writable
顯示使用者的訊息狀態攔。訊息之狀態標示共有3種:”+”、”-”和”?”,分別代表接受write指令傳
來的訊息,不接受write指令的訊息,以及找不到終端機周邊設備
--help 顯示線上說明
--version 顯示版本訊息
可在who指令後面加上紀錄檔的名稱,取代存放在/var/log目錄下的wtmp檔案,用來查詢以前的使用者登入紀錄。假設加在who後面的字串是”am I”,則會顯示本地主機名稱和本帳號的相關資訊
[northstar@FROZENN ~]$ who -l
northstar pts/0 Oct 5 00:59 (ccsun3.csie.nctu.edu.tw)
[northstar@FROZENN ~]$ who -m
FROZENN.Dorm13.NCTU.edu.tw!northstar pts/0 //user登入的主機名稱及登入的帳號 |
Oct | 5 00:59 |
[northstar@FROZENN ~]$ who -q
northstar
# users=1 | |
//列出線上所有users並於# users=統計人數 | |
[northstar@FROZENN ~]$ | who -s |
northstar pts/0 Oct //同不加任何參數 |
5 00:59 |
[northstar@FROZENN ~]$ | who -T |
northstar + pts/0 //這個我真的不知道了@@ |
Oct 5 00:59 |
[northstar@FROZENN ~]$ who --version
who (GNU sh-utils) 2.0
Written by Joseph Arceneaux and David MacKenzie.
//show出此RedHat的版本
[northstar@FROZENN ~]$ who --help
Usage: who [OPTION]... [ FILE | ARG1 ARG2 ]
-H, | --heading | print line of column headings |
-i, | -u, --idle | add user idle time as HOURS:MINUTES, . or old |
-l, | --lookup | attempt to canonicalize hostnames via DNS |
-m | only hostname and user associated with stdin | |
-q, | --count | all login names and number of users logged on |
-s | (ignored) | |
-T, | -w, --mesg | add user's message status as +, - or ? |
--message | same as -T | |
--writable | same as -T | |
--help | display this help and exit | |
--version | output version information and exit |
If FILE is not specified, use /var/run/utmp. /var/log/wtmp as FILE is common. If ARG1 ARG2 given, -m presumed: `am i' or `mom likes' are usual.
Report bugs to
//show出who這個指令的求救(help)畫面,包含可加的參數