On a workstation where <samba_source> is mounted on a tmpfs I have this error: failure: readdir [ Failed for rmdir - 39 = Directory not empty ] in samba4.local.replace and in samba4.raw.search with Testing OS/2 style delete on 700 files error: samba4.raw.search.deleted 352 - expected to delete 700 [ _StringException: _StringException: No reason specified ] time: 2011-11-05 12:34:43.933537Z error: samba4.raw.search.os2 delete [ _StringException: _StringException: Unknown error/failure ] If it's only <samba_source>/st that is mounted on tmpfs volume then it's just samba4.raw.search that is having problem. This is due to the fact that samba4.local.replace create the temporary dir in <samba_source> rather than in <samba_source>/st. To reproduce: ./source4/scripting/devel/tmpfs.sh make test TESTS=samba4.raw.search or cd st; ../bin/smbtorture //localhost local.replace I'm pretty sure that the problem boils down to the os2_delete function that behave strangely in a tmpfs volume.
This is know, if you want to use non disk storage try to create a large file in /dev/shm/ and format it as ext4 and loop mount it.
As I recall, this is considered to be a kernel bug, due to the way readdir works on tmpfs. Implementing OS/2 compatible directory listing (with deletes during that list) is dependent on very, very specific readdir semantics.
The answer of metze is quite satisfying, I think we should eventually fix the script/devel/tmpfs to use a block of shm backed by a loop device.