I am trying to get the volume number with this metrics "count( count by(volume) (volume_total_ops{datacenter=~"$Datacenter",cluster=~"$Cluster",node=~"$Node",svm=~"$SVM",volume=~"$Volume"}) )"
And I get an integer with the query and want to multiply this number with an integer to provision the amount.
But after adding *5000 in the metric, it goes error with no data.
#Prometheus multiply error
1 messages · Page 1 of 1 (latest)
Seems to work fine for me
I'm unsure about the need for the double counting in your expression. Perhaps a better expression will be?
count(volume_total_ops{datacenter="u2",cluster="umeng-aff300-01-02",node="umeng-aff300-01",svm="astra_300"}) * 5000
"invalid parameter "query": 1:6: parse error: unexpected character: '\ufeff'"
No idea with this error
Could you paste the query. Are you using prometheus?
Yes, using prometheus
count( count by(volume) (volume_total_ops{cluster="cluster1",datacenter="tplab",node="cluster1-01",svm="demo"}) )*1000
your query seems to have special chars. I copy pasted it and seeing this
count( count by(volume) (volume_total_ops{cluster="cluster1",datacenter="tplab",node="cluster1-01",svm="demo"}) )
This is the query befor adding *1000
And this works
Seems like adding *1000 change the format?
Can you try below
count(count by(volume)(volume_total_ops{cluster="cluster1",datacenter="tplab",node="cluster1-01",svm="demo"}))*1000
This works!
What is the issue?
same as i mentioned above. Somehow adding 1000 added special chars to your query
Could be related to editor being used
Thanks so much @leaden barn
Also, is it any way to filter the svm that conatins "nfs"?
count( count by(volume) (volume_total_ops{datacenter=~"$Datacenter",cluster=~"$Cluster",node=~"$Node",svm=".nfs."}) )
This seems doesn't work