When using only governor, the charm adds a grub config
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
charm-sysconfig |
Fix Released
|
Low
|
Drew Freiberger |
Bug Description
When deploying a simple bundle like:
series: bionic
applications:
ubuntu:
charm: cs:ubuntu
num_units: 1
sysconfig:
charm: cs:~canonical-
options:
governor: 'performance'
relations:
- - ubuntu:juju-info
- sysconfig:juju-info
We see the following in juju status
Model Controller Cloud/Region Version SLA Timestamp
sysconfig maas maas 2.6.9 unsupported 07:42:13Z
App Version Status Scale Charm Store Rev OS Notes
sysconfig active 1 sysconfig jujucharms 8 ubuntu
ubuntu 18.04 active 1 ubuntu jujucharms 12 ubuntu
Unit Workload Agent Machine Public address Ports Message
ubuntu/0* active idle 0 172.27.12.141 ready
sysconfig/0* active idle 172.27.12.141 reboot required. Changes in: /etc/systemd/
Machine State DNS Inst id Series AZ Message
0 started 172.27.12.141 node02 bionic default Deployed
In the machine, we can see that there's a new /etc/default/
This is due to the fact that during the first config-changed hook, all flags are set to their default value: https:/
Therefore, it will run the update_grub_file function: https:/
In this function, when getting the enable_pti property (as the config option enable-pti is not set), it will set pti_off in the context to True.
A grub file will then be rendered.
Related branches
- JamesLin: Approve
- 🤖 prod-jenkaas-bootstack: Approve (continuous-integration)
- Eric Chen: Approve
- Erhan Sunar: Needs Fixing
- BootStack Reviewers: Pending requested
-
Diff: 149 lines (+71/-7)5 files modifiedsrc/actions.yaml (+1/-1)
src/config.yaml (+3/-0)
src/lib/lib_sysconfig.py (+26/-1)
src/templates/grub.j2 (+0/-5)
src/tests/unit/test_lib.py (+41/-0)
- Alvaro Uria (community): Needs Fixing
- Peter Sabaini (community): Approve
- BootStack Reviewers: Pending requested
- BootStack Reviewers: Pending (mr tracking; do not claim) requested
- Canonical IS Reviewers: Pending requested
-
Diff: 119 lines (+77/-0)2 files modifiedsrc/lib/lib_sysconfig.py (+31/-0)
src/tests/unit/test_lib.py (+46/-0)
- Drew Freiberger (community): Disapprove
- Canonical IS Reviewers: Pending requested
-
Diff: 33 lines (+21/-2)1 file modifiedsrc/reactive/sysconfig.py (+21/-2)
Changed in charm-sysconfig: | |
status: | New → In Progress |
assignee: | nobody → Nicolas Pochet (npochet) |
Changed in charm-sysconfig: | |
assignee: | Nicolas Pochet (npochet) → Drew Freiberger (afreiberger) |
Changed in charm-sysconfig: | |
status: | In Progress → Fix Committed |
milestone: | none → 23.07 |
Changed in charm-sysconfig: | |
status: | Fix Committed → Fix Released |
After a bit more of investigation, it seems that the install_sysconfig() function call update_grub_file without any condition: https:/ /git.launchpad. net/charm- sysconfig/ tree/src/ reactive/ sysconfig. py#n55