Bug #12128

calamari-ctl intialize fails when there are no connected salt-minions

Added by Christina Meno about 6 years ago. Updated almost 6 years ago.

Can't reproduce
Backend (packaging/deployment)
Target version:
% Done:


3 - minor
Affected Versions:
Crash signature (v1):
Crash signature (v2):

adds updated to already connected minions during calamari installation.

it fails on new installs


#1 Updated by karan singh about 6 years ago

To get more information on this issue visit

A temporary fix is to comment update_connected_minions() line in

Expected : Permanent fix in upstream.

#2 Updated by Özhan Karaman about 6 years ago

I tested the fix and it did not work. I used the compiled server and client files from new site and latest git repository. I think code still needs fix, temporary fix looks like does not work. My server is Ubuntu 14.04.02 with latest updates.


#3 Updated by Stefan Lissmats about 6 years ago

I have the same environment as in the github comment and after commenting the line as karan suggests then the "calamari-ctl initialize" commands runs ok but after logging to calamari i get error 500, not sure if this is related or something other?

#4 Updated by Felix Barbeira about 6 years ago

Same error here with ubuntu 14 LTS and the packages from the repo.

#6 Updated by abouzar parvan almost 6 years ago

i've got the same issue on ubuntu 14.04

but this helped me fix the problem temporarily

in file: [cthulhu/cthulhu/]


if len(Key(master_config(config.get('cthulhu', 'salt_config_path'))).list_keys()['minions']) == 0:
# no minions to update
- return
if master_config(config.get('cthulhu', 'salt_config_path')) is not None:
+ pass
+ else:
+"master_config issue happend!")
except TypeError as err:
+ return

#7 Updated by Christina Meno almost 6 years ago

Thank you for the suggestion.
Would you please help me understand it?

I agree that this condition could be more readable and I am concerned that you've changed the expression substantially without explain what is wrong.

The previous condition was something like:
1. find out where the config_path is
2. parse it
3. coerce it to type Key
4. fetch attribute.list_keys
5. get element 'minions'
6. compare the number of minions to 0

Your replacement reads:
1. find out where the config_path is
2. parse it

Then log an opaque error when your code fails to parse or find the config.

What setup does your code survive?

#8 Updated by Christina Meno almost 6 years ago

  • Status changed from New to In Progress
  • Target version changed from 1.4 backlog to 1.3.1

[gmeno@brown-thrasher calamari]$ git branch -r --contains 1d16be88aa6e672a4e7825 | grep -v wip

#9 Updated by abouzar parvan almost 6 years ago

I’ve tried to work with calamari in Ubuntu 14.04 system and the problem was that sometimes
config.get('cthulhu', 'salt_config_path')
Had no value and sometimes
master_config(config.get('cthulhu', 'salt_config_path'))
Was not null , so I’ve tried to overcome this problem by trying to parse it and if some error happened returning nothing

#10 Updated by Christina Meno almost 6 years ago

abouzar parvan,

I am unable to reproduce these config errors on ubuntu 1404.
Is this a devmode instance? packaged install?
What else can you tell me about this issue?

#11 Updated by abouzar parvan almost 6 years ago

Gregory Meno,

it was a setup according to
but i've used the apt version of salt-master and probably that was what caused the problem, anyway i've compiled my own version of calamari-server and calamari-client and installed 2014.7 version of salt and now everything runs smoothly. so i'm not sure that the problem was caused by salt-master's version or the change in code!

#12 Updated by Christina Meno almost 6 years ago

  • Status changed from In Progress to Can't reproduce

Thank you for following up. I will close this ticket. Feel free to re-open if this issue occurs again.

Also available in: Atom PDF