[Pkg-sysvinit-devel] Bug#597338: Do not unmount virtual/kernel fs as it breaks shutdown/reboot when using systemd

Michael Biebl biebl at debian.org
Sat Sep 18 18:47:24 UTC 2010


Package: initscripts
Version: 2.88dsf-12
Severity: normal
Tags: patch

Hi,

systemd is a new init systemd, which makes use of cgroups to track
running processes.
The cgroupfs is mounted below /sys/fs/cgroup as shown below:

$ mount | grep cgroup
tmpfs on /sys/fs/cgroup type tmpfs (rw,noexec,nosuid,nodev,relatime,mode=755)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,noexec,nosuid,nodev,relatime,release_agent=/lib/systemd/systemd-cgroups-agent,name=systemd)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,noexec,nosuid,nodev,relatime,cpuset) 
cgroup on /sys/fs/cgroup/ns type cgroup (rw,noexec,nosuid,nodev,relatime,ns)
cgroup on /sys/fs/cgroup/cpu type cgroup (rw,noexec,nosuid,nodev,relatime,cpu)
cgroup on /sys/fs/cgroup/cpuacct type cgroup (rw,noexec,nosuid,nodev,relatime,cpuacct)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,noexec,nosuid,nodev,relatime,devices)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,noexec,nosuid,nodev,relatime,freezer)
cgroup on /sys/fs/cgroup/net_cls type cgroup (rw,noexec,nosuid,nodev,relatime,net_cls)

/etc/init.d/umountfs tries to unmount those file systems on shutdown. As
systemd still uses them, it fails, which results in error messags during
reboot/shutdown.

I discussed this with Tollef (Debian systemd maintainer) and Kay Sievers
(udev and systemd upstream developer).

We came to the conclusion that virtual/kernel file systems
should not be unmounted at all, as there is no good reason to do so.
The attached patch does just that. It skips all mount points below
/sys/*

I've been using this patch for some time now without any problems.

Please consider applying it in the next upload.

Thanks,
Michael


-- System Information:
Debian Release: squeeze/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (1, 'experimental')
Architecture: i386 (i686)

Kernel: Linux 2.6.32-5-686 (SMP w/1 CPU core)
Locale: LANG=de_DE.utf8, LC_CTYPE=de_DE.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages initscripts depends on:
ii  coreutils                     8.5-1      GNU core utilities
ii  debianutils                   3.4        Miscellaneous utilities specific t
ii  libc6                         2.11.2-6   Embedded GNU C Library: Shared lib
ii  lsb-base                      3.2-23.1   Linux Standard Base 3.2 init scrip
ii  mount                         2.17.2-3.1 Tools for mounting and manipulatin
ii  sysv-rc                       2.88dsf-12 System-V-like runlevel change mech
ii  sysvinit-utils                2.88dsf-12 System-V-like utilities

Versions of packages initscripts recommends:
ii  e2fsprogs                     1.41.12-2  ext2/ext3/ext4 file system utiliti
ii  psmisc                        22.13-1    utilities that use the proc file s

initscripts suggests no packages.

-- Configuration Files:
/etc/init.d/reboot changed [not included]
/etc/init.d/sendsigs changed [not included]
/etc/init.d/umountfs changed [not included]

-- no debconf information
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dont_unmount_virtual_and_kernel_fs_under_sys.patch
Type: text/x-diff
Size: 564 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-sysvinit-devel/attachments/20100918/8a898a47/attachment.patch>


More information about the Pkg-sysvinit-devel mailing list