bugfix on install_mkagent and patch_snmp

This commit is contained in:
2024-09-20 16:38:26 +02:00
parent 092dd214c1
commit 574b57001e
2 changed files with 5 additions and 4 deletions

View File

@@ -12,8 +12,8 @@
# * MK_PORT: Port check_mk agent will use to communicate with server # * MK_PORT: Port check_mk agent will use to communicate with server
# ------------------------------------------------------------------------------ # ------------------------------------------------------------------------------
export VER_install_mkagent="0.0.6" export VER_install_mkagent="0.0.7"
export DEP_install_mkagent="upgrade_dist install_pkg" export DEP_install_mkagent="upgrade_dist"
install_mkagent() install_mkagent()
{ {
@@ -34,6 +34,7 @@ install_mkagent()
gunzip /var/lib/cmk-agent/cmk-agent-ctl.gz gunzip /var/lib/cmk-agent/cmk-agent-ctl.gz
chmod +x /var/lib/cmk-agent/cmk-agent-ctl chmod +x /var/lib/cmk-agent/cmk-agent-ctl
scp -O $MK_SERVER_IP:/etc/check_mk/agentpwd /tmp/mk-pwd scp -O $MK_SERVER_IP:/etc/check_mk/agentpwd /tmp/mk-pwd
sleep 1 # Some execution of cmk-agent-ctl have failed with file not found without that line
/var/lib/cmk-agent/cmk-agent-ctl register --hostname $HOSTNAME \ /var/lib/cmk-agent/cmk-agent-ctl register --hostname $HOSTNAME \
--server $MK_SERVER_IP --site check_mk --user check_mk --password \ --server $MK_SERVER_IP --site check_mk --user check_mk --password \
"$(read /tmp/mk-pwd)" "$(read /tmp/mk-pwd)"

View File

@@ -8,8 +8,8 @@
# https://opensource.org/licenses/BSD-3-Clause # https://opensource.org/licenses/BSD-3-Clause
# ------------------------------------------------------------------------------ # ------------------------------------------------------------------------------
export VER_patch_snmp="0.1.2" export VER_patch_snmp="0.1.3"
export DEP_patch_snmp="install_pkg" export DEP_patch_snmp=""
patch_snmp() patch_snmp()
{ {