Subject: bin/4372: init creates mfs to small for /dev
To: None <gnats-bugs@gnats.netbsd.org>
From: None <andreas@planix.com>
List: netbsd-bugs
Date: 10/28/1997 16:01:57
>Number: 4372
>Category: bin
>Synopsis: init creates mfs to small for /dev
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: bin-bug-people (Utility Bug People)
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Tue Oct 28 13:05:02 1997
>Last-Modified:
>Originator: Andreas Wrede
>Organization:
Planix, Toronto, Ontario, Canada
>Release: -current Oct 28, 1997
>Environment:
System: NetBSD wbook 1.3_ALPHA NetBSD 1.3_ALPHA (GENERIC) #2: Fri Oct 28 13:13:35 EDT 1997 root@woffi:/local1/src/netbsd-current/src/sys/arch/i386/compile/GENERIC i386
>Description:
Init uses mount_mfs to create a memory filesystem for /dev when the root
partition is mounted on a msdos fs and there is a file MAKEDEV in /dev. The
filesystem is created with to few inodes to accomodate all the devices
created by a 'MAKEDEV all'.
>How-To-Repeat:
>Fix:
The patch below causes init to create a filesystem with 700+ inodes and
67bk space. 'MAKEDEV all' uses 446 inodes and 18kb blocks.
*** src/sbin/init/init.c.orig Wed Jul 30 07:41:50 1997
--- src/sbin/init/init.c Tue Oct 28 13:39:40 1997
***************
*** 1395,1402 ****
/* Mount an mfs over /dev so we can create devices */
switch ((pid = fork())) {
case 0:
! (void) execl("/sbin/mount_mfs", "mount_mfs", "-i", "18000",
! "-s", "192", "-b", "4096", "-f", "512", "swap", "/dev",
NULL);
goto done;
--- 1395,1402 ----
/* Mount an mfs over /dev so we can create devices */
switch ((pid = fork())) {
case 0:
! (void) execl("/sbin/mount_mfs", "mount_mfs", "-i", "256",
! "-s", "384", "-b", "4096", "-f", "512", "swap", "/dev",
NULL);
goto done;
>Audit-Trail:
>Unformatted:
The memory filesystem created by init to accomodate /dev when / is on
a msdos partition is to small.
>Howo-To-Repeat:
<code/input/activities to reproduce the problem (multiple lines)>
Copy dosboot.com, /bin/*, /sbin/*, /dev/MAKEDEV and /netbsd to a msdos
partition. Run 'dosboot netbsd' from a dos command prompt. Observe many
'out of inode' messages.