Cannot remove a file nor a directory containing it.
output of ls -la:
-????????? ? ? ? ? ? 1221036243.V905I191359M574755.domain.com:2$
UPDATE 1
[root@domain Maildir]# chmod -R 777 cur
chmod: cannot access `cur/1221036243.V905I191359M574755.domain.com:2$': No such file or directory
UPDATE 2
[root@domain Maildir]# rm -rf cur
rm: cannot remove `cur': Directory not empty
rm -rf 1221036243.V905I191359M574755.domain.com:2$
rm -rf 1221036243.V905I191359M574755.domain.com:2\$
NO output at all.
UPDATE 3
[root@domain cur]# getfacl .
# file: .
# owner: root
# group: root
user::rwx
group::rwx
other::rwx
UPDATE 4
[root@domain /]# umount backup
[root@domain /]# fsck /dev/md119
fsck from util-linux 2.19.1
e2fsck 1.41.14 (22-Dec-2010)
/dev/md119: clean, 1487811/183148544 files, 80994051/732566603 blocks
[root@domain /]# mount backup
UPDATE 5
[root@domain /]# fsck -f /dev/md119
fsck from util-linux 2.19.1
e2fsck 1.41.14 (22-Dec-2010)
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Problem in HTREE directory inode 180886324: block #10437 has bad min hash
Invalid HTREE directory inode 180886324 (/.snapshots/daily.2/h1/mailboxs/magazin/Maildir/cur). Clear HTree index<y>? yes
Pass 3: Checking directory connectivity
Pass 3A: Optimizing directories
Pass 4: Checking reference counts
Pass 5: Checking group summary information
/dev/md119: ***** FILE SYSTEM WAS MODIFIED *****
/dev/md119: 1487811/183148544 files (0.1% non-contiguous), 80980327/732566603 blocks
And many thanks goes to Michael Hampton
with his fsck -f /dev/md119
.
You need to run
fsck
with the-f
option, to actually do the filesystem check.The problem is that you have read access to the directory but no execute and no write access. Execute access will replace the "?" with useful data, write access will allow you to delete the file.
Write access is not enough to delete a directory entry. Execute permission is required, too.