Summary
OpenStack cung cấp hai cơ chế kiểm soát disk I/O hoàn toàn tách biệt: Cinder QoS specs (cho volumes, đầy đủ token bucket với burst) và Nova flavor extra specs (cho ephemeral disk, chỉ có sustained rate). Cả hai đều cuối cùng enforce qua libvirt <iotune> XML trên compute host — nhưng chỉ Cinder QoS mới expose burst params mà QEMU hỗ trợ. Consumer front-end là lựa chọn an toàn nhất vì hoạt động với mọi storage backend bất kể driver.
Key Ideas
- Token bucket trong Cinder QoS:
total_iops_sec= refill rate (sustained),total_iops_sec_max= peak drain rate (burst ceiling),size_iops_sec= bucket capacity (số I/O ops). Burst duration ≈size_iops_sec / (max - sustained) consumer=front-endenforce tại QEMU layer — Nova đọc QoS spec từ volumeconnection_infokhi attach và inject vào libvirt domain XML. Không cần restart VM, apply ngay khi hot-attachconsumer=back-endpass spec tới Cinder driver — Nova bỏ qua hoàn toàn. Chỉ dùng nếu storage array hỗ trợ và driver implement QoS API riêng- Ephemeral disk QoS giới hạn: 6 flavor keys (
quota:disk_[read|write|total]_[bytes|iops]_sec), không có burst. Nova docs ghi rõ “poorly tested and poorly maintained”. Burst params tồn tại ở libvirt/QEMU nhưng không được expose qua Nova flavor - Capacity-based QoS:
total_iops_sec_per_gbscale theo volume size, kết hợp vớitotal_iops_sec_maxđể tạo floor/ceiling policy - Mutual exclusion: không dùng
total_*cùng vớiread_*/write_*cho cùng metric trong một spec - Verify:
virsh dumpxml <instance> | grep -A 15 "<iotune>"— xem trực tiếp params đã được inject
Quotes
“Front-end QoS settings are only supported when using the libvirt driver” — Nova Rocky release notes
Nova docs về ephemeral disk QoS: “poorly tested and poorly maintained”
Rocky blueprint: “No QoS specs are provided for local drives provided directly by Nova” — burst params chỉ cho Cinder volumes
My Take
(Chưa có — đang trong giai đoạn tìm hiểu, chưa deploy thực tế)