[libvirt-users] regard limiting network bandwidth
Michal Privoznik
mprivozn at redhat.com
Thu Nov 19 10:27:34 UTC 2015
On 03.11.2015 13:21, asw Anose wrote:
> hi all
> i am a kvm , qemu user newbie , i am using libvirt and virsh to mange my KVM VMs , i want to limit the network bandwidth of each VM , i come across libvirt xml format option :
> <forward mode='nat' dev='eth0'/>
> <bandwidth>
> <inbound average='1000' peak='5000' burst='5120'/>
> <outbound average='128' peak='256' burst='256'/>
> </bandwidth>to limit the bandwidth of each vm , however i have a question how does these option applied limit on kvm vm ? through using of linux cgroub or its a qemu network bandwidth limit functionality ?
>
>
This is currently implemented per nic calling set of 'tc' commands to
construct some structure that in the end limits the traffic through nic
as requested. If you want to get your hands dirty you may look over this:
http://libvirt.org/git/?p=libvirt.git;a=blob;f=src/util/virnetdevbandwidth.c;h=da3a0d327ea21879e2da5f10701015f38eec0297;hb=HEAD#l149
Michal
More information about the libvirt-users
mailing list