Skip to content

Set up monitoring and logging for your Linux server

Last updated on

Configure your server to send metrics to STACKIT Observability and use Grafana to visualize them.

  1. Create an Observability instance.

  2. Install a monitoring agent on the server, for example Telegraf, and configure it to push the metrics to the instance. This is a basic Telegraf configuration in /etc/telegraf/telegraf.d/:

    [[outputs.http]]
    ## URL is the address to send metrics to
    url = "[Observability Instance Receive URL]"
    username = "[Observability Instance Username]"
    password = "[Observability Instance Password]"
    ## Data format to output.
    data_format = "prometheusremotewrite"
    [outputs.http.headers]
    Content-Type = "application/x-protobuf"
    Content-Encoding = "snappy"
    X-Prometheus-Remote-Write-Version = "0.1.0"
  3. Open the Grafana instance of your Observability instance and set up your dashboards.

  4. Optional: Create alerts in your Observability instance.

Configure your server to send logs to STACKIT Logs, a central log store.

  1. Create a STACKIT Logs instance.

  2. Install a log collector on the server, for example Grafana Alloy.

  3. Configure the collector to send the logs to the instance. For a basic configuration, see Grafana Alloy: Write log data to Logs instance.