How to see the auth.log messages in the terminal?
6,511
You can do what @mikewhatever is telling You. Now, with your next question, and how You can keep using your terminal, what You can do is send the actual process to the background. These are the steps to do it:
tail -F /var/log/auth.log
- Ctrl+z
bg 1
Shazam!!! You can keep using your terminal and You will see the output when a new line is coming into the file.
Related videos on Youtube
Author by
Olivia
Updated on December 03, 2022Comments
-
Olivia over 1 year
I would like to find a way to display the information saved in the auth.log file in real time in my terminal (everytime someone tries to connect to my server, I want it to appear in my terminal) without having to open the file manually.
Thank you !!
Olivia
-
Admin almost 7 yearsHow about
tail -F /var/log/auth.log
? -
Admin almost 7 yearsThank you, this is a first really nice step but still not exactly what I would like, because then I cannot write command lines anymore when I use tail. I would like to be able to continue working on my terminal and that the log messages appear automaticaly in the same terminal when a new line is added to the log file (a permanent rule)
-
Admin over 4 yearsWhy not open another terminal window just for the monitor?
-
-
Admin almost 2 yearsNice! Another way you could do this is "tail -F /var/log/auth.log &", that does it all in one line.
-
Admin almost 2 yearsThat's right! Thanks for coming into the party ( BTW nice editing )