1

We are trying to do some time benchmarks in the Virtual Machine (VPC) e.g. how long it takes to Windows gets idle after boot.

So far we have not figured out a way how to do the benchmarks accurately because it seems the state of the hosted machine affects the performance of the Virtual Machine. e.g. some times VM boots up in 30 seconds, sometimes in 100 seconds.

Is there any way how to assign set number of resources to VM so it performs in a consistent way? (e.g. like the real machine would do)

Janusz
  • 45

2 Answers2

0

Not really. Virtual clients share the resources of the host machine. They can be configured to use less resources (ie limit to 1 CPU or the size of available memory) thru the settings properties of each virtual setup, but never more. And none to my knowledge allow you to specify a different CPU. And since they are shared, if other things are going on on the host machine, that would effect your benchmark.

jdh
  • 7,140
0

Technically, you can use the Windows task scheduler to limit all processes on your system to certain cores, or modify the virtual machine process' affinity. You could use this to assign every running task (before starting your virtual machine) to a particular CPU core, then assign the VM to another core. Obviously you have no direct control over the task scheduler, but this should make your results much more consistent.

Another way to ensure consistent results is to modify the priority of the virtual machine process itself. You can do this in conjunction with modifying the CPU core affinity, or just let the task scheduler do it's thing and just set the process affinity to High. This should prioritize the virtual machine's execution state over other non-essential system services.

If you use a hyperthreaded CPU, you may want to my answer to this related question. If you need to perform any of these actions via command line or batch file, my answer to this other question.

Breakthrough
  • 34,847