VMware vSphere

 View Only
Expand all | Collapse all

How to test DRS

  • 1.  How to test DRS

    Posted Apr 14, 2007 10:11 AM

    I have 2 ESX host share a SAN, each has 32G memory and 4 dual core CPU.

    i want to design a demo for customer, but since i have so many CPU resource, i'm afraid the VM will not migrate to another ESX even i run cpubusy script in the VM, is there any simple method to test DRS?



  • 2.  RE: How to test DRS

    Posted Apr 14, 2007 10:30 AM

    hello,

    use the cpubusy script, it will work, you just need to assure that you unbalance the workload.

    Like starting cpubusy process in 2-4 VMs in the same host and you will see it work just fine.

    The main goal of DRS is distribute the workload, does not count with resource available but in workload differences between different hosts

    Cheers



  • 3.  RE: How to test DRS

    Posted Apr 14, 2007 11:36 AM

    There's also a free app called 'heavyload' you can put load on things like ram, cpu and disk - i found this useful when i first set up our ESX environment and wanted to test host stability and DRS.



  • 4.  RE: How to test DRS

    Posted Apr 16, 2007 10:33 AM

    HeavyLoad is free by Jamsoftware..

    http://www.jam-software.com/freeware/index.shtml

    and the cpubusy scriipt (copy into cpubusy.vbs)

    Dim goal

    Dim before

    Dim x

    Dim y

    Dim i

    goal = 2181818

    Do While True

    before = Timer

    For i = 0 to goal

    x = 0.000001

    y = sin(x)

    y = y + 0.00001

    Next

    y = y + 0.01

    Loop



  • 5.  RE: How to test DRS

    Posted May 07, 2007 08:07 PM

    I tried the cpubusy.vbs script above and it does force DRS to migrate the virtual machines off the host. But, if I put one of the two hosts in my DRS/HA cluster into maintenance mode (to force off all VMs) and then exit maintenance mode DRS does not balance out the VMs. There are 16 VMs, and each is configured with a limit of 1000 MHz. Each host has four processors with dual core and ESX Server 3.0.1. VirtualCenter is version 2.0.1.

    Why isn't DRS balancing out the VMs?



  • 6.  RE: How to test DRS

    Posted May 07, 2007 08:49 PM

    Some tips for triggering DRS...

    1. Set to aggressive...

    2. On one ESX host within one VM run the cpubusy script

    3. VMotion all your VMs to one host

    4. Wait. DRS is inheritently conservative and only checks every 5mins - it performs a very sophisticated check to see if it is even worth bothering with a VMotion, lastly it only does 60 VMotions per hour...

    In away what want is as few VMotion events as possible, this is a sign that there ESX hosts are balanced. Remember DRS is not about evenly distributing VMs, but load. It's quite possible to have 10 VMs on host and 5 on another - as the 10 VMs are doing the same workload as 5 VMs...

    Lastly, another way of generating lots of CPU activity is with one of MS most CPU intensive applications - Microsoft Calculator. Try scientific view, type 9999999 and hit the n! button... It's calculates a factorial of 999999 which takes a very long time...

    Regards

    Mike



  • 7.  RE: How to test DRS

    Posted May 07, 2007 10:00 PM

    DRS is already set to aggressive.

    I already tried what you suggested (see previous post). I was expecting DRS to distribute the VMs somewhat evenly across the two ESX hosts as all VMs were set to 1000 MHz and were running cpubusy.vbs. Even after waiting two days DRS did not move any VMs.

    If the polling cycle is 5 minutes, how many polling cycles before DRS migrates a VM?

    What I am trying to do is verify that DRS is working the way I think it should. Either DRS is not working correctly or there is some gap in my knowledge. You information on how DRS behaves should prove helpfull. BTW, these are new servers with only test VMs.



  • 8.  RE: How to test DRS

    Posted May 07, 2007 10:27 PM

    I would add more load. 16 VMs limited to 1000Mhz is not much for a brand new 4 CPU dual core.

    Perhaps take out the limit.



  • 9.  RE: How to test DRS

    Posted May 07, 2007 10:57 PM

    Hello,

    I have a 7 server DRS/HA cluster with the following specs:

    4 x dual core CPU, 32 GB RAM

    We currently run at about 10% avg CPU utilization and 20-30% avg memory usage with 120 or so virtual machines ( sized for about 500 low use virtual machines ). We are by no means stressing these boxes and no machine has requested a resource and not gotten it. To date we have had over 100 vm migrations. I guess the point is that you don't necessarily need more load to create a situation where DRS will migrate machines around. In my experience it looks like DRS will try to keep things balanced as well across all ESX servers as all my hosts have almost identical CPU load and memory usage.



  • 10.  RE: How to test DRS

    Posted May 08, 2007 11:47 AM

    The VMs were originally set to no CPU speed limit and the result was the same.

    It seems that the only time DRS actually does anything is when I go poking and proding the VMs some how, such as changing CPU speed or restarting VM.

    I checked again this morning. All VMs are still on one host.



  • 11.  RE: How to test DRS

    Posted Apr 16, 2007 09:48 PM

    You should set the DRS settings at the most aggressive level and run the busy script in multiple vm's.

    You can also put one server into maintenance mode. The guests should start migrating if you have the cd-roms/floppies disconnected and the DRS settings at automatic. Another point to show the value of vmware for doing hardware or patch maintenance on your hosts.