TAIL(1)

NAME
tail - deliver the last part of a file

SYNOPSIS
tail [+/-[number][lbc][f]] [file]
tail [+/-[number][l][r]] [file]
tail [-f] [-c number|-n number] [file]

DESCRIPTION
The tail command copies the named file to the standard output beginning at a designated place. If no file is named, the standard input is used.

Copying begins at distance +number from the beginning, or -number from the end of the input. Number is counted in units of lines, blocks or characters (i.e. bytes), according to the appended option l, b or c. When no units are specified, counting is by lines; the default number is 10.

If the f (``follow'') option is present, tail will not terminate at end-of-file, but check for further data to write every second.

With the r option, the order of lines printed is reversed. If no number is specified, the entire file is printed. Number is always taken as count of lines from the end of input.

The tail command also accepts the following options that were introduced by POSIX.2, in the form shown in the third synopsis line:

-c [+|-]number
    Copying will start at number bytes; if the option argument starts with a `+', from the begin of the file, with `-' or no sign from its end.

-f  Follow file changes, as described above.

-n [+|-]number
    Copying will start at number lines. The meaning of the sign is the same as for the -c option.

SEE ALSO
dd(1), head(1)

NOTES
Tails relative to the end of the file are treasured up in a buffer, and thus are limited in length. Various kinds of anomalous behaviour may happen with character special files.