I just tried to mount two folders in one using aufs on Debian 7 wheezy. The command I issued is the following:mkdir /test1mkdir /test2mkdir /testmount -t aufs -o dirs=/test1:/test2 none /testThen I wanted to see if files with the same name would conflict in the same folder, so I issued this:touch /test1/file1.txttouch /test2/file1.txtecho A >/test1/file1.txtecho B >/test2/file1.txtThe result is that /test contains only file1.txt containing the letter B (which means it is the file1.txt contained in /test2). How can the files not conflict? And which criteria does aufs use to choose which file to show if they have the same name?
Do files with equal name conflict in unionfs (aufs)?
debian;filesystems;aufs
Each underlying filesystem is assigned a precedence. If there are duplicate filenames, the one from the higher precedence filesystem is the visible one, the others are hidden.See https://superuser.com/questions/326190/how-does-unionfs-work