zhangfred_vm
Contributor
Contributor

algorithms to calculate the shares in resource management

Hi Friends,

When we set the shares parameter to control the resource allocation?

What is the resource range needed to be shared?

Supposed:

one ESX Host: 3G CPU

VM_001: reserved 1G

Limited 1.5G

shares 2000

VM_002: reserved 0.5G

Limited 1G

shares 1000

When the shares paratemter is used?

if VM_001 and VM_002 are competed to the cpu resource.

VM_001 can get the max cpu resouce : Min(1 G + (2/3) * (3G - 1.5G - 0.5G), 1.5G) = 1.5G

VM_001 can get the max cpu resouce : Min(0.5G + (1/3) * (3G - 1.5G - 0.5G), 1G) = 0.83G

Am I right

0 Kudos
2 Replies
admin
Immortal
Immortal

Hi there, check out page 20 of this doc.

http://www.vmware.com/pdf/vi3_301_201_resource_mgmt.pdf

0 Kudos
admin
Immortal
Immortal

The shares value kicks in between the reservation and the limit. So once the reservation is accounted for and there is contention for the resource the shares value is then used to divide up the remaining resources. So your example would assume that both VM's have their reservation and both want more of the resource and that there is contention for the remaining resources.

VM 1 gets it's 1 Gig processor reservation VM2 gets 512Mhz processor reservation now out of the 1.5 GHz remaining Vm1 will get 2/3 and Vm 1 will get 1/3.

0 Kudos