I have a file test.txt at:

./a/test.txt                    (1 KB, old one)
./unionWritableFolder/test.txt  (2 KB, should be overriding)
./unionMergedFolder/test.txt    (1 KB, old one)

if I do this:

echo 3 | sudo -k tee /proc/sys/vm/drop_caches

the newest modified file on an AUFS unionMergedFolder will be the correct one:


Otherwise it will keep showing the old file: ./a/test.txt

It is like the cache is not being updated? I don't really understand what is going on. Is there some way to make the cache work properly? so I don't need to drop it all the time?

P.S.: I don't intend to stop using AUFS as it is very good to understand and use, very user friendly.

  • By the way, you probably don't need to say ./directory_name/file_name — you use ./file_name for a file in the current directory; otherwise, directory_name/file_name should work fine. Jan 29, 2017 at 2:47
  • @G-Man the problem is that I need to access it thru ./unionMergedFolder/test.txt, actually the application will look for that file, it doesnt know about the other directories. Jan 29, 2017 at 2:55
  • But have you tried saying unionMergedFolder/test.txt instead? Jan 29, 2017 at 2:57
  • @G-Man that would be on a terminal, with ./ or without. The application probably uses relative path and is failing. Anyway, using nautlius F5 I see no changes on the file, unless I drop caches, when also the application will access the new file. Jan 29, 2017 at 3:57
  • 1
    Hmm, if writing to vm/drop_caches has any observable effect other than performance, that's surely a bug somewhere. Jan 29, 2017 at 22:54

1 Answer 1


Answering to: 'Is there some way to make the cache work properly?' (well to actually make aufs writes work properly)

when mounting the aufs, it seems to ONLY work properly if we use -o sync toguether with br like in -o sync,br="..."

now it is finally working great concerning making write updates ready, even timestamps!

PS.: The problem still happens at ubuntu 16.04, making sync required.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.