Expand my Community achievements bar.

Who Me Too'd this topic

Avatar

Level 3

Hi,

I am running below curl function status check from jump servers to verify whether system console is up and running or not across many publishers. We have almost 50+ publishers running across different environments (Prod/Dev/DTQ/SIT etc..).

Problem here is all environments doesn't have common 499 bundles active. Some publishers have 500 active and some have 497 active bundles and some other servers varies with count. 

 

I am looking for a curl command that checks and confirms system console is up and running and also 

all active bundles in total are running. Can someone please assist?

 

function status()
{
/bin/su - root -c "curl -u 'admin':'admin' http://localhost:41000/system/console/bundles/.json | cut -d':' -f2,3 | egrep 499 >> /dev/null"
EXIT_STATUS=`echo $?`
if [ $EXIT_STATUS != 0 ]
then
echo ""
echo "Service is not running"
else
echo ""
echo "Service is running"
fi
}

 

 

Sample Output of below curl

----------------------------

curl -u 'admin':'admin' http://localhost:41000/system/console/bundles/.json | cut -d':' -f2,3

 

% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 93826 0 93826 0 0 3847k 0 --:--:-- --:--:-- --:--:-- 4363k
"Bundle information: 497 bundles in total - all 497 bundles active.","s"

Who Me Too'd this topic