2024-04-04 07:38:42 |
Arnault MICHEL |
description |
Hi,
As ntp sync is really important for CEPH, we try to add the ntp service for every openstack component with :
model-config.yaml file containing :
```yaml
cloudinit-userdata: |
ntp:
enabled: true
ntp_client: chrony
timezone: Europe/Paris
servers:
- DNSserverIP
package_update: true
package_upgrade: true
...
```
Then `juju add-model --controller my-jujuctrl --config ./openstack/bdf.yaml openstack maas-cloud-provider`
The charm try to uninstall chrony but it raise a python error / exception @ https://opendev.org/openstack/charm-ceph-mon/src/branch/master/src/charm.py#L77
complaining about the "packages" parameter, and provide an infinite loop :
2024-04-03 17:44:01 INFO unit.ceph-mon/1.juju-log server.go:325 Installing ['ceph', 'gdisk', 'radosgw', 'lvm2', 'parted', 'smartmontools'] with options: ['--option=Dpkg::Options::=--force-confold']
2024-04-03 17:44:02 INFO unit.ceph-mon/1.juju-log server.go:325 Updating status
2024-04-03 17:44:02 ERROR unit.ceph-mon/1.juju-log server.go:325 Uncaught exception while in charm code:
Traceback (most recent call last):
File "/var/lib/juju/agents/unit-ceph-mon-1/charm/./src/charm.py", line 317, in <module>
main(CephMonCharm)
File "/var/lib/juju/agents/unit-ceph-mon-1/charm/venv/ops/main.py", line 544, in main
manager.run()
File "/var/lib/juju/agents/unit-ceph-mon-1/charm/venv/ops/main.py", line 520, in run
self._emit()
File "/var/lib/juju/agents/unit-ceph-mon-1/charm/venv/ops/main.py", line 506, in _emit
self.framework.reemit()
File "/var/lib/juju/agents/unit-ceph-mon-1/charm/venv/ops/framework.py", line 861, in reemit
self._reemit()
File "/var/lib/juju/agents/unit-ceph-mon-1/charm/venv/ops/framework.py", line 941, in _reemit
custom_handler(event)
File "/var/lib/juju/agents/unit-ceph-mon-1/charm/./src/charm.py", line 75, in on_install
apt.remove_package(packages=rm_packages, fatal=True)
TypeError: remove_package() got an unexpected keyword argument 'packages'
I solved the problem on our server with a manual uninstall :
juju ssh ceph-mon/0 sudo apt remove chrony -y
juju ssh ceph-mon/1 sudo apt remove chrony -y
juju ssh ceph-mon/2 sudo apt remove chrony -y
Our charm setting is :
ceph-mon:
charm: ceph-mon
channel: quincy/stable
revision: 204
resources:
alert-rules: 3
num_units: 3
to:
- lxd:6
- lxd:7
- lxd:8
options:
expected-osd-count: 3
monitor-count: 3
source: distro |
Hi,
As ntp sync is really important for CEPH, we try to add the ntp service for every openstack component with :
model-config.yaml file containing :
```yaml
cloudinit-userdata: |
ntp:
enabled: true
ntp_client: chrony
timezone: Europe/Paris
servers:
- DNSserverIP
package_update: true
package_upgrade: true
...
```
Then `juju add-model --controller my-jujuctrl --config ./openstack/model-config.yaml openstack my-maas-cloud-provider`
The charm try to uninstall chrony but it raise a python error / exception @ https://opendev.org/openstack/charm-ceph-mon/src/branch/master/src/charm.py#L77
complaining about the "packages" parameter, and provide an infinite loop on the install step of the charm.
juju logs :
2024-04-03 17:44:01 INFO unit.ceph-mon/1.juju-log server.go:325 Installing ['ceph', 'gdisk', 'radosgw', 'lvm2', 'parted', 'smartmontools'] with options: ['--option=Dpkg::Options::=--force-confold']
2024-04-03 17:44:02 INFO unit.ceph-mon/1.juju-log server.go:325 Updating status
2024-04-03 17:44:02 ERROR unit.ceph-mon/1.juju-log server.go:325 Uncaught exception while in charm code:
Traceback (most recent call last):
File "/var/lib/juju/agents/unit-ceph-mon-1/charm/./src/charm.py", line 317, in <module>
main(CephMonCharm)
File "/var/lib/juju/agents/unit-ceph-mon-1/charm/venv/ops/main.py", line 544, in main
manager.run()
File "/var/lib/juju/agents/unit-ceph-mon-1/charm/venv/ops/main.py", line 520, in run
self._emit()
File "/var/lib/juju/agents/unit-ceph-mon-1/charm/venv/ops/main.py", line 506, in _emit
self.framework.reemit()
File "/var/lib/juju/agents/unit-ceph-mon-1/charm/venv/ops/framework.py", line 861, in reemit
self._reemit()
File "/var/lib/juju/agents/unit-ceph-mon-1/charm/venv/ops/framework.py", line 941, in _reemit
custom_handler(event)
File "/var/lib/juju/agents/unit-ceph-mon-1/charm/./src/charm.py", line 75, in on_install
apt.remove_package(packages=rm_packages, fatal=True)
TypeError: remove_package() got an unexpected keyword argument 'packages'
I solved the problem on our server with a manual uninstall :
juju ssh ceph-mon/0 sudo apt remove chrony -y
juju ssh ceph-mon/1 sudo apt remove chrony -y
juju ssh ceph-mon/2 sudo apt remove chrony -y
Our charm setting is :
ceph-mon:
charm: ceph-mon
channel: quincy/stable
revision: 204
resources:
alert-rules: 3
num_units: 3
to:
- lxd:6
- lxd:7
- lxd:8
options:
expected-osd-count: 3
monitor-count: 3
source: distro |
|