Add check-gluster-rebalance
This commit is contained in:
parent
f8604697f9
commit
3cd8540bd2
@ -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
|
||||
12
gluster/check-glsuter-rebalance/check-gluster-rebalance.sh
Normal file
12
gluster/check-glsuter-rebalance/check-gluster-rebalance.sh
Normal 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}"
|
||||
@ -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
|
||||
@ -52,6 +52,7 @@ Optionial:
|
||||
subdirectory of the brick path
|
||||
|
||||
HELP
|
||||
exit 0
|
||||
}
|
||||
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user