Ticket #6513 (closed defect: fixed)
Deleting directories on shared folder fails with EBUSY => Fixed in SVN
|Reported by:||foobar42||Owned by:|
Host is Linux with ext3/ext4, guest is Solaris 10u8. Doing 'rm -rf ...' on the Solaris guest on a directory in a shared folder deletes all files, but leaves a bunch of folders; usually (but not always) it prints out errors like
rm: Unable to remove directory <directory>: Device busy
Trying to 'rmdir' those directories sometimes succeeds and sometimes fails with a similar error:
rmdir: directory "<directory>": Directory is a mount point or in use
<pid>: rmdir("<directory>") Err#16 EBUSY
The easiest way to reproduce this is probably to unpack some tar or zip with a bunch of directories and files, and then try to 'rm -rf' it again.
It seems like VB itself may be keeping the directories busy, because A) 'lsof' and 'fuser' show nobody using them, B) running 'rmdir' several times it may fail a few times and then suddenly succeed, and C) using wildcards I can almost never delete subdirectories (i.e. 'rmdir dir/*'), but if I wait a bit and delete them individually ('rmdir dir/a') then they usually succeed.
Note that 'rm -rf' always successfully deletes all files - it's just the directories that have issues.