Tail -f but Suck in Content of the File First – Cat -f Alternative

tail

I need to display whole file before tracking it for a new changes, not only the last 10 lines (yep, I know it's not tail conceptually). In other words, something like cat -f would do, if it would ever existed. Tail's man doesn't give me any ideas. The only option I see right now is to somehow combine cat all but last 10 lines and tail -f output.

Any hints, please?

Best Answer

Here's one way to do it:

tail -f -n+0 /var/log/messages

There doesn't seem to be any difference between a +0 and a +1, so this would be equivalent:

tail -f -n+1 /var/log/messages