Hi, I am deploying openstack using MAAS and JUJU (documentation link here: https://docs.openstack.org/project-deploy-guide/charm-deployment-guide/latest/install-maas.html). Although almost every single charm deployed correctly, but I have problem with ntp. In my attached screenshot below you can see my juju status.https://askubuntu.com/questions/983461/is-it-possible-to-check-the-open-ports-in-a-juju-charm) subprocess.CalledProcessError: Command ‘[‘open-port’, ‘123/UDP’]’ returned non-zero exit status 1. Why juju deployed 5 units? As far as I understand 4 is enough and it would worked perfectly for me
It looks like the ntp hook just failed on the one unit ntp/12. To debug this you can use the
juju debug-log tool or you can ssh to the unit and take a look at the unit log in
There are 5 ntp units because it’s a subordinate. What that means is that it’s related to principal applications. Any time one of these principals spins up (juju add-unit, etc) then a new ntp will come up and also be on the same machine. In this case you’ve got
- 4 ceph-osd units with an ntp on each
- 1 neutron-gateway unit with an ntp
This is why you end up with 5 of them.
Thank you for response, Rick My error log of /var/log/juju/unit-ntp-12.log is:
Hmm, maybe? It’d be interesting to try to run that using the debug-hooks tool and manually try to run the open-port command that’s generated and see what the error message coming out of that is.
Yes. Steps I made was:
juju debug-hooks ntp/12
And here comes the output:
It looks I was right, but next question is how to avoid this error…
Oh hmm, this looks odd. You have both ntp 10 and 12 on the same machine? I think there might be a confusion there. As a subordinate should only be setup once per machine. Otherwise they’re competing for managing the same local config files and such. I think an audit of what is on the machine and what subordinates are in play is in order. You might have to remove the subordinate relation from the neutron-gateway if it’s on the same machine as a ceph-osd, for instance.
Yes I do have ntp/10 and ntp/12 on the same machine. If I do “juju remove-unit ntp/10” I get output “removing unit ntp/10 failed: unit “ntp/10” is a subordinate”
From openstack documentation (https://docs.openstack.org/project-deploy-guide/charm-deployment-guide/latest/install-openstack.html):
And it says to add a relation between neutron-gateway and ntp. Is something wrong with a documentation?
Well I think it assumes they’re on different machines. Instead of removing the unit break the relation.
juju remove-relation ntp neutron-gateway
Okay. My juju status output is all green now. I hope everything will work fine now Thank you for your help
Awesome! Glad we got it sorted out.