From Zero to Dashboard in 10 Minutes with Telegraf, InfluxDB 3, and Grafana

Navigate to:

In this tutorial, let’s walk through setting up a modern TIG stack in 10 minutes. TIG stands for three popular open source tools that complement each other: Telegraf, InfluxDB 3, and Grafana. They are often used to collect, store, and visualize time series data from servers, containers, APIs, or even IoT devices. We will be using a read-to-use GitHub repository that includes:

  • docker-compose.yml to spin up and connect all services
  • .env file to manage environment-specific secrets securely
  • telegraf.conf for collecting local system metrics
  • Support for running either InfluxDB 3 Core or Enterprise
  • Grafana integration walkthrough to quickly explore and visualize the data

Prerequisites

All you need is Docker. Clone the repository from GitHub and launch the stack.

git clone https://github.com/InfluxCommunity/TIG-Stack-using-InfluxDB-3.git
cd TIG-Stack-using-InfluxDB-3

Step 1: Start InfluxDB 3 and generate token

You can choose between the open source InfluxDB 3 Core or, for added features, InfluxDB 3 Enterprise. For this demo, we will reference InfluxDB 3 Core for a quick setup.

docker-compose up -d influxdb3-core
docker-compose exec influxdb3-core influxdb3 create token --admin

Copy the generated token string and update the .env file, particularly the INFLUXDB_TOKEN variable.

Step 2: Launch the full TIG stack

Run the following Docker command to launch the remaining services.

docker-compose up -d

This will trigger:

  • Telegraf collecting your system metrics and writing to various tables inside InfluxDB 3.
  • Grafana on port 3000. (Make sure to connect it with the correct InfluxDB 3 by setting up the URL for Docker along with a token. Choose SQL as the standard query language.)
  • InfluxDB 3 on port 8181.

Step 3: Verify it’s working

Check logs to confirm data is being collected by Telegraf.

docker-compose logs telegraf

Check if Telegraf has created tables in InfluxDB.

docker-compose exec influxdb3-core influxdb3 query \
  "SHOW TABLES" --database local_system --token YOUR_TOKEN_STRING

Step 4: Visualize data in Grafana

  • Open http://localhost:3000
  • Log in using the credentials from your .env file admin/admin by default)
  • Add a new data source:
    • Type: InfluxDB
    • Language: SQL
    • URL:
      • http://influxdb3-core:8181
    • Token: Paste your InfluxDB token
  • Create a new dashboard and add a panel. Use this SQL query to visualize CPU usage:
SELECT "cpu", "usage_user", "time"
FROM "cpu"
WHERE "time" >= $__timeFrom AND "time"<= $__timeTo AND "cpu" = 'cpu0'

Tear down the stack

To stop and clean up:

docker-compose down           # Stop services
docker-compose down -v        # Stop and remove volumes

Mission completed

In just 10 minutes, we went from zero to a real-time monitoring dashboard using Telegraf, InfluxDB 3, and Grafana, all running within Docker.

This setup is fast, flexible, and easy to extend. Whether you’re prototyping locally or preparing for Industrial IoT in production, the modern TIG stack gives you a solid foundation for observability.

In an upcoming blog, we’ll take this further by deploying the TIG stack in a production-ready Kubernetes cluster using Helm charts.