Info |
---|
This article helps troubleshoot the Python module that is used for the updater. |
Status |
---|
colour | Green |
---|
title | LAST TESTED ON CHECKMK 2.3.0P1 |
---|
|
Panel |
---|
borderColor | black |
---|
bgColor | #f8f8f8 |
---|
title | Table of Contents |
---|
|
|
Problem: zipped Python module
During the registration of the Check_MK Updater on Windows, you may face this issue:
Code Block |
---|
language | powershell |
---|
theme | RDark |
---|
|
C:\Program Files (x86)\checkmk\service>check_mk_agent.exe updater -vv
You must install Python Module to use the updater with parameters '-vv'.
To install Python Module you should use Bakery. |
...
Note |
---|
Please make sure that you open the cmd/powershell PowerShell as an administrator! |
The problem is , that the python Python module was not successfully unzipped during the updater process:
Info |
---|
Image Removed |
A possible workaround
Reinstall of the Python
...
Image Added
Or the folder is completely empty
Image Added
A possible workaround
If you have only a python_x.cap file
For some reason, you may have only one python_x.cap file in your folder. In that case, you have these two options:
Reinstall the Python (if the folder is zipped)
Code Block |
---|
language | powershell |
---|
theme | RDark |
---|
|
mkdir C:\ProgramData\checkmk\agent\modules\python-3 & expand C:\ProgramData\checkmk\agent\install\modules\python-3.cab -F:* C:\ProgramData\checkmk\agent\modules\python-3 && cd C:\ProgramData\checkmk\agent\modules\python-3 && call postinstall.cmd |
Reinstall the Python (if the folder is empty)
Code Block |
---|
language | powershell |
---|
theme | RDark |
---|
|
expand C:\ProgramData\checkmk\agent\install\modules\python-3.cab -F:* C:\ProgramData\checkmk\agent\modules\python-3 && cd C:\ProgramData\checkmk\agent\modules\python-3 && call postinstall.cmd |
Reinstall the Python (if the folder is zipped)
Code Block |
---|
language | powershell |
---|
theme | RDark |
---|
|
mkdir C:\ProgramData\checkmk\agent\modules\python-3.8 & expand C:\ProgramData\checkmk\agent\install\modules\python-3.8.zip -F:* C:\ProgramData\checkmk\agent\modules\python-3.8 && cd C:\ProgramData\checkmk\agent\modules\python-3.8 && call postinstall.cmd |
Reinstall the Python (if the folder is empty)
Code Block |
---|
language | powershell |
---|
theme | RDark |
---|
|
expand C:\ProgramData\checkmk\agent\install\modules\python-3.8.zip -F:* C:\ProgramData\checkmk\agent\modules\python-3.8 && cd C:\ProgramData\checkmk\agent\modules\python-3.8 && call postinstall.cmd |
...
Increase the timeout of the updater
Via bakery
Go to Setup → Agents → Windows, Linux, Solaris, AIX → AIX → Agent rules → Set → Set timeouts for plugins and local checks
...
Image Added
Image Removed
Script Pattern: cmk_update_agent.checkmk.py
After saving the rule, you need to must bake and sign the new agent!
Here we described in a detailed way detail how to configure caching and timeout for Windows plugins: Asynchronous execution of Windows plugins.
Via config file
Code Block |
---|
language | powershell |
---|
theme | RDark |
---|
title | C:\ProgramData\checkmk\check_mk.user.yml |
---|
|
plugins:
enabled: true
execution:
cache_age: 86400
pattern: $CUSTOM_PLUGINS_PATH$\cmk_update_agent.checkmk.py
timeout: 180 |
...
Please create an exception for the following paths for the AV:
Code Block |
---|
language | powershell |
---|
theme | RDark |
---|
|
C:\ProgramData\checkmk
C:\Program Files (x86)\checkmk |
...
Reinstall python
Code Block |
---|
|
:: Reinstall Checkmk Python module for Windows agent
@echo off
if not exist "%ProgramData%\checkmk\agent\install\modules\python-3.8.zip" (
echo "%ProgramData%\checkmk\agent\install\modules\python-3.8.zip" is absent, impossible to reinstall
exit /b 1
)
cd %ProgramData%\checkmk\agent || echo "Windows agent is not installed" && exit /b 11
net stop checkmkservice
mkdir modules\python-3.8
cd modules\python-3.8
expand %ProgramData%\checkmk\agent\install\modules\python-3.8.zip -F:* %ProgramData%\checkmk\agent\modules\python-3.8 1>nul
call postinstall.cmd
net start checkmkservice |
...
Filter by label (Content by label) |
---|
showLabels | false |
---|
max | 5 |
---|
spaces | KB |
---|
showSpace | false |
---|
sort | modified |
---|
reverse | true |
---|
type | page |
---|
cql | label in ( "agent_bakerywindows" , "python","agent","windows_agent" , "windows","updaterpython" ) and type = "page" and space = "KB" |
---|
labels | windows updater agent agent_bakery windows_agent pythonsecurity |
---|
|
...