Charm Ceilometer Agent Install Hook in Failed state

Bug #2048226 reported by Faiz Ahmed
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Ceilometer Agent Charm
Invalid
Undecided
Unassigned

Bug Description

I am trying to deploy ceilometer-agent on 2 nova-compute machines and both of the units are throwing same output.

"ceilometer-agent" application is going in failed status with the message 'hook failed: "install"'.

Used following commands "ceilometer-agent"-
```
juju deploy ceilometer-agent --channel yoga/stable

juju integrate ceilometer-agent nova-compute
juju integrate ceilometer-agent:amqp rabbitmq-server:amqp
juju integrate ceilometer:ceilometer-service ceilometer-agent:ceilometer-service
```

Below is the debug-log for ceilometer-agent -

```
WARNING unit.ceilometer-agent/0.install CONFIGS = register_configs()
WARNING unit.ceilometer-agent/0.install File "/var/lib/juju/agents/unit-ceilometer-agent-0/charm/hooks/ceilometer_utils.py", line 120, in register_configs
WARNING unit.ceilometer-agent/0.install if CompareOpenStackReleases(release) >= 'queens':
WARNING unit.ceilometer-agent/0.install File "/var/lib/juju/agents/unit-ceilometer-agent-0/charm/charmhelpers/core/strutils.py", line 97, in __init__
WARNING unit.ceilometer-agent/0.install raise KeyError("Item '{}' is not in list '{}'"
WARNING unit.ceilometer-agent/0.install KeyError: "Item 'bobcat' is not in list '('diablo', 'essex', 'folsom', 'grizzly', 'havana', 'icehouse', 'juno', 'kilo', 'liberty', 'mitaka', 'newton', 'ocata', 'pike', 'queens', 'rocky', 'stein', 'train', 'ussuri', 'victoria', 'wallaby', 'xena', 'yoga')'"
ERROR juju.worker.uniter.operation hook "install" (via explicit, bespoke hook script) failed: exit status 1
INFO juju.worker.uniter awaiting error resolution for "install" hook
INFO juju.worker.uniter awaiting error resolution for "install" hook
INFO juju.worker.uniter awaiting error resolution for "install" hook
```

Model-Controller-Cloud/Region/Version -
```
Model Controller Cloud/Region Version
openstack maas-controller maas-one/default 3.1.7
```

Juju Status for the app -
```
App Version Status Scale Charm Channel Rev Exposed Message
ceilometer-agent error 2 ceilometer-agent yoga/stable 509 no hook failed: "install"
```

Revision history for this message
Alex Kavanagh (ajkavanagh) wrote :

Please could you add the output of `juju status nova-compute`? ceilometer-agent is a subordinate charm so we need a more complete picture of what is being installed.

Thanks.

Changed in charm-ceilometer-agent:
status: New → Incomplete
Revision history for this message
Faiz Ahmed (faizahmedfarooqui) wrote (last edit ):

Output of the command "juju status nova-compute" -

```
Model Controller Cloud/Region Version SLA Timestamp
openstack maas-controller maas-one/default 3.1.7 unsupported 06:21:18Z

App Version Status Scale Charm Channel Rev Exposed Message
ceilometer-agent error 2 ceilometer-agent yoga/stable 509 no hook failed: "install"
nova-compute 28.0.0 active 2 nova-compute 2023.2/stable 703 no Unit is ready
ovn-chassis 23.09.0 active 2 ovn-chassis 23.09/stable 178 no Unit is ready

Unit Workload Agent Machine Public address Ports Message
nova-compute/4 active idle 13 10.2.1.241 Unit is ready
  ceilometer-agent/6* error idle 10.2.1.241 hook failed: "install"
  ovn-chassis/5 active idle 10.2.1.241 Unit is ready
nova-compute/5* active idle 14 10.2.1.242 Unit is ready
  ceilometer-agent/7 error idle 10.2.1.242 hook failed: "install"
  ovn-chassis/4* active idle 10.2.1.242 Unit is ready

Machine State Address Inst id Base AZ Message
13 started 10.2.1.241 bls10202-i48-blr-c1 ubuntu@22.04 default Deployed
14 started 10.2.1.242 bls10128-i49-blr-c2 ubuntu@22.04 default Deployed
```

I have also attached the screenshot of the terminal.

Revision history for this message
Faiz Ahmed (faizahmedfarooqui) wrote :

I am also attaching a screenshot showing the "juju status" command's output for the reference in this comment.

Revision history for this message
Alex Kavanagh (ajkavanagh) wrote :

This is the issue:

  ceilometer-agent error 2 ceilometer-agent yoga/stable 509 no hook failed: "install"
  nova-compute 28.0.0 active 2 nova-compute 2023.2/stable 703 no Unit is ready

nova-compute is using 2023.2/stable (bobcat), whereas ceilometer-agent is being deployed from yoga/stable. That version of ceilometer-agent won't work with bobcat.

Possibly the bundle is wrong, or there is some other issue.

Please check the bundle and verify which channel the ceilometer-agent charm is being deployment from.

Revision history for this message
Faiz Ahmed (faizahmedfarooqui) wrote (last edit ):

Oh! Ok, I did not know we have to keep them on the same channel.

No, you're right - it was the channel version issue. I refreshed ceilometer-agent to 2023.2/stable channel and it worked as expected. Thank You.

Revision history for this message
Alex Kavanagh (ajkavanagh) wrote :

Hi Faiz

> No, you're right - it was the channel version issue. I refreshed ceilometer-agent to 2023.2/stable channel and it worked as expected.

Excellent! Good to know you got it working. In general OpenStack versions only tend to work +1/-1 (e.g. yoga with zed or 2023.1 (antelope), and they work best if exactly the same. The API services (keystone, glance, cinder, nova, etc.) all use microversioned APIs which helps (as the client indicates the API it wants to use), so the API services should always be the same or 1+ ahead of the non API services.

Hope that helps!

Changed in charm-ceilometer-agent:
status: Incomplete → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.