[initscripts/f14/master] Fix umount on halt

Bill Nottingham notting at fedoraproject.org
Thu Aug 26 17:28:40 UTC 2010


commit 98e69fe5400f703785bd8bb9e4d5279a2d97fcd9
Author: Bill Nottingham <notting at redhat.com>
Date:   Thu Aug 26 13:27:42 2010 -0400

    Fix umount on halt

 cgroup.diff      |   28 ++++++++++++++++++++++++++++
 initscripts.spec |    7 ++++++-
 2 files changed, 34 insertions(+), 1 deletions(-)
---
diff --git a/cgroup.diff b/cgroup.diff
new file mode 100644
index 0000000..4ccbead
--- /dev/null
+++ b/cgroup.diff
@@ -0,0 +1,28 @@
+commit af1d17f1d3e213e41d9b320b5e2251118d463bd3
+Author: Bill Nottingham <notting at redhat.com>
+Date:   Thu Aug 26 13:25:36 2010 -0400
+
+    Fix umount on halt for new cgroup location. (#612789)
+
+diff --git a/rc.d/init.d/halt b/rc.d/init.d/halt
+index a19c76f..cb33cbe 100755
+--- a/rc.d/init.d/halt
++++ b/rc.d/init.d/halt
+@@ -138,7 +138,7 @@ __umount_loop '$3 ~ /^rpc_pipefs$/ || $3 ~ /^rpc_svc_gss_pipefs$/ {print $2}' \
+     $"Unmounting pipe file systems (retry): " \
+     -f
+ 
+-LANG=C __umount_loop '$2 ~ /^\/$|^\/proc|^\/cgroup|^\/dev/{next}
++LANG=C __umount_loop '$2 ~ /^\/$|^\/proc|^\/cgroup|^\/sys\/fs\/cgroup|^\/dev/{next}
+ 	$3 == "tmpfs" || $3 == "proc" {print $2 ; next}
+ 	/(loopfs|autofs|nfs|cifs|smbfs|ncpfs|sysfs|^none|^\/dev\/ram|^\/dev\/root$)/ {next}
+ 	{print $2}' /proc/mounts \
+@@ -155,7 +155,7 @@ rm -f /.autofsck
+ 
+ # Try all file systems other than root, essential filesystems and RAM disks,
+ # one last time.
+-awk '$2 !~ /\/(|dev|proc|selinux|cgroup|sys)$/ && $1 !~ /^\/dev\/ram/ { print $2 }' \
++awk '$2 !~ /\/(|dev|proc|selinux|cgroup|sys)$/ && $1 !~ /(^\/dev\/ram|cgroup)/ { print $2 }' \
+     /proc/mounts | sort -r | \
+   while read line; do
+     fstab-decode $UMOUNT -f $line
diff --git a/initscripts.spec b/initscripts.spec
index 9e8fd38..d27d09f 100644
--- a/initscripts.spec
+++ b/initscripts.spec
@@ -6,7 +6,7 @@ Version: 9.17
 # ppp-watch is GPLv2+, everything else is GPLv2
 License: GPLv2 and GPLv2+
 Group: System Environment/Base
-Release: 1%{?dist}
+Release: 2%{?dist}
 URL: http://fedorahosted.org/releases/i/n/initscripts/
 Source: http://fedorahosted.org/releases/i/n/initscripts/initscripts-%{version}.tar.bz2
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
@@ -46,6 +46,7 @@ Requires(pre): /usr/sbin/groupadd
 Requires(post): /sbin/chkconfig, coreutils
 Requires(preun): /sbin/chkconfig
 BuildRequires: glib2-devel popt-devel gettext pkgconfig
+Patch0: cgroup.diff
 
 %description
 The initscripts package contains the basic system scripts used to boot
@@ -66,6 +67,7 @@ Currently, this consists of various memory checking code.
 
 %prep
 %setup -q
+%patch0 -p1
 
 %build
 make
@@ -242,6 +244,9 @@ rm -rf $RPM_BUILD_ROOT
 /etc/profile.d/debug*
 
 %changelog
+* Thu Aug 26 2010 Bill Nottingham <notting at redhat.com> - 9.17-2
+- halt: fix umount on halt for new cgroup location. (#612789)
+
 * Wed Aug 25 2010 Bill Nottingham <notting at redhat.com> - 9.17-1
 - init.d/functions: redirect start/stop/condrestart/etc to systemctl in a systemd environment (#612728)
 - rc.sysinit: don't frob the console loglevel on boot (#621257, #626572)


More information about the scm-commits mailing list