Agent Baking not working after upgrade to 2.1.0p12

After upgrading from 2.1.0p11 to 2.1.0p12 we are not able to bake the agents.
We get this error message

Error creating agent for XXXXXX: Error in bakery plugin "cmk_update_agent" ("files" section): 'config'
Traceback (most recent call last):
  File "/omd/sites/cn_central/lib/python3/cmk/base/cee/bakery/", line 328, in _collect_bakelet_objects
    objects += function(**func_args)
  File "/omd/sites/cn_central/lib/python3/cmk/base/cee/bakery/core_bakelets/", line 167, in get_cmk_update_agent_files
    updater_starter = get_unix_agent_agent_updater_binary_lines(agconf["agent_paths"], interval)
  File "/omd/sites/cn_central/lib/python3/cmk/base/cee/bakery/core_bakelets/", line 252, in get_unix_agent_agent_updater_binary_lines
    "MK_CONFDIR=%s" % agent_paths["config"],
KeyError: 'config'
Error creating agent for XXXXX: Error in bakery plugin "cmk_update_agent" ("files" section): 'config'
1 Like

Is it possible that you have a rule “Installation paths for agent files (Linux, UNIX)” in your system? If yes please check this rule. On my test system it is working without this error.

Hi @andreas-doehler
yes, we have such a rule for “Directory for storage of temporary data” that we set to “/var/tmp/” because our “/tmp” has no-exec bit enabled.
This was working in p11

Can you please test to set all the other folders to the default value?

It works when deactivating the rule. But we need this rule.

That’s why i said, please also set the other paths. There you can leave the default values. But active the other paths.


Hi @andreas-doehler

that was the right hint. When setting all other folders with default value also the bakery works.
Thank you.
But i think this should be considered as a bug.

Yes the bake script should check if the other paths are set or not. If not set the bake script should always use the default value.


I’m investigating the problem right now

The problem had been found and fixed, the fix had been sent for the review.
Next release will be fre from the bug. In meantime, I would suggest to use the workaround from Andreas Doehler.
Thank you, guys, for very useful information.