update
This commit is contained in:
4
dsmon.sh
4
dsmon.sh
@@ -75,13 +75,15 @@ RUN(){
|
||||
fi
|
||||
fi
|
||||
done
|
||||
|
||||
SERVEROS=$(curl -sL https://go.scity.us/get-os | bash)
|
||||
|
||||
thresholdlog=()
|
||||
for KEY in "${!THRESHOLD[@]}"; do
|
||||
thresholdlog+=("${KEY}:${THRESHOLD[$KEY]}")
|
||||
done
|
||||
|
||||
QRY="USE servermonitor; UPDATE hosts SET ip='${SERVERIPS// /}',hostname='${SERVERHOSTNAME}',hostname_full='${SERVERHOSTNAME_FULL}',limits='${thresholdlog[@]}' WHERE id='${SERVERMON_ID}';"
|
||||
QRY="USE servermonitor; UPDATE hosts SET ip='${SERVERIPS// /}',hostname='${SERVERHOSTNAME}',hostname_full='${SERVERHOSTNAME_FULL}',os='${SERVEROS}',limits='${thresholdlog[@]}' WHERE id='${SERVERMON_ID}';"
|
||||
MYSQL_PWD="sysmoninsert" ${mysqlcmd} ${mysql_conn} -u sysmoninsert -e "${QRY}"
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user