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

Masna

macrumors newbie
Original poster
Apr 20, 2007
8
0
I moved my Mac HD's private folder to the trash not knowing that it stores thousands of crucial UNIX folders (one of which that stores the admin password). I haven't yet trashed it, but I can't move it back to its original location because when I try to do that Leopard asks for the admin password but the password doesn't exist anymore because it's been moved to the trash. Is there anyway I can remove the private folder from the Trash and put it back? Maybe some kind of Terminal command?

Thanks!
 
This is a tough one.

You could *maybe* do this in Terminal, the problem is you will need admin privileges since the private folder is owned by root.

Here is the command though:
Code:
sudo mv ~/.Trash/private /

It is going to ask for a password. Good luck.
 
This is a tough one.

You could *maybe* do this in Terminal, the problem is you will need admin privileges since the private folder is owned by root.

Here is the command though:
Code:
sudo mv ~/.Trash/private /

It is going to ask for a password. Good luck.

Geez, just when I thought things couldn't get any worse...

When I try to open Terminal, I get this: "You are not authorized to run this application. The administrator has set the shell to an illegal value."
 
I would recommend Single User Mode, but that isn't going to work either. And once you reboot, your options have dwindled.

I would backup your data (if you can) and reinstall. Or do an archive and install.

I am not sure what computer you have, but a possibility is to take out the HD and put it into an enclosure or another computer and use the "Ignore Permissions option."

You are stuck in a vicious loop. I would worry about making sure you data is secure and reinstall.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.