Query structure with Grafana/ InfluxDB for "diskio" statistics for IOPs: read, write, sum= read + write

Hi,

[Server side]
telegraf-1.5.0-1.x86_64
grafana-4.6.3-1.x86_64
influxdb-1.4.2-1.x86_64

[Query structure in order to show the SUM for read_bytes/ write_bytes]
Regarding IOPs I need somehow to have the total number of read/ wite IOPs for all: sda + sdb + sdc + dm-x not separate as now: sda, sdb, sdc, dm-x.

Any suggestions?

Kind Regards,

You’re using a group by clause along with the tag name in your query, so InfluxDB is grouping results based on name, in your case sda, sdb, etc. You should modify your group by clause so that it only groups by time and host.

You can find more information about the “Group By” clause in the InfluxDB documentation.

Also, you are currently querying for the number of bytes read and written; this is different from IOPS, which is the number of input / output operations per second. If you are interested in the number of operations, rather than the amount of bytes, you should query against the reads and writes fields instead of read_bytes and write_bytes.

1 Like

Hi,

Thank you for clarifications.
Regarding reads/ writes you are right, I’ve missed this point.
I’ll double check and come back with a feedback today.

Kind Regards,

Yes working fine for me.
Thank you for your valuable support.

I have now in GUI metrics for: total IOPs read, total IOPs write and also for each name= sdb, sdc, dm, etc the IOPs.

I’m searching for a way to have sum= total IOPs read + total IOPs write = total IOPs per server.
I’ve used as Selector the “last” and not the Aggregations “mean”, what do you think about this?

Do you have any recommendation if “last” vs “mean” and also for the sum?

Blockquote
I’m searching for a way to have sum= total IOPs read + total IOPs write = total IOPs per server.
I’ve used as Selector the “last” and not the Aggregations “mean”, what do you think about this?
Blockquote

did someone find an answer for that ?