Alias manipulation for queries from InfluxDB - possible?

Hi all,

I’m rather new to Grafana and just started to toy with a PoC graphing my home FreeNAS system. FreeNAS has got an integrated collectd - nothing to configure here but the hostname or address of a remote Graphite server. So far so good.

I found the Graphite stack rather complex with all the moving parts (carbon, whisper), separate web server (Apache/Nginx), uwsgi and all. So I ended with InfluxDB and a Graphite compatible listener. Piece of cake to set up, Grafana too. Really :wink:

Now the series I’d like to graph are these:


My first attempt looked the way I wanted but I used 7 distinct queries. That does not scale to our data centre and graphing dozens of hosts (I already got around creating variables) with varying disk topologies.

But for my second attempt I cannot get it to work like I want to it seems.

First the config:

And the resulting panel:

How do I get rid of the “disktemp-” in front of every temperature reading? I figured it should be possible to use a pattern like “/disktemp-(.*)/” in the regex match for resource but no staring at the “Templating with InfluxDB” and no trial and error gave me a solution.

Any hints most welcome.

Thanks in advance,

I found how I could define a “disk” variable, but then I am again stuck trying to get all values into a single panel. Using a repeating panel for all values of $disk works but takes up a little much screen space :wink:

What’s the magic incantation to group by a multi value variable in a query?

If I understand this fesature request correctly:

There is currently no way to do string manipulation in e.g. the Alias field of the query or the Title field of the visualization config.

As I wrote I was able to define a variable that cuts the “disktemp-” prefix via regex, but it seems I cannot use that in “group by” in the query?

Is there really no way to display all disk temperatures dynamically in a single panel if the Influx data structure is like I described?

I am attempting to develop a Grafana plugin for FreeNAS that comes with a preconfigured dashboard. Naturally I do not know what kind and how many disk drives the eventual users will have in their systems.

Kind regards,