Microsoft Virtualization Discussions

Perf Counters with Get-NaPerfData

aschneider146
3,253 Views

I am trying to figure out the math to get iSCSI latency.  I have the following code to get the raw data but I am trying to figure out the relationship between counters and base-counters

$counters =  (Get-NaPerfData iscsi).counters

$counters has values for iscsi_latency (units = ms) and iscsi_ops (units = ops per second) . Also, I have found that iscsi_ops is the "base counter." What post processing math do I need to get iscsi latency in ms?

Thanks,

Andy

2 REPLIES 2

aschneider146
3,253 Views

I think I just answered my own question. It looks like the raw numbers do not correspond to the units (aka ops/sec or ms) All i need to do is divide the latency counter by its base counter. This seems to line up with the data we are getting from "My Auto Support."

If I am missing something, please do let me know.

Thanks,

Andy

cknight
3,253 Views

Hi, Andy.  Yes, that looks correct for an averaging metric such as latency.  To measure latency over a specific interval, you can get the values at the start and end of the interval and then use:

average = (counter_t2 - counter_t1) / (base_t2 - base_t1)

Public