Bug 59562 - /initrd/dev not unmounted when initrd uses devfs
Summary: /initrd/dev not unmounted when initrd uses devfs
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: initscripts   
(Show other bugs)
Version: 7.2
Hardware: All Linux
Target Milestone: ---
Assignee: Bill Nottingham
QA Contact: Brock Organ
: 61771 (view as bug list)
Depends On:
TreeView+ depends on / blocked
Reported: 2002-02-10 13:58 UTC by W. Michael Petullo
Modified: 2014-03-17 02:25 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2002-04-12 20:45:57 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
An example linuxrc that supports devfs. (3.69 KB, text/plain)
2002-02-10 13:59 UTC, W. Michael Petullo
no flags Details

Description W. Michael Petullo 2002-02-10 13:58:17 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 Galeon/1.0.2 (X11; Linux i686; U;) Gecko/20011226

Description of problem:
/etc/rc.d/rc.sysinit trys to unmount /initrd.  However, if the initrd uses
devfs, then this unmount fails because devfs is mounted at /initrd/dev.  Since
/initrd/dev can not be mounted until after chroot executes init in the initrd
linuxrc script (following a call to pivot_root), /initrd/dev/must be unmounted
by rc.sysinit.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1.  Make an initrd that supports devfs and have its linuxrc mount devfs at /dev.
2.  Linuxrc executes pivot_root and "chroot ... init".
3.  Rc.sysinit tries to unmount /initrd but fails because /initrd/dev is a
mounted devfs.

Actual Results:  Unmount of /initrd by rc.sysinit fails.

Additional info:

Here is a patch that fixes this rc.sysinit bug:

--- /tmp/rc.sysinit     Sun Feb 10 14:36:23 2002
+++ /etc/rc.d/rc.sysinit        Sun Feb 10 14:36:39 2002
@@ -54,6 +54,9 @@

 # Unmount the initrd, if necessary
 if grep -q /initrd /proc/mounts ; then
+   if [ -e /initrd/dev/.devfsd ]; then
+      action $"Unmounting initrd devfs: " umount /initrd/dev
+   fi
    action $"Unmounting initrd: " umount /initrd
    /sbin/blockdev --flushbufs /dev/ram0 >/dev/null 2>&1

Comment 1 W. Michael Petullo 2002-02-10 13:59:28 UTC
Created attachment 45159 [details]
An example linuxrc that supports devfs.

Comment 2 Bill Nottingham 2002-04-12 20:45:53 UTC
*** Bug 61771 has been marked as a duplicate of this bug. ***

Comment 3 Bill Nottingham 2002-04-12 20:48:11 UTC
devfs is not supported, but the code will be added in 6.63-1.

Note You need to log in before you can comment on or make changes to this bug.