Linux Foundation Certified System Administrator (LFCS) — Question 74
Which of the following commands kills the process with the PID 123 but allows the process to "clean up" before exiting?
Answer options
- A. kill -PIPE 123
- B. kill -KILL 123
- C. kill -STOP 123
- D. kill -TERM 123
Correct answer: D
Explanation
The correct answer is D, as the 'kill -TERM' command sends a termination signal that allows the process to handle cleanup before exiting. In contrast, 'kill -KILL' (B) forcefully stops the process without giving it a chance to clean up, 'kill -STOP' (C) pauses the process, and 'kill -PIPE' (A) sends a signal that may not necessarily lead to termination.