Question 1
Choose 1
A Linux systems administrator is running an important maintenance task that consumes a large amount of
CPU, causing other applications to slow. Which of the following actions should the administrator take to help
alleviate the issue?
Correct answer:
B. Lower the priority of the maintenance task with renice.
Explanation:
The renice command allows an administrator to alter the scheduling priority of an already running process.
The Concept of "Niceness": In Linux, process priority is represented by a "nice" value, ranging from -20 (highest priority) to 19 (lowest priority).
Alleviating CPU Contention: By increasing the nice value of the CPU-heavy maintenance task (e.g., changing it from 0 to 10), the administrator tells the kernel's scheduler to give that task less CPU time when other processes need it.
Impact on Other Apps: This effectively "lowers the priority" of the maintenance task, allowing the other applications to receive the CPU cycles they need to remain responsive.
Explanation of Incorrect Answers
Increase the available CPU time with pidstat:
pidstat is a monitoring tool used to report statistics for Linux tasks (CPU, memory, I/O).
It is used for observation and diagnosis, not for modifying process behavior or increasing CPU allocation.
Run the maintenance task with nohup:
nohup (no hangup) is used to run a command so that it continues running even after the user logs out.
It does not affect CPU usage or process priority; its only purpose is to ignore the SIGHUP signal.
Execute the other applications with the bg utility:
The bg (background) utility is used to resume a suspended job in the background.
Moving a process to the background does not change its priority or CPU consumption; it simply frees up the terminal's foreground for other commands.
Reference
CompTIA Exam Objective: Domain 1.0 (System Management) – Subsection 1.1: "Summarize and utilize Linux command line tools" and Domain 5.0 (Troubleshooting) – Subsection 5.1: "Analyze and troubleshoot system-level issues" (specifically Process Management).
Reference: Linux Man Pages (man renice, man nice); Official CompTIA Linux+ Study Guide, Chapter on Process and Resource Management.
The renice command allows an administrator to alter the scheduling priority of an already running process.
The Concept of "Niceness": In Linux, process priority is represented by a "nice" value, ranging from -20 (highest priority) to 19 (lowest priority).
Alleviating CPU Contention: By increasing the nice value of the CPU-heavy maintenance task (e.g., changing it from 0 to 10), the administrator tells the kernel's scheduler to give that task less CPU time when other processes need it.
Impact on Other Apps: This effectively "lowers the priority" of the maintenance task, allowing the other applications to receive the CPU cycles they need to remain responsive.
Explanation of Incorrect Answers
Increase the available CPU time with pidstat:
pidstat is a monitoring tool used to report statistics for Linux tasks (CPU, memory, I/O).
It is used for observation and diagnosis, not for modifying process behavior or increasing CPU allocation.
Run the maintenance task with nohup:
nohup (no hangup) is used to run a command so that it continues running even after the user logs out.
It does not affect CPU usage or process priority; its only purpose is to ignore the SIGHUP signal.
Execute the other applications with the bg utility:
The bg (background) utility is used to resume a suspended job in the background.
Moving a process to the background does not change its priority or CPU consumption; it simply frees up the terminal's foreground for other commands.
Reference
CompTIA Exam Objective: Domain 1.0 (System Management) – Subsection 1.1: "Summarize and utilize Linux command line tools" and Domain 5.0 (Troubleshooting) – Subsection 5.1: "Analyze and troubleshoot system-level issues" (specifically Process Management).
Reference: Linux Man Pages (man renice, man nice); Official CompTIA Linux+ Study Guide, Chapter on Process and Resource Management.