[standalone] /run/libvirt is needed, although libvirt-daemon isn't installed

Bug #1801977 reported by Cédric Jeanneret
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
tripleo
Fix Released
High
Cédric Jeanneret

Bug Description

Dear Stacker,

While doing some work on the standalone deploy with podman, I discovered an issue:

Nova containers want to bind-mount /run/libvirt, but apparently, libvirt-daemon is not installed for standalone deploy.

If the absence of the host /run/libvirt directory doesn't cause any trouble with docker, that's not the same for podman.

So I see two possibilities:
- either add libvirt-daemon as a hard dependency
- or create another host location for the "libvirt" shared directory.

The second possibility is OK if and only if the host libvirt service isn't used. This appears to be the case, since the libvirtd is deactivated at some point.

For now, we don't have this issue with the overcloud deploy, as the libvirt packages are still installed in the overcloud-full image:
https://github.com/openstack/tripleo-puppet-elements/blob/ba45a6c5f5454ca736eadb5b684b4cd7a5fd4173/elements/overcloud-compute/install.d/package-installs-overcloud-compute#L3

But as I suspect this will change with the full containerization, it might be good to ensure we have a safe way out.

Any thoughts?

Cheers,

C.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to tripleo-heat-templates (master)

Fix proposed to branch: master
Review: https://review.openstack.org/615956

Changed in tripleo:
assignee: nobody → Cédric Jeanneret (cjeanner)
status: Triaged → In Progress
Revision history for this message
Oliver Walsh (owalsh) wrote :

Creating a different location on the host LGTM. Not sure if we are relying on /var/run/libvirt cleanup on reboot though.

Changed in tripleo:
assignee: Cédric Jeanneret (cjeanner) → Emilien Macchi (emilienm)
assignee: Emilien Macchi (emilienm) → Cédric Jeanneret (cjeanner)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to tripleo-heat-templates (master)

Reviewed: https://review.openstack.org/615956
Committed: https://git.openstack.org/cgit/openstack/tripleo-heat-templates/commit/?id=f65664ff56de26b6e98ffcf09001427e5a8bdaf3
Submitter: Zuul
Branch: master

commit f65664ff56de26b6e98ffcf09001427e5a8bdaf3
Author: Cédric Jeanneret <email address hidden>
Date: Tue Nov 6 18:51:43 2018 +0100

    Ensure directories managed by libvirt-daemon exist

    The /var/run/libvirt directory is managed by libvirt-daemon. As
    this service is now running within a container, the directory
    might not exists on a fresh install.
    This patch also takes care of the fact the /var/run directory is
    cleaned upon reboot, and uses systemd-tmpfiles in order to ensure
    the directory creation during the boot process.

    We also take care of missing log directories, also managed by the
    libvirt-daemon package.

    Change-Id: I6f8dc49ff556215a25e8bb23ae8da63ce607d70c
    Closes-Bug: #1801977

Changed in tripleo:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/tripleo-heat-templates 10.2.0

This issue was fixed in the openstack/tripleo-heat-templates 10.2.0 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to tripleo-heat-templates (stable/rocky)

Fix proposed to branch: stable/rocky
Review: https://review.opendev.org/675262

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to tripleo-heat-templates (stable/queens)

Fix proposed to branch: stable/queens
Review: https://review.opendev.org/675357

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to tripleo-heat-templates (stable/rocky)

Reviewed: https://review.opendev.org/675262
Committed: https://git.openstack.org/cgit/openstack/tripleo-heat-templates/commit/?id=2beb6e7d5b94527dc4b3ce8f93f4e9d590707bfc
Submitter: Zuul
Branch: stable/rocky

commit 2beb6e7d5b94527dc4b3ce8f93f4e9d590707bfc
Author: Cédric Jeanneret <email address hidden>
Date: Tue Nov 6 18:51:43 2018 +0100

    Ensure directories managed by libvirt-daemon exist

    The /var/run/libvirt directory is managed by libvirt-daemon. As
    this service is now running within a container, the directory
    might not exists on a fresh install.
    This patch also takes care of the fact the /var/run directory is
    cleaned upon reboot, and uses systemd-tmpfiles in order to ensure
    the directory creation during the boot process.

    We also take care of missing log directories, also managed by the
    libvirt-daemon package.

    Change-Id: I6f8dc49ff556215a25e8bb23ae8da63ce607d70c
    Closes-Bug: #1801977
    (cherry picked from commit f65664ff56de26b6e98ffcf09001427e5a8bdaf3)

tags: added: in-stable-rocky
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to tripleo-heat-templates (stable/queens)

Reviewed: https://review.opendev.org/675357
Committed: https://git.openstack.org/cgit/openstack/tripleo-heat-templates/commit/?id=82d0b03d237fc1c3024daaa6fe480549a13d000f
Submitter: Zuul
Branch: stable/queens

commit 82d0b03d237fc1c3024daaa6fe480549a13d000f
Author: Cédric Jeanneret <email address hidden>
Date: Tue Nov 6 18:51:43 2018 +0100

    Ensure directories managed by libvirt-daemon exist

    The /var/run/libvirt directory is managed by libvirt-daemon. As
    this service is now running within a container, the directory
    might not exists on a fresh install.
    This patch also takes care of the fact the /var/run directory is
    cleaned upon reboot, and uses systemd-tmpfiles in order to ensure
    the directory creation during the boot process.

    We also take care of missing log directories, also managed by the
    libvirt-daemon package.

    Change-Id: I6f8dc49ff556215a25e8bb23ae8da63ce607d70c
    Closes-Bug: #1801977
    (cherry picked from commit f65664ff56de26b6e98ffcf09001427e5a8bdaf3)

tags: added: in-stable-queens
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/tripleo-heat-templates 9.4.1

This issue was fixed in the openstack/tripleo-heat-templates 9.4.1 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/tripleo-heat-templates 8.4.1

This issue was fixed in the openstack/tripleo-heat-templates 8.4.1 release.

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.