Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 18 Feb 1999 17:00:10 +0000
From:      Tony Finch <dot@dotat.at>
To:        freebsd-stable@freebsd.org
Subject:   mount -o union broken recently?
Message-ID:  <E10DWo6-0003QE-00@fanf.noc.demon.net>

next in thread | raw e-mail | index | archive | help
I have been experimenting with union mounts today with a recent
-stable (cvsupped yesterday), and I haven't had much luck.

Because cvsup likes to obliterate local changes, I thought it would be
convenient to keep the altered files on a separate filesystem and use
a union mount to overlay them on the upstream source when I compile
things. So:

# mount
/dev/da0s1a on / (local, writes: sync 420 async 3185)
procfs on /proc (local)
/dev/da0s1e on /www (local, writes: sync 2 async 0)
# mount /dev/da0s1f /srcdelta
# ls -l /srcdelta
total 1
drwxr-xr-x   6 root     wheel         512 Feb 18 10:32 sys
# umount /srcdelta
# ls /usr/src
COPYRIGHT         UPDATING          include           share
CVS               bin               kerberosIV        sys
Makefile          contrib           lib               tools
Makefile.inc0     crypto            libexec           usr.bin
Makefile.inc1     etc               release           usr.sbin
Makefile.upgrade  games             sbin
README            gnu               secure
# mount -o union /dev/da0s1f /usr/src
# ls -l /usr/src
total 1
drwxr-xr-x   6 root     wheel         512 Feb 18 10:32 sys
# umount /usr/src
# uname -a
FreeBSD shirt.www.demon.net 3.1-STABLE FreeBSD 3.1-STABLE #6: Thu Feb 18 02:26:59 GMT 1999     root@shirt.www.demon.net:/usr/src/sys/compile/SHIRT  i386
#

However, on another machine running 3.0-RELEASE mount -o union works
as expected:

# ls -l
total 6
drwxr-xr-x   2 root     wheel         512 Feb 18 16:36 da1
drwxr-xr-x   2 root     wheel         512 Dec 11 11:06 da2
# mount /dev/da1s1e da1
# mount /dev/da2s1e da2
# ls -l da?/*
-rw-r--r--   1 root     wheel           0 Feb 18 16:36 da1/this_is_da1
-rw-r--r--   1 root     wheel           0 Feb 18 16:36 da2/this_is_da2
# umount da2
# mount -o union /dev/da2s1e /www/da1
# ls -l da?/*
-rw-r--r--   1 root     wheel           0 Feb 18 16:36 da1/this_is_da1
-rw-r--r--   1 root     wheel           0 Feb 18 16:36 da1/this_is_da2
#

Shirt's kernel configuration is below.

Tony.
-- 
f.a.n.finch  dot@dotat.at  fanf@demon.net


machine		"i386"
cpu		"I686_CPU"
ident		SHIRT
maxusers	64

options		INET			#InterNETworking
options		FFS			#Berkeley Fast Filesystem
options		FFS_ROOT		#FFS usable as root device [keep this!]
options		MFS			#Memory Filesystem
#options	MFS_ROOT		#MFS usable as root device, "MFS" req'ed
options		NFS			#Network Filesystem
options		NFS_NOSERVER
#options	NFS_ROOT		#NFS usable as root device, "NFS" req'ed
options		MSDOSFS			#MSDOS Filesystem
#options	"CD9660"		#ISO 9660 Filesystem
#options	"CD9660_ROOT"		#CD-ROM usable as root. "CD9660" req'ed
options		PROCFS			#Process filesystem
options		"COMPAT_43"		#Compatible with BSD 4.3 [KEEP THIS!]
options		SCSI_DELAY=1000		#Be pessimistic about Joe SCSI device
options		UCONSOLE		#Allow users to grab the console
options		USERCONFIG		#boot -c editor
options		VISUAL_USERCONFIG	#visual boot -c editor

options		NETALIAS
options		NETBIND
options		SOFTUPDATES

options         "MAXMEM=(64*1024)"
options		PQ_MEDIUMCACHE
options		INCLUDE_CONFIG_FILE
options		PERFMON

options		IPFIREWALL
options		IPFIREWALL_VERBOSE
options		IPFIREWALL_DEFAULT_TO_ACCEPT

options		ICMP_BANDLIM

options		DUMMYNET

config		kernel	root on wd0

controller	isa0
controller	eisa0
controller	pci0

controller	fdc0	at isa? port "IO_FD1" bio irq 6 drq 2
disk		fd0	at fdc0 drive 0
#disk		fd1	at fdc0 drive 1

options		"CMD640"	# work around CMD640 chip deficiency
controller	wdc0	at isa? port "IO_WD1" bio irq 14
disk		wd0	at wdc0 drive 0

options		ATAPI		#Enable ATAPI support for IDE bus
options		ATAPI_STATIC	#Don't do it as an LKM
device		acd0		#IDE CD-ROM

controller	ncr0

controller	scbus0

device		da0

device		pass0

device		cd0	#Only need one of these, the code dynamically grows

# atkbdc0 controlls both the keyboard and the PS/2 mouse
controller	atkbdc0	at isa? port IO_KBD tty
device		atkbd0	at isa? tty irq 1
device		psm0	at isa? tty irq 12

device		vga0	at isa? port ? conflicts

# splash screen/screen saver
#pseudo-device	splash
#options	VM86
#options	VESA

# syscons is the default console driver, resembling an SCO console
device		sc0	at isa? tty

device		npx0	at isa? port IO_NPX irq 13

# Laptop support (see LINT for more options)
#
device		apm0    at isa?	disable	flags 0x31 # Advanced Power Management

# serial port
device		sio0	at isa? port "IO_COM1" flags 0x10 tty irq 4
device		sio1	at isa? port "IO_COM2" tty irq 3

# Parallel port
device		ppc0	at isa? port? net irq 7
controller	ppbus0
device		nlpt0	at ppbus?
device		plip0	at ppbus?
device		ppi0	at ppbus?
#controller	vpo0	at ppbus?

# Order is important here due to intrusive probes, do *not* alphabetize
# this list of network interfaces until the probes have been fixed.
# Right now it appears that the ie0 must be probed before ep0. See
# revision 1.20 of this file.
device tl0
device tx0

pseudo-device	loop
pseudo-device	ether
pseudo-device	sl	1
pseudo-device	ppp	1
pseudo-device	tun	1
pseudo-device	pty	32
pseudo-device	gzip		# Exec gzipped a.out's
pseudo-device	vn

# KTRACE enables the system-call tracing facility ktrace(2).
# This adds 4 KB bloat to your kernel, and slightly increases
# the costs of each syscall.
options		KTRACE		#kernel tracing

# This provides support for System V shared memory and message queues.
#
options		SYSVSHM
options		SYSVMSG

#  The `bpfilter' pseudo-device enables the Berkeley Packet Filter.  Be
#  aware of the legal and administrative consequences of enabling this
#  option.  The number of devices determines the maximum number of
#  simultaneous BPF clients programs runnable.
pseudo-device	bpfilter 4	#Berkeley packet filter



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-stable" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E10DWo6-0003QE-00>