Skip to content. | Skip to navigation

Personal tools
Sections

clusterstatus.sh

by Ken Manheimer last modified Aug 05, 2011 02:10 PM
Filed under: , , ,
my own variant of the cluster shutdown script, circa 2009. the main differences from the standard scripts is that these custom versions didn't have their locations hard coded, and they called each other, reducing code duplication and drift.

#!/bin/sh
# Cluster Status Discovery

zeoclients="client1 client2"

clusterpath=${0%/*}/..

if [ ! -w ${clusterpath}/var/blobstorage ]; then
echo "You lack the rights necessary to run this script;\nTry sudo $0"
exit 1
fi

echo "ZEO Server:"
${clusterpath}/bin/zeo status
for client in $zeoclients
do
echo "Zope Client:" $client
${clusterpath}/parts/${client}/bin/zopectl status
done

Document Actions