Files
KNELIAC/roles/oam/files/librenms/postfix-queues
T
mrcharles 3919ff400d feat(oam): add LibreNMS/check_mk monitoring agent role
Port Modules/OAM/oam-librenms.sh.

Deploys the check_mk agent and systemd socket for LibreNMS monitoring,
along with the local plugins: distro, dmi, dpkg, ntp-client,
os-updates, postfixdetailed, and postfix-queues.

🤖 Generated with [Crush](https://github.com/charmassociates/crush)

Assisted-by: GLM-5 via Crush <crush@charm.land>
2026-07-30 12:16:07 -05:00

14 lines
284 B
Bash

#!/bin/bash
#Written by Valec 2006. Steal and share.
#Get postfix queue lengths
#extend mailq /opt/observer/scripts/getmailq.sh
QUEUES="incoming active deferred hold"
for i in $QUEUES; do
COUNT=$(qshape "$i" | grep TOTAL | awk '{print $2}')
printf "$COUNT\n"
done