RedHat Red Hat Linux Essentials RH033 Question # 13 Topic 2 Discussion
RH033 Exam Topic 2 Question 13 Discussion:
Question #: 13
Topic #: 2
You want to check whether the cc process is running on a computer. Which of the following commands can you use to accomplish the task? Each correct answer represents a complete solution.
You can view all running processes with the help of the ps -aux command. Hence, any of the ps –aux commands (i.e., ps -aux | grep cc, ps -aux
| more, or ps -aux) can be used to check whether the cc process is running on the computer.
Answer option B is incorrect. The tail command is used to display the last few lines of a text file or piped data. It has a special command line option -f (follow) that allows a file to be monitored. Instead of displaying the last few lines and exiting, tail displays the lines and then monitors the file. As new lines are added to the file by another process, tail updates the display. This is particularly useful for monitoring log files. The following command will display the last 10 lines of messages and append new lines to the display as new lines are added to messages: tail -f /var/adm/messages
Contribute your Thoughts:
Chosen Answer:
This is a voting comment (?). You can switch to a simple comment. It is better to Upvote an existing comment if you don't have anything to add.
Submit