Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 10 Oct 2009 12:37:42 -0700
From:      David Ehrmann <ehrmann@gmail.com>
To:        freebsd-current@freebsd.org
Subject:   Strange md/unionfs issue
Message-ID:  <4AD0E286.9030508@gmail.com>

next in thread | raw e-mail | index | archive | help
I have a system running on a flash disk.  To prevent it from wearing out 
quickly, I don't run with a swap and mount /tmp and /var from memory.  
Because /var needs some directories and contains files I probably should 
save from time to time, I mount it from flash, mount /var to /var_real 
so I can access the underlying files, and then I mount an md device on 
top of /var as a unionfs.  Initially, it seems to work, but seconds 
later, the unionfs seems to fail.

server# cd /var
server# ls
.snap           crash           heimdal         preserve        yp
account         cron            log             run
at              db              mail            rwho
audit           empty           msgs            spool
backups         games           named           tmp
server# mount
/dev/ad0s1a on / (ufs, NFS exported, local)
devfs on /dev (devfs, local, multilabel)
/dev/ad0s1f on /usr (ufs, local, soft-updates)
/dev/ad0s1e on /var (ufs, local, soft-updates)
/var on /var_real (nullfs, local, noatime)
/dev/md0 on /var (ufs, local, union, soft-updates)
/dev/md1 on /tmp (ufs, local, soft-updates)
server# cd /var_real/
server# ls
.snap           crash           heimdal         preserve        yp
account         cron            log             run
at              db              mail            rwho
audit           empty           msgs            spool
backups         games           named           tmp
server# cd /var
server# ls
.snap
server#

Removing /var_real from the fstab didn't help.  Here's the full version:

# Device                Mountpoint      FStype  Options         Dump    
Pass#
/dev/ad0s1a             /               ufs     rw              1       1
/dev/ad0s1f             /usr            ufs     rw              2       2

/dev/ad0s1e             /var            ufs     rw              2       2
/var                    /var_real       nullfs  rw,noatime
md                      /var            mfs     rw,union,-s128M

md                      /tmp            mfs     rw,-s128M

Ideas?




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4AD0E286.9030508>