Hi All, I am trying to get the volume avg_latency, And the statistics I got from the command "statistics volume show " has a big different to the following API return: "/cluster/counter/tables/{counter_table.name}/rows/{id}". I am wondering are they the same function since they both return volume performance data, but totally different value.
#Volume average latency error (cluster/counter/tables/{counter_table.name}/rows/{id})
1 messages · Page 1 of 1 (latest)
Values returned from /cluster/counter/tables/{counter_table.name}/rows/{id} are not a cooked data. avg_latency has a base counter total_ops . It can be calculated as delta(avg_latency)/ delta(total_ops) where delta represents the difference between these counters between two consecutive REST calls. Harvest(https://github.com/NetApp/harvest) does it for you with its RestPerf Collector.
@dark lotus So is the data from the command "statistics volume show" also non-cooked data?
I have the harvest with query "avg_latency", but it was also no matched to the value I got from the command.
statistics volume show is a cooked data. I suggest comparing read_latency from the CLI instead because statistics volume show does not provide avg_latency. We have previously analyzed these counters in Harvest, which can be found at https://github.com/NetApp/harvest/wiki/Volume-latency-for-flexgroup.
Is there any matches command to this query result?
two consecutive REST calls is between 15s?
it is the schedule defined in collector. For example in Harvest RestPerf Collector it is 60seconds
https://github.com/NetApp/harvest/blob/main/conf/restperf/default.yaml#L8
I suppose the API response should be the same as the "volume_avg_latency" metrics
I think, you are right, ONTAP docs says the same
You can verify it with below CLI command
statistics volume show -volume VOLUME_NAME -interval 60 -iterations 10
But if you are comparing with harvest, CLI start-end of 60second should match with harvest collector start-end which will be tough to match but values should be close
I am running it locally and value is matching with Harvest volume_avg_latency
I tried to verify the value in harvest with the "statistics volume show" command, but the data of "volume_avg" of volume is not the same, so wondering which is the correct one
Could you share the exact CLI with which you compared?
You should use interval 60 in CLI to match with Harvest.
Let me check with the command!!!
Thanks for your help!!!
Amazing
no problem. Thanks We'll correct our document on wiki as well where we compared with volume_read_latency