Skip to content

osmount: avoid stale propagated mounts - #516

Open
petrutlucian94 wants to merge 1 commit into
cloudbase:masterfrom
petrutlucian94:avoid_leaked_mounts
Open

osmount: avoid stale propagated mounts#516
petrutlucian94 wants to merge 1 commit into
cloudbase:masterfrom
petrutlucian94:avoid_leaked_mounts

Conversation

@petrutlucian94

Copy link
Copy Markdown
Member

We'll need to prevent Coriolis mounts from being propagated to other namespaces belonging to Systemd services.

These would be leaked when running "unmount -R" in this namespace, being especially troublesome if the
minion gets reused. Stale mounts can prevent the FS from being remounted (e.g. if os-morphing gets retried).

We'll need to prevent Coriolis mounts from being propagated to other
namespaces belonging to Systemd services.

These would be leaked when running "unmount -R" in this namespace,
being especially troublesome if the
minion gets reused. Stale mounts can prevent the FS from being
remounted (e.g. if os-morphing gets retried).
# remounted (e.g. if os-morphing gets retried).
#
# The other "--make-(r)private" calls may no longer be required.
self._exec_cmd("sudo mount --make-rprivate /")

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's also the option of limiting the scope to a given directory, although that would also have to be a mount, e.g.

sudo mkdir -p /mnt/coriolis
# bind /mnt/coriolis to itself so that we can modify propagation rules
sudo mount --bind /mnt/coriolis  /mnt/coriolis
sudo mount --make-private /mnt/coriolis

But then we'd have to ensure that all Coriolis mounts go under that path and also avoid rebinding it multiple times.

For simplicity we can stick with sudo mount --make-rprivate /.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant