A Linux server that hosts a busy PostgreSQL instance is experiencing very slow query performance during peak traffic. You run top and observe a high I/O wait percentage (%wa) and a load average that rises well above the number of cores. A follow-up check with iostat -x 1 5 shows %util near 100% and an avgqu-sz that frequently exceeds 90 for the only block device, an enterprise-grade SSD. Without changing application code or replacing hardware, which action is most likely to lower the high I/O wait time and improve overall responsiveness?
Change the block device's I/O scheduler from CFQ to mq-deadline or none, both recommended for fast SSDs.
Increase the kernel's swappiness value so the system begins swapping sooner.
Lower the PostgreSQL shared_buffers setting to reduce memory usage.
Disable TCP segmentation and generic offloading features on the network interface.
The combination of a high I/O wait (%wa) with a high load average indicates that processes are waiting on storage, not the CPU. This is confirmed by the iostat output, where %util near 100% and a very large avgqu-sz (average queue size) show that the storage device is saturated. On older Linux systems, the default I/O scheduler was often CFQ (Completely Fair Queuing), which is optimized for spinning disks and can add unnecessary overhead on fast SSDs. Modern schedulers like mq-deadline or none are better suited for solid-state storage. They remove complex re-ordering logic, shortening the path through the kernel block layer, which can significantly reduce I/O wait time and improve responsiveness.
The other options do not target the storage bottleneck: increasing swappiness would generate more disk I/O, worsening the issue; lowering PostgreSQL's shared_buffers reduces its memory cache, forcing more disk reads; and disabling network offloading affects NIC processing, not disk latency. Therefore, changing the I/O scheduler is the most effective remediation in this scenario.
Ask Bash
Bash is our AI bot, trained to help you pass your exam. AI Generated Content may display inaccurate information, always double-check anything important.
What does changing the I/O scheduler to `mq-deadline` or `none` do for SSDs?
Open an interactive chat with Bash
What do `%util` and `avgqu-sz` in `iostat` indicate about storage performance?
Open an interactive chat with Bash
Why is CFQ less suitable for use with SSDs?
Open an interactive chat with Bash
CompTIA Linux+ XK0-006 (V8)
Troubleshooting
Your Score:
Report Issue
Bash, the Crucial Exams Chat Bot
AI Bot
Loading...
Loading...
Loading...
Pass with Confidence.
IT & Cybersecurity Package
You have hit the limits of our free tier, become a Premium Member today for unlimited access.
Military, Healthcare worker, Gov. employee or Teacher? See if you qualify for a Community Discount.
Monthly
$19.99
$19.99/mo
Billed monthly, Cancel any time.
3 Month Pass
$44.99
$14.99/mo
One time purchase of $44.99, Does not auto-renew.
MOST POPULAR
Annual Pass
$119.99
$9.99/mo
One time purchase of $119.99, Does not auto-renew.
BEST DEAL
Lifetime Pass
$189.99
One time purchase, Good for life.
What You Get
All IT & Cybersecurity Package plans include the following perks and exams .