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>
14 lines
284 B
Bash
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
|