libkrun v1.17.5 - vsock Queue Overflow Fixes
🎉 libkrun v1.17.5
vsock Queue Overflow Fixes
This release resolves critical vsock queue overflow issues that caused network stalls under heavy load.
Key Fixes
vsock Queue Management:
- Fix queue overflow when container applications perform heavy network communication
- Implement backpressure mechanism with
rx_ready_fdsignaling - Add
paused_proxiesqueue to prevent CPU busy-loops - Fix CreditUpdate logic to only update on successful packet push
Flow Control:
- Prevent flow control deadlocks in credit-based flow control
- Add proper signaling when RX queue space becomes available
- Implement level-triggered epoll handling to avoid busy-loops
Code Quality:
- Add missing
AsRawFdimports in balloon and rng event handlers - Add detailed error logging for queue overflow scenarios
Verification
- ✅ nginx container test: 10/10 requests successful
- ✅ No queue overflow errors under load
- ✅ Stable network communication
- ✅ Proper backpressure handling
Files Changed
src/devices/src/virtio/vsock/muxer.rssrc/devices/src/virtio/vsock/muxer_thread.rssrc/devices/src/virtio/vsock/event_handler.rssrc/devices/src/virtio/vsock/tsi_stream.rssrc/devices/src/virtio/vsock/unix.rssrc/devices/src/virtio/vsock/proxy.rssrc/devices/src/virtio/balloon/event_handler.rssrc/devices/src/virtio/rng/event_handler.rs
Upgrade Notes
This is a recommended upgrade for all users experiencing network stalls or high CPU usage in vsock communication.