1Z0-821 practice question 12 of 30

You wish to troubleshoot some issues that you are having on the system. You want to monitor the /var/adm/messages file in real time. Which command would you use to do this?

Full set: 243 questions
Answer options
A: head
B: tail Correct answer
C: cat
D: file
E: test
Correct Answer:
B. tail
Explanation

tail is a program on Unix and Unix-like systems used to display the last few lines of a text file or piped data. By default, tail will print the last 10 lines of its input to the standard output. With command line options the number of lines printed and the printing units (lines, blocks or bytes) may be changed. The following example shows the last 20 lines of filename: tail -n 20 filename

Scroll to Top