ussuri: unable to stop and start an instance post upgrade
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Ubuntu Cloud Archive |
Fix Released
|
Critical
|
James Page | ||
Ussuri |
Fix Committed
|
Critical
|
James Page | ||
Victoria |
Fix Released
|
Critical
|
James Page | ||
nova (Ubuntu) |
Fix Released
|
Critical
|
James Page | ||
Focal |
Fix Released
|
Critical
|
James Page | ||
Groovy |
Fix Released
|
Critical
|
James Page |
Bug Description
== Impact ==
instances cannot be stopped and then started
== Test Case ==
Deploy OpenStack (using Juju Charms)
Create networking and boot an instance
stop the instance
start the instance
(fails with permissions errors)
== Regression Potential ==
Low - the proposed change opens the permission under /var/lib/nova to allow for the odd ownership changes that happen during instance lifecycle.
== Original Bug Report ==
bionic or focal with OpenStack Ussuri.
The latest version of the nova package sets permissions on package update for /var/lib/nova:
find /var/lib/nova -exec chown nova:nova "{}" +
find /var/lib/nova -type f -exec chmod 0640 "{}" + -o -type d -exec chmod 0750 "{}" +
However, when managing vm's via libvirt, various ownership changes happen to the underlying disks that mean that nova can no longer access the disk files with 0640 permissions.
The disks (and base image) for a vm are created as nova:nova; libvirt then shifts the ownership to libvirt-qemu:kvm as the vm starts. When the vm is stopped the ownership reverts to root:root.
0640 permissions are maintained - however nova is not part of the root or kvm groups so cannot access the file - which means the instance cannot be restarted.
The following permissions are required for correct operation:
find /var/lib/nova -type f -exec chmod 0644 "{}" + -o -type d -exec chmod 0755 "{}" +
Changed in nova (Ubuntu Focal): | |
status: | New → Triaged |
Changed in nova (Ubuntu Groovy): | |
status: | New → Triaged |
Changed in nova (Ubuntu Focal): | |
importance: | Undecided → Critical |
Changed in nova (Ubuntu Groovy): | |
importance: | Undecided → Critical |
Changed in nova (Ubuntu Focal): | |
assignee: | nobody → James Page (james-page) |
Changed in nova (Ubuntu Groovy): | |
assignee: | nobody → James Page (james-page) |
description: | updated |
Changed in nova (Ubuntu Groovy): | |
status: | Triaged → In Progress |
Changed in nova (Ubuntu Focal): | |
status: | Triaged → In Progress |
Changed in cloud-archive: | |
status: | In Progress → Fix Committed |
Linked bug 691590