1 .\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.35.
2 .TH TAIL "1" "March 2007" "GNU coreutils 6.9" "User Commands"
4 tail \- output the last part of files
7 [\fIOPTION\fR]... [\fIFILE\fR]...
9 .\" Add any additional description here
11 Print the last 10 lines of each FILE to standard output.
12 With more than one FILE, precede each with a header giving the file name.
13 With no FILE, or when FILE is \-, read standard input.
15 Mandatory arguments to long options are mandatory for short options too.
18 keep trying to open a file even if it is
19 inaccessible when tail starts or if it becomes
20 inaccessible later; useful when following by name,
21 i.e., with \fB\-\-follow\fR=\fIname\fR
23 \fB\-c\fR, \fB\-\-bytes\fR=\fIN\fR
24 output the last N bytes; alternatively, use +N to
25 output bytes starting with the Nth of each file
27 \fB\-f\fR, \fB\-\-follow[=\fR{name|descriptor}]
28 output appended data as the file grows;
29 \fB\-f\fR, \fB\-\-follow\fR, and \fB\-\-follow\fR=\fIdescriptor\fR are
33 same as \fB\-\-follow\fR=\fIname\fR \fB\-\-retry\fR
35 \fB\-n\fR, \fB\-\-lines\fR=\fIN\fR
36 output the last N lines, instead of the last 10;
37 or use +N to output lines starting with the Nth
39 \fB\-\-max\-unchanged\-stats\fR=\fIN\fR
40 with \fB\-\-follow\fR=\fIname\fR, reopen a FILE which has not
41 changed size after N (default 5) iterations
42 to see if it has been unlinked or renamed
43 (this is the usual case of rotated log files)
45 \fB\-\-pid\fR=\fIPID\fR
46 with \fB\-f\fR, terminate after process ID, PID dies
48 \fB\-q\fR, \fB\-\-quiet\fR, \fB\-\-silent\fR
49 never output headers giving file names
51 \fB\-s\fR, \fB\-\-sleep\-interval\fR=\fIS\fR
52 with \fB\-f\fR, sleep for approximately S seconds
53 (default 1.0) between iterations.
55 \fB\-v\fR, \fB\-\-verbose\fR
56 always output headers giving file names
59 display this help and exit
62 output version information and exit
64 If the first character of N (the number of bytes or lines) is a `+',
65 print beginning with the Nth item from the start of each file, otherwise,
66 print the last N items in the file. N may have a multiplier suffix:
67 b 512, k 1024, m 1024*1024.
69 With \fB\-\-follow\fR (\fB\-f\fR), tail defaults to following the file descriptor, which
70 means that even if a tail'ed file is renamed, tail will continue to track
71 its end. This default behavior is not desirable when you really want to
72 track the actual name of the file, not the file descriptor (e.g., log
73 rotation). Use \fB\-\-follow\fR=\fIname\fR in that case. That causes tail to track the
74 named file by reopening it periodically to see if it has been removed and
75 recreated by some other program.
77 Written by Paul Rubin, David MacKenzie, Ian Lance Taylor, and Jim Meyering.
79 Report bugs to <bug\-coreutils@gnu.org>.
81 Copyright \(co 2007 Free Software Foundation, Inc.
83 This is free software. You may redistribute copies of it under the terms of
84 the GNU General Public License <http://www.gnu.org/licenses/gpl.html>.
85 There is NO WARRANTY, to the extent permitted by law.
87 The full documentation for
89 is maintained as a Texinfo manual. If the
93 programs are properly installed at your site, the command
97 should give you access to the complete manual.