How to install influxDb & Grafana in QNAP NAS?

How to install influxDb & Grafana in QNAP NAS?

In this tutorial, you will learn how to use QIoT Suite Lite to display data with Grafana (Only support for x86 NAS models)

influxDB container

  • Install influxDB container
  1. Go to Container Station > Click “Create”
  2.  Search “influxdb”
  3.  Click “Install” > Click “Next” > Click “OK”
  4. Go to Network:
    In Port Forwarding, setting port 2003 & 8086

  5. Go to Shared Folders:
    Save Database information to volume (Refer to below path: /var/lib/influxdb)

  6.  Click “Create”
  • Test the influxDB
  1. Go to Container Station > Click “Containers” > Click “influxdb container”
  2. Click “Terminal”
  3. Enter “bash” >  Click “OK”

  4. Enter “influx” and click Enter
  5. Enter “show databases” and click Enter, it will show the screenshot as below:
  • Create database
  1. Create a name with “demo” and enter “create database demo”

QIoT Suite Lite

  1. SSH into NAS
  2. Go into qiot-node-red Container:

    system-docker exec -ti qiot-node-red bash
  3. Move folder to node_modules:
    cd /usr/local/lib/node_modules/node-red/node_modules/ 
  4. Install NodeRED plugin:
    npm install node-red-contrib-influxdb
  5. Restart all process:
    supervisorctl restart all
  • Set up QIoT Suite Lite Rule
  1.  Please ensure you already set up for an IoT application, IoT things, resource
  2.  Go to IoT application > Click Rule
  3.  Pull “influxdb” node to Flow
  4. Click influxdb node > click edit
  5. Refer to the settings of your influxDB and fill in the associated  information (Note: if influxDB and QIoT Suite Lite are in same NAS then fill your IP to
  6. Set up Measurement (Similar with SQL table)
  7. Pull function node to Flow and connect with influxdb node. Click function node to enter code:
    msg.payload = {
    return msg;

  8. Pull QBroker node to flow and click it. Set up Thing-Resource and connect with function node. Click save.

Grafana container

  • Install Grafana container
  1.  Go to Container Station > click “Create”
  2.  Search “grafana”
  3.  Click “Install” > Click “Next” > Click “OK”
  4. Go to Network:
    In Port Forwarding, setting port 3000
  5.  More information, reter to Grafana website:
  6.  Click “Create”
  • Set up Grafana 
  1.  Default url of Grafana: http://[nasIP]:3000
    Default account/password: admin/admin
  2.  Establish database:
    a. Enter your influxDB location (e.g., If you use Container Station to establish influxDB then the url should be:
    b. Enter influxDB database name (e.g., demo)
  3. Grafana Dashboard instruction
    a. Click “+”
    b. Click dashboard

    c. Click Table (Take table as example)

    d. Click panel title and will show the drop-down list
    e. Click edit

    f. Choose data source (e.g., demo)
    g. In FROM, choose measurement
    h. Set up other option
  4.  Install Grafana plugin
    (Refer to
    a. Go to Container Station > click “Cotainers” > click “grafana container”
    b. Click “Terminal”
    c.  Enter below code and click OK:

    grafana-cli plugins install grafana-piechart-panel 

Related posts

Leave a Reply