Add check-gluster-rebalance

This commit is contained in:
Thomas Gebert 2025-12-02 15:47:08 +01:00
parent f8604697f9
commit 3cd8540bd2
4 changed files with 32 additions and 0 deletions

View File

@ -0,0 +1,10 @@
[Unit]
Description=Check status of gluster rebalance
After=glusterd.service
[Service]
Type=oneshot
ExecStart=/usr/local/sbin/check-gluster-rebalance.sh
[Install]
WantedBy=multi-user.target

View File

@ -0,0 +1,12 @@
#!/bin/bash
VOLS="deepunity"
SENDER="icasfs-augustinus@st-augustinus.eu"
RECIPIENT="thomas.gebert@iternity.com"
for VOL in ${VOLS}; do
echo "################################################################################"
echo "# ${VOL}"
gluster vol rebalance "${VOL}" status
echo ""
done | mail -S sendwait -s "gluster rebalance status on $HOSTNAME" -r "${SENDER}" "${RECIPIENT}"

View File

@ -0,0 +1,9 @@
[Unit]
Description=Check status of gluster rebalance
After=glusterd.servcie
[Timer]
OnCalendar=Mon..Fri 07:00
[Install]
WantedBy=multi-user.target

View File

@ -52,6 +52,7 @@ Optionial:
subdirectory of the brick path subdirectory of the brick path
HELP HELP
exit 0
} }