Bird
0
0

You want to optimize Kafka disk I/O for a high-throughput system. Which combination of settings is best to improve write performance without increasing disk usage too much?

hard📝 Application Q15 of 15
Kafka - Performance Tuning
You want to optimize Kafka disk I/O for a high-throughput system. Which combination of settings is best to improve write performance without increasing disk usage too much?
ADecrease <code>num.io.threads</code>, set very large <code>log.segment.bytes</code>, and disable flushing
BIncrease <code>num.io.threads</code>, set moderate <code>log.segment.bytes</code>, and tune <code>log.flush.interval.messages</code>
CSet <code>num.io.threads</code> to 1, use small <code>log.segment.bytes</code>, and flush after every message
DIgnore <code>num.io.threads</code>, set <code>log.segment.bytes</code> to default, and increase retention time
Step-by-Step Solution
Solution:
  1. Step 1: Understand the impact of num.io.threads and segment size

    Increasing num.io.threads allows more parallel disk operations. Moderate segment size balances write efficiency and disk usage.
  2. Step 2: Consider flushing settings

    Tuning log.flush.interval.messages controls how often data is flushed to disk, improving performance without excessive disk writes.
  3. Step 3: Evaluate other options

    Decreasing threads or disabling flushing harms performance or data safety. Small segments and frequent flushes increase disk I/O. Ignoring threads or retention does not optimize writes.
  4. Final Answer:

    Increase num.io.threads, set moderate log.segment.bytes, and tune log.flush.interval.messages -> Option B
  5. Quick Check:

    Balanced threads, segment size, and flush tuning optimize disk I/O [OK]
Quick Trick: Balance threads, segment size, and flush interval for best write speed [OK]
Common Mistakes:
  • Setting too large segments causing disk bloat
  • Disabling flushing risking data loss
  • Using too few I/O threads limiting throughput

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Kafka Quizzes