9736c4ddb6
Submitted by: kano at na rim or jp
220 lines
5.6 KiB
Groff
220 lines
5.6 KiB
Groff
.\" Copyright (c) 1980, 1990, 1993
|
||
.\" The Regents of the University of California. All rights reserved.
|
||
.\"
|
||
.\" Redistribution and use in source and binary forms, with or without
|
||
.\" modification, are permitted provided that the following conditions
|
||
.\" are met:
|
||
.\" 1. Redistributions of source code must retain the above copyright
|
||
.\" notice, this list of conditions and the following disclaimer.
|
||
.\" 2. Redistributions in binary form must reproduce the above copyright
|
||
.\" notice, this list of conditions and the following disclaimer in the
|
||
.\" documentation and/or other materials provided with the distribution.
|
||
.\" 3. All advertising materials mentioning features or use of this software
|
||
.\" must display the following acknowledgement:
|
||
.\" This product includes software developed by the University of
|
||
.\" California, Berkeley and its contributors.
|
||
.\" 4. Neither the name of the University nor the names of its contributors
|
||
.\" may be used to endorse or promote products derived from this software
|
||
.\" without specific prior written permission.
|
||
.\"
|
||
.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
||
.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||
.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
||
.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
||
.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||
.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
||
.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
||
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||
.\" SUCH DAMAGE.
|
||
.\"
|
||
.\" @(#)last.1 8.1 (Berkeley) 6/6/93
|
||
.\" %FreeBSD: src/usr.bin/last/last.1,v 1.16 2003/08/17 10:24:53 tjr Exp %
|
||
.\"
|
||
.\" $FreeBSD$
|
||
.\"
|
||
.Dd July 27, 2003
|
||
.Dt LAST 1
|
||
.Os
|
||
.Sh ̾¾Î
|
||
.Nm last
|
||
.Nd ºÇ¶á¥í¥°¥¤¥ó¤·¤¿¥æ¡¼¥¶¤ÎµÏ¿¤òɽ¼¨¤¹¤ë
|
||
.Sh ½ñ¼°
|
||
.Nm
|
||
.Op Fl swy
|
||
.Oo
|
||
.Fl d
|
||
.Sm off
|
||
.Op Oo Ar CC Oc Ar YY
|
||
.Op Ar MM DD
|
||
.Ar hh mm
|
||
.Op Ar .SS
|
||
.Sm on
|
||
.Oc
|
||
.Op Fl f Ar file
|
||
.Op Fl h Ar host
|
||
.Op Fl n Ar maxrec
|
||
.Op Fl t Ar tty
|
||
.Op Ar user ...
|
||
.Sh ²òÀâ
|
||
.Nm
|
||
¥æ¡¼¥Æ¥£¥ê¥Æ¥£¤Ï»ØÄꤵ¤ì¤¿
|
||
.Ar user ,
|
||
.Ar tty ,
|
||
¤ä
|
||
.Ar host
|
||
¤Ç¤Î¥í¥°¥¤¥ó¤·¤Æ¤«¤é¥í¥°¥¢¥¦¥È¤Þ¤Ç¤ò
|
||
ºÇ¶á¤Îʪ¤«¤éɽ¼¨¤·¤Þ¤¹¡£
|
||
¤Þ¤¿¤Ï¡¢ËÜ¥³¥Þ¥ó¥É¤Ï¡¢»ØÄꤷ¤¿»þ¹ï¤Ë¥í¥°¥¤¥ó¤·¤Æ¤¤¤¿¥æ¡¼¥¶¤òɽ¼¨¤·¤Þ¤¹¡£
|
||
½ÐÎϤγƹԤˤϡ¢¥æ¡¼¥¶Ì¾¡¢¥»¥Ã¥·¥ç¥ó¤ò½èÍý¤·¤¿ tty¡¢¥Û¥¹¥È̾¡¢¥»¥Ã¥·¥ç¥ó¤Î
|
||
³«»Ï¤ª¤è¤Ó½ªÎ»»þ¹ï¡¢¥»¥Ã¥·¥ç¥ó¤Î´ü´Ö¤Î¾ðÊ󤬴ޤޤì¤Þ¤¹¡£¥»¥Ã¥·¥ç¥ó¤¬¤Þ¤À
|
||
·Ñ³Ãæ¤Ç¤¢¤ë¤«¡¢¥¯¥é¥Ã¥·¥å¤Ê¤¤¤·¥·¥ã¥Ã¥È¥À¥¦¥ó¤Ë¤è¤êÃæÃǤµ¤ì¤¿¾ì¹ç¤Ï
|
||
¤½¤Î¤è¤¦¤Ëɽ¼¨¤µ¤ì¤Þ¤¹¡£
|
||
.Pp
|
||
¼¡¤Î¥ª¥×¥·¥ç¥ó¤¬»ÈÍѲÄǽ¤Ç¤¹:
|
||
.Bl -tag -width indent-two
|
||
.It Fl d Ar date
|
||
¥¹¥Ê¥Ã¥×¥·¥ç¥Ã¥È¤ÎÆü»þ¤ò»ØÄꤷ¤Þ¤¹¡£
|
||
¤½¤Î¥¹¥Ê¥Ã¥×¥·¥ç¥Ã¥È¤ÎÆü»þ¤Ë¥í¥°¥¤¥ó¤·¤Æ¤¤¤¿Á´¥æ¡¼¥¶¤¬Êó¹ð¤µ¤ì¤Þ¤¹¡£
|
||
Êݸ¤µ¤ì¤Æ¤¤¤ë
|
||
.Pa wtmp
|
||
¥Õ¥¡¥¤¥ë¤«¤é·ë²Ì¤ò°ú¤½Ð¤¹¤¿¤á¤Ë¡¢
|
||
.Fl f
|
||
¥ª¥×¥·¥ç¥ó¤ò»ÈÍѲÄǽ¤Ç¤¹¡£
|
||
ËÜ¥ª¥×¥·¥ç¥ó¤¬»ØÄꤵ¤ì¤ë¤È¡¢
|
||
.Fl f
|
||
¤È
|
||
.Fl n
|
||
°Ê³°¤ÎÁ´¥ª¥×¥·¥ç¥ó¤Ï̵»ë¤µ¤ì¤Þ¤¹¡£
|
||
°ú¿ô¤Ï¼¡¤Î½ñ¼°¤Ç¤¢¤ë¤Ù¤¤Ç¤¹:
|
||
.Sm off
|
||
.Op Oo Ar CC Oc Ar YY
|
||
.Op Ar MM DD
|
||
.Ar hh mm
|
||
.Op Ar .SS
|
||
.Sm on
|
||
¤³¤³¤Ç¡¢³Æʸ»ú¤ÎÁȤϼ¡¤Î°ÕÌ£¤Ç¤¹:
|
||
.Pp
|
||
.Bl -tag -width Ds -compact -offset indent
|
||
.It Ar CC
|
||
ǯ¤ÎºÇ½é¤Î 2 ·å (À¤µª)¡£
|
||
.It Ar YY
|
||
ǯ¤Î¼¡¤Î 2 ·å¡£
|
||
.Ar YY
|
||
¤¬»ØÄꤵ¤ì¡¢
|
||
.Ar CC
|
||
¤¬»ØÄꤵ¤ì¤Ê¤¤¾ì¹ç¡¢
|
||
.Ar YY
|
||
¤Ë 69 ¤«¤é 99 ¤ÎÃͤò»ØÄꤹ¤ë¤È
|
||
.Ar CC
|
||
¤ÎÃÍ¤Ï 19 ¤Ë¤Ê¤ê¤Þ¤¹¡£
|
||
¤½¤¦¤Ç¤Ê¤¤¾ì¹ç¡¢
|
||
.Ar CC
|
||
¤ÎÃÍ¤Ï 20 ¤Ë¤Ê¤ê¤Þ¤¹¡£
|
||
.It Ar MM
|
||
·î¤Ç¤¢¤ê¡¢1 ¤«¤é 12 ¤Ç¤¹¡£
|
||
.It Ar DD
|
||
Æü¤Ç¤¢¤ê¡¢1 ¤«¤é 31 ¤Ç¤¹¡£
|
||
.It Ar hh
|
||
»þ´Ö¤Ç¤¢¤ê¡¢0 ¤«¤é 23 ¤Ç¤¹¡£
|
||
.It Ar mm
|
||
ʬ¤Ç¤¢¤ê¡¢0 ¤«¤é 59 ¤Ç¤¹¡£
|
||
.It Ar SS
|
||
ÉäǤ¢¤ê¡¢0 ¤«¤é 61 ¤Ç¤¹¡£
|
||
.El
|
||
.Pp
|
||
.Ar CC
|
||
¤È
|
||
.Ar YY
|
||
¤Îʸ»ú¤ÎÁȤ¬»ØÄꤵ¤ì¤Ê¤¤¾ì¹ç¡¢Ãͤϸ½ºß¤Îǯ¤Ë¤Ê¤ê¤Þ¤¹¡£
|
||
.Ar SS
|
||
ʸ»ú¤ÎÁȤ¬»ØÄꤵ¤ì¤Ê¤¤¾ì¹ç¡¢ÃÍ¤Ï 0 ¤Ë¤Ê¤ê¤Þ¤¹¡£
|
||
.It Fl f Ar file
|
||
»ØÄꤷ¤¿¥Õ¥¡¥¤¥ë¤«¤é¥í¥°¥¤¥ó¾ðÊó¥Õ¥¡¥¤¥ë¤òÆɤ߹þ¤ß¤Þ¤¹¡£
|
||
¥Ç¥Õ¥©¥ë¥È
|
||
¤Ç¤Ï¡¢
|
||
.Pa /var/log/wtmp
|
||
¤òÆɤ߹þ¤ß¤Þ¤¹¡£
|
||
.It Fl h Ar host
|
||
.Ar host
|
||
¤Ï¡¢¥Û¥¹¥È̾¤«¥¤¥ó¥¿¡¼¥Í¥Ã¥È¥¢¥É¥ì¥¹¤ò»ØÄꤷ¤Þ¤¹¡£
|
||
.It Fl n Ar maxrec
|
||
ɽ¼¨¤¹¤ë¥»¥Ã¥·¥ç¥ó¾ðÊó¤ò¡¢
|
||
.Ar maxrec
|
||
¹Ô
|
||
°ÊÆâ¤ËÀ©¸Â¤·¤Þ¤¹¡£
|
||
.It Fl s
|
||
¥í¥°¥¤¥ó¥»¥Ã¥·¥ç¥ó¤ÎŤµ¤ò¡¢¥Ç¥Õ¥©¥ë¥È¤ÎÆü¿ô¡¦»þ´Ö¿ô¡¦Ê¬¿ô¤Ç¤Ï¤Ê¤¯¡¢
|
||
Éÿô¤Ç¥ì¥Ý¡¼¥È¤·¤Þ¤¹¡£
|
||
.It Fl t Ar tty
|
||
.Ar tty
|
||
¤ò»ØÄꤷ¤Þ¤¹¡£
|
||
.Ar tty
|
||
¤Ë¤Ï¡¢´°Á´¤Ê
|
||
üËö̾¤«¡¢tty ¤ò¾Êά¤·¤¿Ì¾Á°¤ò»È¤¦¤³¤È¤¬¤Ç¤¤Þ¤¹¡£¤¿¤È¤¨¤Ð¡¢
|
||
.Dq Li "last -t 03"
|
||
¤Ï¡¢
|
||
.Dq Li "last -t tty03"
|
||
¤ÈƱ¤¸¤Ç¤¹¡£
|
||
.It Fl w
|
||
¥í¥°¥¤¥ó¥»¥Ã¥·¥ç¥ó¤Î¥Õ¥£¡¼¥ë¥ÉÉý¤ò¹¤²¡¢
|
||
¥Ç¥Õ¥©¥ë¥È¤ÎÆü¿ô¡¦»þ´Ö¿ô¡¦Ê¬¿ô¤Î¤ß¤Ç¤Ï¤Ê¤¯¡¢Éÿô¤â¥ì¥Ý¡¼¥È¤·¤Þ¤¹¡£
|
||
.It Fl y
|
||
¥»¥Ã¥·¥ç¥ó³«»Ï»þ¹ï¤Ëǯ¤â¥ì¥Ý¡¼¥È¤·¤Þ¤¹¡£
|
||
.El
|
||
.Pp
|
||
Ê£¿ô¤Î°ú¿ô¤¬Í¿¤¨¤é¤ì¡¢¥¹¥Ê¥Ã¥×¥·¥ç¥Ã¥È¤ÎÆü»þ¤¬»ØÄꤵ¤ì¤Ê¤¤¤È¡¢
|
||
.Nm
|
||
¤Ï¤½¤ì¤é¤Î°ú¿ô¤Î¤¤¤º¤ì¤«¤òËþ¤¹¤ë¤¹¤Ù¤Æ¤Î
|
||
¥»¥Ã¥·¥ç¥ó¾ðÊó¤òɽ¼¨¤·¤è¤¦¤È¤·¤Þ¤¹¡£¤¹¤Ê¤ï¤Á¡¢
|
||
.Dq Li "last root -t console"
|
||
¤È¤¹¤ë¤È¡¢
|
||
.Dq Li root
|
||
¤Î¹Ô¤Ã¤¿¥»¥Ã¥·¥ç¥ó¤Î¤¹¤Ù¤Æ¤È¡¢Ã¼Ëö console ¾å¤Ç¤Î
|
||
¥»¥Ã¥·¥ç¥ó¤Î¤¹¤Ù¤Æ¤òɽ¼¨¤·¤Þ¤¹¡£¤â¤·¡¢
|
||
.Ar user
|
||
¤â
|
||
.Ar host
|
||
¤â
|
||
.Ar tty
|
||
¤â
|
||
»ØÄꤵ¤ì¤Ê¤±¤ì¤Ð¡¢
|
||
.Nm
|
||
¤Ï¤¹¤Ù¤Æ¤Î¥í¥°¥¤¥ó¡¢¥í¥°¥¢¥¦¥È¾ðÊó¤òɽ¼¨
|
||
¤·¤Þ¤¹¡£
|
||
.Pp
|
||
¥·¥¹¥Æ¥à¤ò¥ê¥Ö¡¼¥È¤¹¤ë¤È¡¢¤½¤Î¾ðÊó¤Ï²¾Áۥ桼¥¶¤Ç¤¢¤ë
|
||
.Ar reboot
|
||
¤Î¥»¥Ã¥·¥ç¥ó¤È¤·¤ÆµÏ¿¤µ¤ì¤Þ¤¹¡£¤·¤¿¤¬¤Ã¤Æ¡¢
|
||
.Dq Li last reboot
|
||
¤È¤¹¤ë¤È¡¢¥·¥¹¥Æ¥à¤Î¥ê¥Ö¡¼¥È
|
||
´Ö³Ö¤òÃΤ뤳¤È¤¬¤Ç¤¤Þ¤¹¡£
|
||
.Pp
|
||
³ä¤ê¹þ¤ß¤¬µ¯¤³¤ë¤È¡¢
|
||
.Pa wtmp
|
||
¤ÎµÏ¿³«»ÏÆü»þ¤òɽ¼¨¤·¤Þ¤¹¡£QUIT ¥·¥°¥Ê¥ë¤Ë¤è¤Ã¤Æ³ä¤ê¹þ¤ß¤¬¹Ô¤ï¤ì¤¿¾ì¹ç¡¢
|
||
.Nm
|
||
¤Ï
|
||
¸¡º÷¤ò³«»Ï¤·¤Æ¤«¤é¥·¥°¥Ê¥ë¤ò¼õ¤±¤ë¤Þ¤Ç¤Ë¸¡º÷¤·¤¿ÆüÉÕ¤òɽ¼¨¤·¡¢¼Â¹Ô¤ò³¤±¤Þ¤¹¡£
|
||
.Sh ´ØÏ¢¥Õ¥¡¥¤¥ë
|
||
.Bl -tag -width /var/log/wtmp -compact
|
||
.It Pa /var/log/wtmp
|
||
¥í¥°¥¤¥ó¾ðÊó¥Ç¡¼¥¿¥Ù¡¼¥¹
|
||
.El
|
||
.Sh ´ØÏ¢¹àÌÜ
|
||
.Xr lastcomm 1 ,
|
||
.Xr utmp 5 ,
|
||
.Xr ac 8
|
||
.Sh ¥Ð¥°
|
||
¥í¥°¥¤¥ó¥·¥§¥ë¤¬²¿¤é¤«¤ÎÍýͳ¤Ç°Û¾ï½ªÎ»¤·¤¿¾ì¹ç¡¢¥í¥°¥¢¥¦¥È¤ÎµÏ¿¤¬
|
||
.Pa wtmp
|
||
¥Õ¥¡¥¤¥ë¤ËµÏ¿¤µ¤ì¤Ê¤¤¾ì¹ç¤¬¤¢¤ê¤Þ¤¹¡£¤³¤ÎÍͤʾì¹ç¡¢
|
||
.Nm
|
||
¤Ï¡¢
|
||
¥í¥°¥¢¥¦¥È¤Î»þ¹ï¤ò "shutdown" ¤Èɽ¼¨¤·¤Þ¤¹¡£
|
||
.Sh Îò»Ë
|
||
.Nm
|
||
¥æ¡¼¥Æ¥£¥ê¥Æ¥£¤Ï
|
||
.Bx 3.0
|
||
¤«¤éÅо줷¤Þ¤·¤¿¡£
|