All Questions
Redis hard

Why might an administrator select the LFU (Least Frequently Used) eviction policy over the standard LRU (Least Recently Used) for a system with large periodic scans?

  1. A LFU uses a more efficient O(1) eviction logic that requires zero additional CPU overhead compared to LRU.
  2. B LFU is resistant to 'Scan Pollution'; one-time background scans won't displace frequently accessed 'hot' keys.
  3. C LFU reduces memory usage by automatically merging duplicate string keys into a single shared buffer segment.
  4. D LRU has been deprecated in Redis 6.0 and replaced by a more robust epoch-based frequency counter.

One system design question a day, with spaced repetition so the ones you miss come back.

Get the app

Related questions