Hi,

first of all, I am very happy for the existence of aufs, it fits nicely 
with the diskless networks I've setup at my customers. Unfortunately I 
have stumbled upon an error, which, even after long analysis, I could 
not find a solution for, so I humbly ask for help.

The Problem:

Sometimes I loose all mounted filesystems on the client, except for the 
aufs mounted root. It is reproducible by triggering a tab filename 
completion in bash, it can mostly be prevented by doing an ls on the 
aufs mount before switching root at startup. Sometimes, with no clear 
evidence on what provoked it, all mounts are lost anyways. Using X11, 
OpenOffice, Firefox and Thunderbird is apparently usually safe, 
especially work on the command line seems to trigger it.

The Error:
Pressing ls /pro followed by the tab key (or /hom or /us or /var)
All mounted filesystems are empty afterwards

The Kludge:
Putting ls /root > /dev/null in initramfs
Filename completion is mostly safe in booted system

The Setup:

Debian Squeeze Server, custom kernel 3.6.10 (or 2.6.26 in another setup)
with kernel-mode NFSv3 exports.

Debian Squeeze clients, custom kernel 3.6.6 (3.6.10 in another setup) 
with aufs 3.6-20121112 as a module built with aufs3-standalone.git tree.

Root mounting is done in a initramfs, custom script ( 
http://pastebin.com/2WB5dNXA )

/bin/mount -t tmpfs -o size=16M none /aufs/xino
/bin/mount -t nfs -o rw,${NFSOPTS} ${SERVER}:/target/export/${HOSTNAME} 
/aufs/private
/bin/mount -t nfs -o ro,${NFSOPTS} ${SERVER}:/target/export/clients 
/aufs/clients
/bin/mount -t nfs -o ro,${NFSOPTS} ${SERVER}:/target/ /aufs/server
/bin/mount -t aufs -o 
noplink,xino=/aufs/xino/root,dirs=/aufs/private=rw:/aufs/clients=ro+wh:/aufs/server=ro
 
none ${TARGET}

# HERE IS THE KLUDGE WORKING SOMEWHAT
ls /target > /dev/null

/bin/mount --move /aufs/xino ${TARGET}/aufs/xino
/bin/mount --move /aufs/private ${TARGET}/aufs/private
/bin/mount --move /aufs/clients ${TARGET}/aufs/clients
/bin/mount --move /aufs/server ${TARGET}/aufs/server
/bin/mount --move /sys ${TARGET}/sys
/bin/mount --move /proc ${TARGET}/proc

exec /bin/run-init ${TARGET} /sbin/init "$@" <${TARGET}/dev/console 
 >${TARGET}/dev/console

This appears similar to the observation of Jochen Rill
http://sourceforge.net/mailarchive/message.php?msg_id=29515546

Trace of error  ("ls /root" not done in initramfs)
http://pastebin.com/gRVtxNfS

Trace of no error ("ls /root" done in initramfs)
http://pastebin.com/KmtBD32H

Debugging option of aufs produces lots of output, mainly of the form:

Jan 24 13:37:59 hti13 kernel: aufs au_do_h_d_reval:773:klogd[681]: DEBUG: b2
Jan 24 13:37:59 hti13 kernel: aufs h_d_revalidate:838:klogd[681]: DEBUG: 
b2, lo

Full debug log while error is produced can be found here (large file, 46 
MB):
https://docs.google.com/file/d/0B0s7uiDVoB3OV09wNXZrM0Uyc2s/edit?usp=sharing

If you need any further data I would be more than willing to provide it.

Eibo Thieme


/proc/mounts
===
rootfs / rootfs rw 0 0
none /sys sysfs rw,nosuid,nodev,noexec,relatime 0 0
none /proc proc rw,nosuid,nodev,noexec,relatime 0 0
none /aufs/xino tmpfs rw,relatime,size=16384k 0 0
192.168.0.1:/target/export/hti13/ /aufs/private nfs 
rw,relatime,vers=3,rsize=32768,wsize=32768,namlen=255,hard,nolock,proto=udp,timeo=11,retrans=10,sec=sys,mountaddr=192.168.0.1,mountvers=3,mountport=58461,mountproto=udp,local_lock=all,addr=192.168.0.1
 
0 0
192.168.0.1:/target/export/clients/ /aufs/clients nfs 
ro,relatime,vers=3,rsize=32768,wsize=32768,namlen=255,hard,nolock,proto=udp,timeo=11,retrans=10,sec=sys,mountaddr=192.168.0.1,mountvers=3,mountport=58461,mountproto=udp,local_lock=all,addr=192.168.0.1
 
0 0
192.168.0.1:/target/ /aufs/server nfs 
ro,relatime,vers=3,rsize=32768,wsize=32768,namlen=255,hard,nolock,proto=udp,timeo=11,retrans=10,sec=sys,mountaddr=192.168.0.1,mountvers=3,mountport=58461,mountproto=udp,local_lock=all,addr=192.168.0.1
 
0 0
none / aufs rw,relatime,si=6709df6d,noplink 0 0
tmpfs /lib/init/rw tmpfs rw,nosuid,relatime,mode=755 0 0
varrun /var/run tmpfs rw,nosuid,relatime,mode=755 0 0
varlock /var/lock tmpfs rw,nosuid,nodev,noexec,relatime 0 0
tmpfs /dev tmpfs rw,relatime,size=10240k,mode=755 0 0
tmpfs /dev/shm tmpfs rw,nosuid,nodev,relatime 0 0
devpts /dev/pts devpts rw,nosuid,noexec,relatime,gid=5,mode=620 0 0
192.168.0.1:/target/usr/ /usr nfs 
rw,noatime,vers=3,rsize=1048576,wsize=1048576,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=192.168.0.1,mountvers=3,mountport=58461,mountproto=udp,local_lock=none,addr=192.168.0.1
 
0 0
192.168.0.1:/target/var/ /aufs/server-var nfs 
ro,noatime,vers=3,rsize=1048576,wsize=1048576,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=192.168.0.1,mountvers=3,mountport=58461,mountproto=udp,local_lock=none,addr=192.168.0.1
 
0 0
192.168.0.1:/target/export/var/hti13/ /aufs/client-var nfs 
rw,noatime,vers=3,rsize=1048576,wsize=1048576,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=192.168.0.1,mountvers=3,mountport=58461,mountproto=udp,local_lock=none,addr=192.168.0.1
 
0 0
192.168.0.1:/target/export/tmp/hti13/ /tmp nfs 
rw,noatime,vers=3,rsize=1048576,wsize=1048576,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=192.168.0.1,mountvers=3,mountport=58461,mountproto=udp,local_lock=none,addr=192.168.0.1
 
0 0
192.168.0.1:/target/export/swaps/hti13/ /swap nfs 
rw,noatime,vers=3,rsize=1048576,wsize=1048576,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=192.168.0.1,mountvers=3,mountport=58461,mountproto=udp,local_lock=none,addr=192.168.0.1
 
0 0
192.168.0.1:/home/ /home nfs 
rw,noatime,vers=3,rsize=1048576,wsize=1048576,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=192.168.0.1,mountvers=3,mountport=58461,mountproto=udp,local_lock=none,addr=192.168.0.1
 
0 0

/sys/module/aufs/*
===
coresize
   204507
initsize
   0
initstate
   live
refcnt
   31
srcversion
   B884E6E7F16C3A1C018E993
taint
   O
uevent
   cat: uevent: Keine Berechtigung
version
   3.6-20121112
parameters/brs
   1
parameters/debug
   0
sections/__bug_table
   0xf89a040f
sections/__ex_table
   0xf89a2fc0
sections/__param
   0xf899c1bc

/sys/fs/aufs
===
config
   CONFIG_AUFS_FS=m
   CONFIG_AUFS_BRANCH_MAX_127=y
   CONFIG_AUFS_SBILIST=y
   CONFIG_AUFS_DEBUG=y
si_6709df6d/br0
   /aufs/private=rw
si_6709df6d/br1
   /aufs/clients=ro+wh
si_6709df6d/br2
   /aufs/server=ro
si_6709df6d/xi_path
   /aufs/xino/root
si_67260e6d/br0
   /aufs/client-var=rw
si_67260e6d/br1
   /aufs/server-var=ro
si_67260e6d/xi_path
   /aufs/xino/var

client kernel config
===
=> http://pastebin.com/DEd7NbzZ

config.mk
===
# Kconfig
# instead of setting 'n', leave it blank when you disable it.
CONFIG_AUFS_BRANCH_MAX_127 = y
CONFIG_AUFS_BRANCH_MAX_511 =
CONFIG_AUFS_BRANCH_MAX_1023 =
#CONFIG_AUFS_BRANCH_MAX_32767 =
CONFIG_AUFS_SBILIST = y
CONFIG_AUFS_HNOTIFY = y
CONFIG_AUFS_HFSNOTIFY =
CONFIG_AUFS_EXPORT =
CONFIG_AUFS_RDU =
CONFIG_AUFS_PROC_MAP =
CONFIG_AUFS_SP_IATTR =
CONFIG_AUFS_SHWH =
CONFIG_AUFS_BR_RAMFS =
CONFIG_AUFS_BR_FUSE =
CONFIG_AUFS_BR_HFSPLUS =
CONFIG_AUFS_DEBUG = y
CONFIG_AUFS_MAGIC_SYSRQ =
CONFIG_AUFS_BDEV_LOOP =
CONFIG_AUFS_INO_T_64 =
CONFIG_AUFS_POLL =


------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_d2d_feb

Reply via email to