PVE Native Install of Grafana Alloy Client

tssrshot

New Member
Feb 17, 2026
1
0
1
Is it possible or possibly in advisable to install Grafana Alloy client natively in each PVE Physical Server?

Alloy vs Prometheus Exporter has flipped the script on remote write of logs and metrics, but people are suggesting it as a container…however, that lacks permissions to some key functions like storage and logs to be universally forwarded.

There are Debian repos for Alloy, and there is a small config file element to it.

https://grafana.com/docs/alloy/latest/set-up/install/linux/
 
Hi,

Try this:
1. Create small container: 1 CPU, 256 MB RAM
2. Install alloy in it.
3. In the PVE host console run:

Code:
#!/bin/bash

container=<put-your-container-name-here>

pct set $container -mp0 /,mp=/host/rootfs,ro=1
pct set $container -mp1 /proc,mp=/host/proc,ro=1
pct set $container -mp2 /sys,mp=/host/sys,ro=1
pct set $container -mp3 /run/udev/data,mp=/host/run/udev/data,ro=1

4. Restart container
5. Configure alloy in container:

Code:
//config.alloy example
// journald
loki.source.journal "journal" {
  forward_to = [loki.write.default.receiver]
  relabel_rules = loki.relabel.journal.rules
  max_age    = "12h"
  path       = "/host/rootfs/var/log/journal"
  labels = {
    job  = "systemd-journal",
    host = "pve",
  }
}
prometheus.exporter.unix "pve" {
  // Disable unnecessary collectors to reduce overhead
  disable_collectors = ["ipvs", "infiniband", "xfs", "btrfs"]
  rootfs_path = "/host/rootfs"
  procfs_path = "/host/proc"
  sysfs_path = "/host/sys"
  udev_data_path = "/host/run/udev/data"
  ...
}

6. In container, execute: systemctl start alloy
7. Having rootfs mounted inside the container isn't safe even it's read only.

Good luck.