alloy: node scraper fine tuning to memory consumption reduction

This commit is contained in:
Márcio Fernandes
2026-09-05 01:13:59 +00:00
parent 75ddb9debe
commit 03c24f8d35
@@ -73,7 +73,7 @@ alloy:
// Read journald logs from the host
loki.source.journal "journal" {
max_age = "24h"
max_age = "4h"
relabel_rules = discovery.relabel.host_journal.rules
forward_to = [loki.process.host_journal.receiver]
}
@@ -214,13 +214,20 @@ alloy:
replacement = env("SERVICE")
}
# trying to reduce memory usage
rule {
source_labels = ["__name__"]
regex = "container_fs_.*"
action = "drop"
}
forward_to = [prometheus.remote_write.metrics_service.receiver]
}
prometheus.scrape "cadvisor" {
targets = ["localhost:8080"]
scrape_interval = "30s"
scrape_interval = "60s"
}
prometheus.remote_write "metrics_service" {