DEV Community

Discussion on: The linux commands that help me work

dwilmer profile image
Daan Wilmer
tail -n 20 error.log

to get the last 20 lines of the error log is perhaps the most used command on my machine.

skorotkiewicz profile image
Sebastian Korotkiewicz Author • Edited on

You're right, I forgot tail! I use tail -f file.log to live track of my logs.

Ideal for live viewing of web server logs.

tail -f /var/log/nginx/korotkiewicz-access.log