Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

agdickinson

macrumors regular
Original poster
Hi,

I had a machine lockup using OS X 10.2.8 and now I'm unable to delete a file.

I have run disk utility and checked the permissions on the disk and everything appears to be fine.

[pbg4-15a:/] root# rm -r p
rm: p: Directory not empty
[pbg4-15a:/] root# cd p
[pbg4-15a:/p] root# ls -lastr
total 0
0 drwxrwxrwx 3 andrew admin 102 Oct 16 16:11 .
0 drwxrwxr-t 30 root admin 1020 Oct 16 16:15 ..

It is saying the directory is not empty, even though I've checked for files.

HELP
 
do me a favor

cd into the directory

do an rm -rf *

then cd back out and try deleting the directory with -rf flags.

paste the results. i don't have a clue either, really, but it can't hurt...

:)
pnw
 
Success albeit a bit complicated

Well

I managed to sort it out via a few lovely unix commands in the Single user mode for my PowerBook G4.

I reset the machine and then when starting it up held down:

<APPLE-KEY> + <s>

which started the machine in single user mode.

I then typed in:

/sbin/fsck -y

It fixed problems on the machine, then I typed it in again (until 'No problems appeared').

/sbin/fsck -y

Then after everything was ok:

/sbin/mount -uw /

Then

/sbin/fsck -y

Which ran successfully and finally:

reboot

Which rebooted the machine and it started up okay. The files had gone, and also I could delete files from Trash which had it did not allow me to do...

:O)

Andrew
 
Delete OS X files in OS 9

agdickinson said:

I had a machine lockup after using OS X 10.2.8 and now I'm unable to delete a file.
I have run disk utility and checked the permissions on the disk and everything appears to be fine.
It is saying the directory is not empty, even though I've checked for files.


agdickinson, have you tried the back door through OS 9? Probably one of the reasons Apple wanted to drop our capability of being able to start up in OS 9 is that by doing so, many of the safeguards in OS X are easily bypassed.

EASIEST SOLUTION: If you know the identity and location of the "problem file" in 10, go into 9 and TRASH it there.

I had to reload OS X Jaguar after being an early installer of the errant 10.2.8 due to app crashing and other ugly problems, especially corruption of preferences - which needed to be trashed in OS X. I'm still cleaning up the mess.

Problems were only on my 1GHz DP G4, no problems on my iBook G3 700 MHz. Hopefully, Panther will cure lots and lots of things.

If that doesn't work, ask for more ideas.
 
It could have been a hidden file starting with a "." ls -a would show any hidden files.

Edit - oh my bad i didnt notice the a in there sorry
 
Trash mac problem Error Code 51

I had a weird problem with my trash. For some reason it started deleting my files immediately when I placed it in the trashcan. Then, it wouldn't delete anything at all and I got the error message Error Code 51. Just for other users out there because this forum really helped me. So, if I sound a little naive with my computer usage... apologies. Anyway, I took all my folders of documents that I have and placed it under OS 9 folder. I then created a new user, took the files from the OS 9 folder and placed it back onto my desktop. they came out as read-only files, but you can obviously open it up, save as and there we are. I then deleted the user that wasn't working and my trash is working on my new user and all my files were still on there. Hope this helps anyone as this forum as helped me. Thanks everyone out there! -frustrated user in London
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.