/var/log bind mount overshadows /var/log/journal bindmount in lxc container setup

Bug #1895533 reported by Jocelyn Thode
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack-Ansible
Fix Released
High
Dmitriy Rabotyagov

Bug Description

Hi,

While deploying openstack with openstack-ansible 20.1.3 (stable/train) in lxc containers we ran into an issue related to logs mount points

By default when creating the containers, the role will add a bind mount so that the journald logs are sent to the host which is very useful for log collection. (see https://github.com/openstack/openstack-ansible-lxc_container_create/blob/stable/train/tasks/lxc_container_config.yml#L44)

However, this mount point is overshadowed when running a service install after having created the containers. For example running the playbook os-heat-install.yml will overshadow the mount point /var/log/journal/... due to the variable lxc_default_bind_mounts (see https://github.com/openstack/openstack-ansible/blob/stable/train/playbooks/common-tasks/os-lxc-container-setup.yml#L49)

Expected behavior would be that the more specific mount point would be mounted after the more general one to avoid overshadowing.

description: updated
Revision history for this message
Dmitriy Rabotyagov (noonedeadpunk) wrote :

I think as a workaround you can try setting `lxc_default_bind_mounts: false` in your user_variables, to omit mounting /var/log at all, while journal is supposed to be mounted anyway.

Changed in openstack-ansible:
importance: Undecided → Critical
importance: Critical → High
status: New → Triaged
assignee: nobody → Dmitriy Rabotyagov (noonedeadpunk)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to openstack-ansible (master)

Fix proposed to branch: master
Review: https://review.opendev.org/752059

Changed in openstack-ansible:
status: Triaged → In Progress
Revision history for this message
Jocelyn Thode (jocelynthode) wrote :

Hi,

do we have an ETA on when we can expect this to land in master?

Cheers

Revision history for this message
Dmitriy Rabotyagov (noonedeadpunk) wrote :

This has been landed on master and backported to stable/victoria

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

This issue was fixed in the openstack/openstack-ansible 22.0.1 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/openstack-ansible 23.0.0.0b1

This issue was fixed in the openstack/openstack-ansible 23.0.0.0b1 development milestone.

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.