deploying the candidate charm stuck in maintenance status
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Telegraf Charm |
Fix Released
|
High
|
Robert Gildein |
Bug Description
Deploying the following bundle in LXD on Juju 2.9.33
series: jammy
applications:
ubuntu:
scale: 1
charm: ch:ubuntu
telegraf:
charm: ch:telegraf
channel: candidate
relations:
- ["ubuntu", "telegraf"]
My juju status is stuck as follows:
Model Controller Cloud/Region Version SLA Timestamp
tele-test localhost-localhost localhost/localhost 2.9.33 unsupported 15:28:35+02:00
App Version Status Scale Charm Channel Rev Exposed Message
telegraf maintenance 1 telegraf candidate 55 no Installing python3-
ubuntu 22.04 active 1 ubuntu stable 20 no
Unit Workload Agent Machine Public address Ports Message
ubuntu/0* active idle 0 10.144.51.60
telegraf/0* maintenance idle 10.144.51.60 Installing python3-
Machine State Address Inst id Series AZ Message
0 started 10.144.51.60 juju-c85c5c-0 jammy Running
Related branches
- Celia Wang: Approve
- Gabriel Cocenza: Needs Fixing
- Eric Chen: Approve
- Robert Gildein: Pending requested
-
Diff: 137 lines (+12/-9)12 files modified.pre-commit-config.yaml (+1/-0)
src/reactive/telegraf.py (+0/-1)
src/requirements.txt (+0/-1)
src/templates/apache-server-status.tmpl (+1/-0)
src/templates/influxdb-api.conf.tmpl (+2/-1)
src/templates/sudoers/telegraf_intel_rdt.tmpl (+1/-0)
src/templates/sudoers/telegraf_ipmi.tmpl (+1/-0)
src/templates/sudoers/telegraf_iptables.tmpl (+1/-0)
src/templates/sudoers/telegraf_ovs.tmpl (+1/-0)
src/templates/sudoers/telegraf_smart.tmpl (+1/-0)
src/templates/telegraf.conf.tmpl (+3/-3)
src/wheelhouse.txt (+0/-3)
- 🤖 prod-jenkaas-bootstack (community): Needs Fixing (continuous-integration)
- Eric Chen: Approve
- BootStack Reviewers: Pending requested
-
Diff: 12 lines (+1/-0)1 file modifiedsrc/reactive/telegraf.py (+1/-0)
tags: | added: bseng-382 |
Changed in charm-telegraf: | |
importance: | Undecided → High |
Changed in charm-telegraf: | |
assignee: | nobody → Robert Gildein (rgildein) |
status: | New → In Progress |
Changed in charm-telegraf: | |
milestone: | none → 22.10 |
status: | In Progress → Fix Committed |
Changed in charm-telegraf: | |
status: | Fix Committed → Fix Released |
I could reproduced this error from 49 revision above
and the cause of the issue is MP [1].
The issue is that function `configure_ telegraf( )` is run only prometheus- client. configured" flag is set, but this prometheus_ client_ with_relation( prometheus) ` - Prometheus relation prometheus_ client( )`
when "plugins.
flag is set only in two functions:
1. `configure_
2. `configure_
And function `configure_ prometheus_ client( )` runs only when `telegraf. configured` , telegraf( )`. So without Prometheus relation telegraf( )` or `configure_ prometheus_ client( )`
which is set only in `configure_
none of the functions `configure_
will be triggered.
I tried to reproduced it (issue mentioned in MP [1]) with deploying
revision 49 as follow:
1. upgrade- charm` method= snap` upgrade- charm`
- `juju deploy ch:telegraf --revision 49 --channel stable --series focal`
- change `install_method` configuration to `snap`
- run `hooks/
2.
- `juju deploy ch:telegraf --revision 49 --channel stable --series focal --config install_
- run `hooks/
3.
- download charm with `juju download telegraf --series xenial --channel stable`
- deploy charm from local file
- change `install_method` configuration to `snap`
- `juju upgrade-charm <name> --switch ch:telegraf-49 --channel stable`
3. method= snap`
- download charm with `juju download telegraf --series xenial --channel stable`
- deploy charm from local file with `--config install_
- `juju upgrade-charm <name> --switch ch:telegraf-49 --channel stable`
None of the approaches reproduced the error.
In this situation we have two options: "telegraf. installed" )`
1. revert changes made in [1]
2. use `@when(
--- /code.launchpad .net/~hloeung/ charm-telegraf/ +git/charm- telegraf/ +merge/ 428004
[1]: https:/