SHA256
1
0
forked from pool/systemd

Accepting request 144458 from home:elvigia:branches:Base:System

OBS-URL: https://build.opensuse.org/request/show/144458
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd?expand=0&rev=318
This commit is contained in:
Frederic Crozat 2012-12-07 08:12:17 +00:00 committed by Git OBS Bridge
parent 4f7edebdc7
commit 1b82a2aec2
5 changed files with 62 additions and 0 deletions

View File

@ -0,0 +1,44 @@
commit 140883405e429d9f8d3480a2701d8904f97e4a98
Author: Tom Gundersen <teg@jklm.no>
Date: Wed Nov 28 18:08:54 2012 +0100
shutdown: don't consider umounting of / and /usr failed
In the words of Homer: If you don't try, you can't fail.
This is a revert of 9279749b84cc87c7830280b7895a48bed03c9429.
It used to be necessary to consider the umounting failed to make sure /
and /usr were remounted read-only, but that is no longer necessary as
everything is now remounted read-only anyway.
Moreover, this avoids a warning at shutdown saying a filesystem was not
unmounted. As the umounting of / is never attempted there was no
corresponding warning message saying which fs that failed. This caused some
spurious bug-reports from concerned users.
Cc: Michael Biebl <biebl@debian.org>
diff --git a/src/core/umount.c b/src/core/umount.c
index e794057..5989a4c 100644
--- a/src/core/umount.c
+++ b/src/core/umount.c
@@ -433,15 +433,14 @@ static int mount_points_list_umount(MountPoint **head, bool *changed, bool log_e
}
/* Skip / and /usr since we cannot unmount that
- * anyway, since we are running from it */
+ * anyway, since we are running from it. They have already been
+ * remounte ro. */
if (path_equal(m->path, "/")
#ifndef HAVE_SPLIT_USR
|| path_equal(m->path, "/usr")
#endif
- ) {
- n_failed++;
+ )
continue;
- }
/* Trying to umount. Forcing to umount if busy (only for NFS mounts) */
if (umount2(m->path, MNT_FORCE) == 0) {

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Dec 6 22:47:09 UTC 2012 - crrodriguez@opensuse.org
- revert-of-9279749b84cc87c7830280b7895a48bed03c9429.patch:
do not consider failure to umount / and /usr an error.
-------------------------------------------------------------------
Wed Dec 5 15:13:27 UTC 2012 - fcrozat@suse.com

View File

@ -156,6 +156,8 @@ Patch68: mount-efivars.patch
Patch69: switch-root-try-pivot-root.patch
# PATCH-FIX-UPSTREAM remount-ro-before-unmount.patch fcrozat@suse.com -- remount ro before unmounting in final shutdown loop
Patch70: remount-ro-before-unmount.patch
# PATCH-FIX-UPSTREAM revert-of-9279749b84cc87c7830280b7895a48bed03c9429.patch crrodriguez@opensuse.org -- do not consider failure to umount / and /usr an error.
Patch73: revert-of-9279749b84cc87c7830280b7895a48bed03c9429.patch
# udev patches
# PATCH-FIX-OPENSUSE 0001-Reinstate-TIMEOUT-handling.patch
@ -371,6 +373,7 @@ cp %{SOURCE7} m4/
%patch70 -p1
%patch71 -p1
%patch72 -p1
%patch73 -p1
%build
autoreconf -fiv

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Dec 6 22:47:09 UTC 2012 - crrodriguez@opensuse.org
- revert-of-9279749b84cc87c7830280b7895a48bed03c9429.patch:
do not consider failure to umount / and /usr an error.
-------------------------------------------------------------------
Wed Dec 5 15:13:27 UTC 2012 - fcrozat@suse.com

View File

@ -151,6 +151,8 @@ Patch68: mount-efivars.patch
Patch69: switch-root-try-pivot-root.patch
# PATCH-FIX-UPSTREAM remount-ro-before-unmount.patch fcrozat@suse.com -- remount ro before unmounting in final shutdown loop
Patch70: remount-ro-before-unmount.patch
# PATCH-FIX-UPSTREAM revert-of-9279749b84cc87c7830280b7895a48bed03c9429.patch crrodriguez@opensuse.org -- do not consider failure to umount / and /usr an error.
Patch73: revert-of-9279749b84cc87c7830280b7895a48bed03c9429.patch
# udev patches
# PATCH-FIX-OPENSUSE 0001-Reinstate-TIMEOUT-handling.patch
@ -366,6 +368,7 @@ cp %{SOURCE7} m4/
%patch70 -p1
%patch71 -p1
%patch72 -p1
%patch73 -p1
%build
autoreconf -fiv