TICK stack

the TICK stack is a quite popular software stack consisting of

all published by the Influxdata organization.

The intent of using the TICK-stack is to use it for server monitoring. On the long run I want to deploy a few smart home devices, which send data to an MQTT channel, which gets parsed by Telegraf, which writes the data into the influx time series database.

But first lets look into hardware monitoring. As usual, I am going to set it up with a docker-compose.yml. It looks like this:

tick stack docker-compose.yml
version: 3.9
services:
  influxdb:
    image: influxdb:alpine
    container_name: influxdb
    restart: always
    volumes:
      # Mount for influxdb data directory
      - ./data/influxdb:/var/lib/influxdb
      # Mount for influxdb configuration
      - ./conf/influxdb.conf:/etc/influxdb/influxdb.conf:ro
    ports:
      # The API for InfluxDB is served on port 8086
      - "8086:8086"  
  telegraf:
    image: telegraf:alpine
    container_name: telegraf
    hostname: telle
    restart: always
    volumes:
      # needed for docker input
      - /var/run/docker.sock:/var/run/docker.sock
      - ./conf/telegraf.conf:/etc/telegraf/telegraf.conf
      - /:/hostfs:ro
    environment:
      - HOST_MOUNT_PREFIX=/hostfs
      - HOST_PROC=/hostfs/proc  
  chronograf:
    image: chronograf:alpine
    container_name: chronograf
    restart: always
    volumes:
      # Mount for chronograf database
      - ./data/chronograf/:/var/lib/chronograf/
    ports:
      # The WebUI for Chronograf is served on port 8888
      - "8888:8888"
    depends_on:
      - influxdb  
  kapacitor:
    image: kapacitor:alpine
    container_name: kapacitor
    restart: always
    environment:
      KAPACITOR_HOSTNAME: kapacitor
      KAPACITOR_INFLUXDB_0_URLS_0: http://influxdb:8086
    volumes:
      - ./data/kapacitor:/var/lib/kapacitor
    depends_on:
      - influxdb
    ports:
      - "9092:9092"  
  influxdb-cli:
    image: influxdb:alpine
    container_name: influxdb-cli
    entrypoint:
      - influx
      - -host
      - influxdb

After I checked that everything is up and running and created my config files. I set up telegraf on my laptop to send the CPU and RAM usage into the influxdb and played with the chronograf frontend.

On my Server I set up telegraf to log information from docker, system, disk space and frequently (every 15m) ping a few servers to check that they are up and running. This went quite smooth, the documentation is quite good on this one.

I also included the MQTT logging to log information from my smartmeter but thats another story.

I didn’t quite go into detail with the alerting tool kapacitor as I did not like a few things with chronograf. Chronograf does not allow to include a Dashboard somewhere else as an embedded link (see here). Chronograf is also quite limited in the data visualisation which is the reason I switched to Grafana after a few weeks.

InfluxDB 2.x is going to include the whole TICK stack in one binary, which is a thing I quite don’t like as I gave up using Chronograf and Kapacitor. I hope the 1.x branch will be supported for quite a long time as I don’t see a reason to give up the modularity of InfluxData’s current approach.