| 1 |
.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.50.1. |
| 2 |
.TH TAIL "1" "February 2026" "GNU coreutils 9.10" "User Commands" |
| 3 |
.SH NAME |
| 4 |
tail \- output the last part of files |
| 5 |
.SH SYNOPSIS |
| 6 |
.B tail |
| 7 |
[\fI\,OPTION\/\fR]... [\fI\,FILE\/\fR]... |
| 8 |
.SH DESCRIPTION |
| 9 |
.\" Add any additional description here |
| 10 |
.PP |
| 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 |
.PP |
| 14 |
With no FILE, or when FILE is \-, read standard input. |
| 15 |
.PP |
| 16 |
Mandatory arguments to long options are mandatory for short options too. |
| 17 |
.TP |
| 18 |
\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail-c'\fB\-c, \-\-bytes=\,[+]NUM\fP\X'tty: link'\/\fR |
| 19 |
output the last NUM bytes; |
| 20 |
or use \fB\-c\fR +NUM to output starting with byte NUM of each file |
| 21 |
.TP |
| 22 |
\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail--debug'\fB\-\-debug\fP\X'tty: link' |
| 23 |
indicate which \fB\-\-follow\fR implementation is used |
| 24 |
.TP |
| 25 |
\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail-f'\fB\-f, \-\-follow[=\,{name|descriptor}]\fP\X'tty: link'\/\fR |
| 26 |
output appended data as the file grows; |
| 27 |
an absent option argument means 'descriptor' |
| 28 |
.TP |
| 29 |
\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail-F'\fB\-F\fP\X'tty: link' |
| 30 |
same as \fB\-\-follow\fR=\fI\,name\/\fR \fB\-\-retry\fR |
| 31 |
.TP |
| 32 |
\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail-n'\fB\-n, \-\-lines=\,[+]NUM\fP\X'tty: link'\/\fR |
| 33 |
output the last NUM lines, instead of the last 10; |
| 34 |
or use \fB\-n\fR +NUM to skip NUM\-1 lines at the start |
| 35 |
.TP |
| 36 |
\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail--max-unchanged-stats'\fB\-\-max\-unchanged\-stats=N\fP\X'tty: link' |
| 37 |
with \fB\-\-follow\fR=\fI\,name\/\fR, reopen a FILE which has not |
| 38 |
changed size after N (default 5) iterations |
| 39 |
to see if it has been unlinked or renamed |
| 40 |
(this is the usual case of rotated log files); |
| 41 |
with inotify, this option is rarely useful |
| 42 |
.TP |
| 43 |
\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail--pid'\fB\-\-pid=PID\fP\X'tty: link' |
| 44 |
with \fB\-f\fR, exit after PID no longer exists; |
| 45 |
can be repeated to watch multiple processes |
| 46 |
.TP |
| 47 |
\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail-q'\fB\-q, \-\-quiet, \-\-silent\fP\X'tty: link' |
| 48 |
never output headers giving file names |
| 49 |
.TP |
| 50 |
\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail--retry'\fB\-\-retry\fP\X'tty: link' |
| 51 |
keep trying to open a file if it is inaccessible |
| 52 |
.TP |
| 53 |
\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail-s'\fB\-s, \-\-sleep\-interval=\,N\fP\X'tty: link'\/\fR |
| 54 |
with \fB\-f\fR, sleep for approximately N seconds |
| 55 |
(default 1.0) between iterations; |
| 56 |
with inotify and \fB\-\-pid\fR=\fI\,P\/\fR, |
| 57 |
check process P at least once every N seconds |
| 58 |
.TP |
| 59 |
\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail-v'\fB\-v, \-\-verbose\fP\X'tty: link' |
| 60 |
always output headers giving file names |
| 61 |
.TP |
| 62 |
\X'tty: link https://www.gnu.org/software/coreutils/manual/coreutils.html#tail-z'\fB\-z, \-\-zero\-terminated\fP\X'tty: link' |
| 63 |
line delimiter is NUL, not newline |
| 64 |
.TP |
| 65 |
\X'tty: link https://www.gnu.org/software/coreutils/tail#tail--help'\fB\-\-help\fP\X'tty: link' |
| 66 |
display this help and exit |
| 67 |
.TP |
| 68 |
\X'tty: link https://www.gnu.org/software/coreutils/tail#tail--version'\fB\-\-version\fP\X'tty: link' |
| 69 |
output version information and exit |
| 70 |
.PP |
| 71 |
NUM may have a multiplier suffix: |
| 72 |
b 512, kB 1000, K 1024, MB 1000*1000, M 1024*1024, |
| 73 |
GB 1000*1000*1000, G 1024*1024*1024, and so on for T, P, E, Z, Y, R, Q. |
| 74 |
Binary prefixes can be used, too: KiB=K, MiB=M, and so on. |
| 75 |
.PP |
| 76 |
With \fB\-\-follow\fR (\fB\-f\fR), tail defaults to following the file descriptor, which |
| 77 |
means that even if a tail'ed file is renamed, tail will continue to track |
| 78 |
its end. This default behavior is not desirable when you really want to |
| 79 |
track the actual name of the file, not the file descriptor (e.g., log |
| 80 |
rotation). Use \fB\-\-follow\fR=\fI\,name\/\fR in that case. That causes tail to track the |
| 81 |
named file in a way that accommodates renaming, removal and creation. |
| 82 |
.SH AUTHOR |
| 83 |
Written by Paul Rubin, David MacKenzie, Ian Lance Taylor, |
| 84 |
and Jim Meyering. |
| 85 |
.SH "REPORTING BUGS" |
| 86 |
Report bugs to: bug\[email protected] |
| 87 |
.br |
| 88 |
GNU coreutils home page: <https://www.gnu.org/software/coreutils/> |
| 89 |
.br |
| 90 |
General help using GNU software: <https://www.gnu.org/gethelp/> |
| 91 |
.br |
| 92 |
Report any translation bugs to <https://translationproject.org/team/> |
| 93 |
.SH "SEE ALSO" |
| 94 |
\fBhead\fP(1) |
| 95 |
.PP |
| 96 |
.br |
| 97 |
Full documentation <https://www.gnu.org/software/coreutils/tail> |
| 98 |
.br |
| 99 |
or available locally via: info \(aq(coreutils) tail invocation\(aq |
| 100 |
.PP |
| 101 |
.br |
| 102 |
Packaged by Debian (9.10\-1) |
| 103 |
.br |
| 104 |
Copyright \(co 2026 Free Software Foundation, Inc. |
| 105 |
.br |
| 106 |
License GPLv3+: GNU GPL version 3 or later <https://gnu.org/licenses/gpl.html>. |
| 107 |
.br |
| 108 |
This is free software: you are free to change and redistribute it. |
| 109 |
.br |
| 110 |
There is NO WARRANTY, to the extent permitted by law. |