Random Project

Excellent plugin !

Thank you for this plugin 😉

I modify it in order to ignore DSM updates. It works perfectly.

These are the lines for add option -I to ignore DSM updates :

case $DSMUpgradeAvailable in
“1”) DSMUpgradeAvailable=”Available”; healthWarningStatus=1; updateMessage=”DSM update available”;;
“2”) DSMUpgradeAvailable=”Unavailable”; healthWarningStatus=0; updateMessage=”Update unavailable”;;
“3”) DSMUpgradeAvailable=”Connecting”; healthWarningStatus=0; updateMessage=”Update in progress”;;
“4”) DSMUpgradeAvailable=”Disconnected”; healthWarningStatus=1; updateMessage=”DSM Update Disconnected”;;
“5”) DSMUpgradeAvailable=”Others”; healthWarningStatus=1; updateMessage=”Check DSM Update”;;
esac

if [ “$ignoreUpdate” = “yes” ] ; then
healthWarningStatus=0;
healthString=”$healthString, Info : $updateMessage”;
else
healthString=”$healthString, $updateMessage”;
fi

and on the last lines, I modify the output for Ok status :

if [ “$healthCriticalStatus” = “0” ] && [ “$healthWarningStatus” = “0” ] ; then
echo “OK – $healthString Appliance is in good health”
exit 0
fi