This commit is contained in:
2024-01-25 08:04:51 -06:00
parent 831360a7d0
commit bfddb26ad7
2 changed files with 16 additions and 2 deletions

View File

@@ -1,5 +1,5 @@
VERS='2.5.158-01252024' VERS='2.5.159-01252024'
noheader=' update service dailytemp confsync -r -report ' noheader=' update service dailytemp confsync -r -report '

View File

@@ -630,6 +630,20 @@ HOSTMGMT(){
sleep 3s sleep 3s
done done
if [ "${POWER^^}" == "ON" ] && ([ "${ESXI_HOST}" == "ALL" ] || [ "${ESXI_HOST}" == "MAINSITE" ]); then
##DECREASE CPU OVERCOMMIT
if [[ "${PW_OFFSITE_HOSTS}" != *"${ESXI_HOST}"* ]] && [ "${ESXI_HOST}" != "OFFSITE" ]; then
MSG="Decreasing DRS CPU-Overcommit back down to 2"
c=0; MSG_SPC=''; spc1=`expr ${HC_CW} - ${#MSG}`; until [ ${c} = ${spc1} ]; do MSG_SPC="${MSG_SPC} "; ((c++)); done
echo -en "${idsCL[White]}${MSG}${MSG_SPC}: "
if [ "${TEST}" != "true" ]; then
${PW_FOLDER}/esxi-scripts/set-drs.ps1 2 >/dev/null 2>&1
echo -e "${idsCL[Green]}Done${idsCL[Default]}\n"
else
echo -e "${idsCL[Yellow]}(TEST MODE)${idsCL[Default]}\n"
fi
fi
fi
else else
HOSTPOWER ${ESXI_HOST} ${POWER} HOSTPOWER ${ESXI_HOST} ${POWER}
fi fi