Plugins 〉GreptimeDB


Sign up to receive occasional product news and updates:

Latest webinars
Data Source


  • Overview
  • Installation
  • Change log
  • Related content

GreptimeDB data source

GreptimeDB datasource for grafana

This plugin is currently campatiable with GreptimeDB 0.1.1-alpha.

Learn more about GreptimeDB Github | Website


GreptimeDB currently is not production ready. Do not use it in production at the moment.

Using GreptimeDB in Grafana

Install GreptimeDB


Get GreptimeDB from Greptime's release page here.

This plugin is currently campatiable with GreptimeDB 0.1.1-alpha.

For demostration, run it in standalone mode ./greptime standalone start. In case of port conflicts, start with option -c <config.toml>. The format of config.toml can be found here


There are also some docker images available on Docker Hub.

You can start a GreptimeDB instance with docker like this:

docker run  -p 4000-4004:4000-4004 \
            -p 4242:4242 \
            -v "greptime-vol:/tmp/greptimedb" \
            --name greptime \
            greptime/greptimedb:0.1.1-alpha standalone start

Install The Plugin


Download the plugin from this repo's release page

Put the unzipped plugin folder into your grafana's plugin directory, which default at /var/lib/grafana/plugins

Restart your Grafana and the plugin will be loaded!

Add GreptimeDB data source in Grafana

Add a new data source in grafana, and select GreptimeDB.

As currently GreptimeDB has not implement any authentication yet, we just need to fill the URL input box.

Then click Save & test. It will query numbers from your GreptimeDB to check if the data source is available. If the test result shows Success, you have successfully added your GreptimeDB as Grafana data source!

Visualize your data

If you are a new to GreptimeDB, you may need some dummy data for testing.

First, let's create a time-series table in GreptimeDB. GreptimeDB supports execute sql from HTTP API. You can use curl to execute sql.

curl http://localhost:4000/v1/sql -d "sql=
    CREATE TABLE system_metrics (               
    host STRING,                                      
    idc STRING,                                       
    cpu_util DOUBLE,                                  
    memory_util DOUBLE,                               
    disk_util DOUBLE,                                 
    PRIMARY KEY(host, idc),                           
    TIME INDEX(ts))"

I have written a bash script for you to insert some dummy data.

sql="INSERT INTO system_metrics VALUES"

for i in {1..20}; do host="host$(echo $i%3 | bc)" idc="idc$(echo $i%3 | bc)" cpu_util=$(echo "scale=2; $RANDOM/327.67" | bc) memory_util=$(echo "scale=2; $RANDOM/327.67" | bc) disk_util=$(echo "scale=2; $RANDOM/327.67" | bc) ts=$(echo "$(date -d "-$i minute" +%s) * 1000" | bc) sql="$sql (’$host’, ‘$idc’, $cpu_util, $memory_util, $disk_util, $ts)" if [ $i -lt 20 ]; then sql="$sql," fi done

curl http://localhost:4000/v1/sql -d "sql=$sql"

Go back to Grafana, create a new panel, select your metrics in the query area of your panel and watch the visualization happen!

Installing GreptimeDB on Grafana Cloud:

For more information, visit the docs on plugin installation.



Added visual editor, which supports FROM SELECT WHERE


Added more features to the visual editor, including GROUP BY, Aggregate Function for SELECT


Auto detect time column after table changes. Added detailed error message.


More detailed user guide.


Added a time filter that automatically adds a WHERE clause to the query depending on the time range selected in the dashboard.


Documentation improvements

Update grafanaDependency to ">=9.0.0" to make this plugin install-able in other grafana version.