forked from pool/systemd
ba9b55aa79
1 OBS-URL: https://build.opensuse.org/request/show/262952 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd?expand=0&rev=209
28 lines
1.1 KiB
Diff
28 lines
1.1 KiB
Diff
Based on d89b5fed9ea5d9ec293585cb85bb27b56ea6ac9c Mon Sep 17 00:00:00 2001
|
|
From: Michal Sekletar <msekleta@redhat.com>
|
|
Date: Tue, 21 Oct 2014 18:38:42 +0200
|
|
Subject: [PATCH] shutdown: do final unmounting only if not running inside the
|
|
container
|
|
|
|
If we run in the container then we run in a mount namespace. If namespace dies
|
|
then kernel should do unmounting for us, hence we skip unmounting in containers.
|
|
|
|
Also, it may be the case that we no longer have capability to do umount,
|
|
because we are running in the unprivileged container.
|
|
|
|
See: http://lists.freedesktop.org/archives/systemd-devel/2014-October/023536.html
|
|
---
|
|
src/core/shutdown.c | 2 +-
|
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
|
--- src/core/shutdown.c
|
|
+++ src/core/shutdown.c 2014-10-29 14:18:38.767837898 +0000
|
|
@@ -278,6 +278,7 @@ int main(int argc, char *argv[]) {
|
|
broadcast_signal(SIGKILL, true, false);
|
|
|
|
if (in_container) {
|
|
+ need_umount = false;
|
|
need_swapoff = false;
|
|
need_dm_detach = false;
|
|
need_loop_detach = false;
|