Linux command: tail


I had come a cross a question from a class I'm currently taking. I know, I shouldn't seek help and figure it out by myself; but I gave up on it after looking all over the class book as well as internet. The question reads as this:

"In /var/log/, there should be a file that records every email message sent. Using the tail command and the appropriate switch (which you may have to find by using the man command) display the last 11 lines of that file to the screen. Paste the command and output here."

What I've done so far:

cd /var/log
tail -11 messages

But it says you may have to use man command to find appropriate switch. How would I do that? Could you please help me?
Thank you.

Best Answer

If you'd like to see the man(manual) page for a particular command(i.e. tail)

man tail

press 'q' to exit man pages.


tail --help
tail --help | less

press 'q' to exit

Related Question