I am trying to delete a directory.
rm -rf bla
rm: cannot remove ‘bla’: Directory not empty
It looks empty. I have also tried rmdir
.
The ownership and groups looks fine. In fact, the directory was created by a tool I just ran.
drwxrwsr-x 2 me mygroup 4096 Oct 20 17:59 bla
I have changed permissions to chmod 777 bla
, but I still cannot delete it.
I am on a cluster and do not have sudo rights. The file itself is not in any special system location or anything.
ls -a bla/
, without the final asterisk, since it won't match dotfiles – ilkkachu Oct 20 '21 at 20:34find bla -ls
. I doubt it, but is there a file system which will deny deleting a directory until all deleted files/directories are unlinked? – Bib Oct 20 '21 at 20:45bla
a directory on an NFS filesystem? If so - and only if so - please take a look at https://unix.stackexchange.com/q/348315/100397 (the error message won't apply, but the symptoms and solution might) – Chris Davies Oct 20 '21 at 21:31"There is an issue with metadata on Glusterfs that causes this kind of behavior. I can fix this for you."
So, I don't know what kind of magic they do. Anyway, Thank you all for your help and suggestions.
– mindlessgreen Oct 21 '21 at 06:38