NetBSD Problem Report #2423

From gnats  Thu May 16 12:39:13 1996
Received: from by (8.7.4/8.6.12) with ESMTP id MAA07350 for <>; Thu, 16 May 1996 12:11:20 -0400 (EDT)
Message-Id: <>
Date: Thu, 16 May 1996 18:06:11 +0200 (MET DST)
From: Andrew Wheadon <>
Subject: bugs in union-mounts
X-Send-Pr-Version: 3.95

>Number:         2423
>Category:       kern
>Synopsis:       union mounts panic when unmounting, panic when done twice
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu May 16 12:50:03 +0000 1996
>Last-Modified:  Mon Jun 05 22:28:14 +0000 2000
>Originator:     Andrew Wheadon
>Release:        19960515
The cost of living hasn't affected it's popularity. (Mark Twain)
current	release=doc \ "NetBSD-current mirror"
hostbase=/mit/ftp/pub/NetBSD base=/usr prefix=/usr backup delete use-rel-suffix

System: NetBSD wipux2 1.1B NetBSD 1.1B (WIPOOL) #0: Thu May 16 14:57:24 MET DST 1996 toor@wipux2:/src/src/sys/arch/i386/compile/WIPOOL i386

three bugs:	1) panics when unmounting, 2) allows double-mounting,
		which is followed by panic on access, 3) no dependencies
		explained when compiling kernel.
one nicety:	4) union-mounts are not nfs-exportable

	Union mounts panic when trying to unmount them:
mount -t union -o -b /src2/boot/wippc00 /src2/boot/wippc51
ls /src2/boot/wippc51
umount /src2/boot/wippc51
	syscall (22)

	Union mounts are easily mounted twice over each other:

mount /src2/boot/wippc53
mount /src2/boot/wippc53
(this is the output of 'mount')
/dev/sd1g on /src2 type ffs (NFS exported, local)
<below>:/src2/boot/wippc00 on /src2/boot/wippc51 type union
<below>:/src2/boot/wippc00 on /src2/boot/wippc53 type union
<below>:/src2/boot/wippc00 on /src2/boot/wippc55 type union
<below>:/src2/boot/wippc00 on /src2/boot/wippc53 type union

	and when you then try to ls /src2/boot/wippc53 it (naturally)
	panic locking against myself
	syscall (196)
	(I have the (11mb compressed) core-dump for this one)

	When compiling the Kernel and setting 'option UNION', unions
	will still fail to mount. At least one of the following additional
	options are needed to compile a kernel that supports UNION
	NULLFS,UMAPFS (probably NULLFS) but dependency is not defined
	in files*.

<root@wipux2:/src2/boot> mount -v -t nfs wipux2:/src2/boot /mnt
wipux2:/src2/boot on /mnt type nfs
<root@wipux2:/src2/boot> ls /mnt/wippc53
.s      dev/    home/   root/   src2/   usr/
bin/    etc/    mnt/    sbin/   tmp/    var/
<root@wipux2:/src2/boot> mount
<below>:/src2/boot/wippc00 on /src2/boot/wippc53 type union
wipux2:/src2/boot on /mnt type nfs
<root@wipux2:/src2/boot> umount /mnt
<root@wipux2:/src2/boot> mount -v -t nfs wipux2:/src2/boot/wippc53 /mnt
nfs: can't access /src2/boot/wippc53: Permission denied
<root@wipux2:/src2/boot> umount /mnt

As you can tell mounting /src2/boot lets me see the file but
ignores the union, and just shows me truely local files. (ie. the kernel
file on wippc00/netbsd is not listed etc.)
Trying to mount the union-directory fails completely.

	see above.
	1)	??? 
	2)	Do NOT permit mounting same stuff in same place twice.
	3)	somehow add dependencies for config.
	4)	???

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD:,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.