apache / apache/cloudstack

Allow limiting IO operation size (KVM)

Aperta
#8,384 2 commenti 1 reazione 0 assegnatari Vedi su GitHub
component:primary-storage component:storage type:new-feature
Lingua principale
Java
Stelle
3.1k
Fork
1.4k
Merge medio
6g 19h
PR unite (30g)
32

Descrizione

##### ISSUE TYPE

* Improvement Request

##### COMPONENT NAME

~~~
KVM hypervisor
~~~

##### CLOUDSTACK VERSION

~~~
4.18 or latest
~~~

##### SUMMARY

The [qemu documentation](https://github.com/qemu/qemu/blob/master/docs/throttle.txt#L142) explains why this is important:

> When applying IOPS limits all I/O operations are treated equally
regardless of their size. This means that the user can take advantage
of this in order to circumvent the limits and submit one huge I/O
request instead of several smaller ones.
>
> QEMU provides a setting called throttling.iops-size to prevent this
from happening. This setting specifies the size (in bytes) of an I/O
request for accounting purposes. Larger requests will be counted
proportionally to this size.

In libvirt this option is called `size_iops_sec` inside the `` section ([ref](https://libvirt.org/formatdomain.html)).

Other big clouds such as AWS also use this mechanism to fairly allocate IOPS.

##### STEPS TO REPRODUCE

Checking the CloudStack code shows that this option is currently not supported:
https://github.com/apache/cloudstack/blob/1411da1a22bc6aa26634f3038475e3d5fbbcd6bb/plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/resource/LibvirtVMDef.java#L1173-L1207

Guida per i contributori

Apri la guida per i contributori

Direzione di ricerca

Iniziare da plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/resource/LibvirtVMDef.java intorno alle righe 1173-1207, dove l'issue indica che sono definite le opzioni KVM IO. Leggere la documentazione collegata sul throttling di QEMU e il riferimento di libvirt a size_iops_sec, quindi rendere l'opzione disponibile per la configurazione KVM di CloudStack e verificare che l'impostazione generata utilizzi la dimensione IO richiesta per la contabilizzazione.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
java
Ambito
cloud, infrastructure
Tipo di issue
Funzionalità
Difficoltà
3/5
Tempo stimato
1-2 giorni
Stato di attività
Tranquilla
Chiarezza
Abbastanza chiara
Idoneità per principianti
62/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.