none
do you know behind the scene with the measure-VM? RRS feed

  • Question

  • hi, the expert of scripting..

    Do you know how "measure-VM" works?

    how does it calculate to get the result of "Average RAM" or the others? 

    let's assume, i have 1 VM with 2GB RAM in monday, then tuesday i change the RAM to 4GB RAM, Wednesday 4GB RAM, then i run the "measure-VM -VMName VMTEST" script in wednesday, the result of AvgRAM i got is 4096MB. how could it be? (assume the VM is always ON from Monday till Wednesday)

    why not like this 2GB+4GB+4GB=10GB/3= 3,3 GB ?

    Thank you

    Wednesday, November 5, 2014 9:50 AM

Answers

  • Average is really current or max for physical attributes.  You cannot have a partial amount of a physical entity.

    To change ram you need to restart which erases all physical values and reset on restart.

    This is really not a scripting question. It is about what the meaning of a technical value is and how it is associated.

    Suppose you have an adapter. Now add one. Do you have 1.5 adapters? Does that even make sense?


    ¯\_(ツ)_/¯

    Thursday, November 6, 2014 2:39 PM
    Moderator
  • Hi Weili,

    In addition, more detailed information about the average memory in the cmdlet measure-vm:

    There are four resources that you can measure: your CPU, memory, network, and storage utilization. We measure these resources over the period of time between when you measure and when you last reset metering.

    We do include the offline time of the virtual machine when calculating the average memory utilization. This provides an accurate view of how much memory the virtual machine was using over that billing cycle, so that you can charge your users accurately.

    Refer to:

    Introduction to Resource Metering

    How to Use Resource Metering With PowerShell

    If there is anything else regarding this issue, please feel free to post back.

    Best Regards,

    Anna Wang

    Monday, November 17, 2014 7:09 AM
    Moderator

All replies

  • Average is really current or max for physical attributes.  You cannot have a partial amount of a physical entity.

    To change ram you need to restart which erases all physical values and reset on restart.

    This is really not a scripting question. It is about what the meaning of a technical value is and how it is associated.

    Suppose you have an adapter. Now add one. Do you have 1.5 adapters? Does that even make sense?


    ¯\_(ツ)_/¯

    Thursday, November 6, 2014 2:39 PM
    Moderator
  • Thanks for the reply.

    i wanna know about how does it (Measure-VM) count the average of Memory Usage? i set Dynamic memory on my VM. 

    Thank You.

    Friday, November 7, 2014 1:45 AM
  • memory usage has nothing to do with installed RAM.

    ¯\_(ツ)_/¯

    Friday, November 7, 2014 1:49 AM
    Moderator
  • Hi Weili,

    In addition, more detailed information about the average memory in the cmdlet measure-vm:

    There are four resources that you can measure: your CPU, memory, network, and storage utilization. We measure these resources over the period of time between when you measure and when you last reset metering.

    We do include the offline time of the virtual machine when calculating the average memory utilization. This provides an accurate view of how much memory the virtual machine was using over that billing cycle, so that you can charge your users accurately.

    Refer to:

    Introduction to Resource Metering

    How to Use Resource Metering With PowerShell

    If there is anything else regarding this issue, please feel free to post back.

    Best Regards,

    Anna Wang

    Monday, November 17, 2014 7:09 AM
    Moderator