5
2
I have a file in trash, and I cannot delete it. Before you ask me to STFW, no, the file is not locked :-/
The file is a symbolic link to nothing (target is deleted). Here is the output of ls -lO
on that file:
lrwxrwxrwx 1 1000 _lpoperator uappnd,nodump,opaque,compressed 22 Apr 3 2009 fly.pdf -> stuff.pdf
The output of rm
is
$ sudo rm fly.pdf
rm: fly.pdf: No such file or directory
However the file does exist, which can be confirmed by ls
or by opening trash in Finder. If I empty trash using the menu, it plays that sound and nothing happens. If I try securely empty trash, it complains about not having permission. So I'm stuck... Any suggestion?
BTW, the file in question is in the trash of a volume called "Shared", which is not the boot volume.
UPDATE: @bug pointed out that this may be caused by my link being opaque, and suggested to delete it in a chroot jail. I tried that, and chroot gave me a segmentation fault. Here is what I did for that: I enabled root following this, and followed @bug's answer and this to create the chroot jail. Chroot gave me
# chroot /Volumes/Shared
Segmentation fault: 11
Just tried it within linux, created a symlink, removed the target, no complaints when deleting the link afterwards. strange problem :/ – Baarn – 2012-02-01T01:15:19.767
Exactly. In my mind sym links are just regular files, so I'm kinda confused... – MetroWind – 2012-02-01T01:17:48.500
@Darksair I think if you use
rm -rf
it will probably also work. :) – tftd – 2012-02-02T16:44:30.320@TheDevil: No I tried, and it didn't :-, which was pretty weird... – MetroWind – 2012-02-02T16:45:38.300