Reset ownership of Home items to fix problems

Aug 30, '02 05:18:57AM

Contributed by: varcos

My brother was having a lot of problems with his computer recently. He couldn't sync his Palm because the Transport Monitor wouldn't start (it kept giving a "9460 error"). Mail.app kept asking him for his password. Other preference settings simply wouldn't save.

I figured that there was something that didn't have the correct permissions set, and it was most likely in his home directory. Read the rest of the article for the process we used to fix the problem.

WARNING: Please be very careful when doing this, if you accidently set the user for your files to a different user, you run the risk of not being able to boot at all. This writeup is intended for beginners, so please excuse me if it seems overly detailed.

Go to the System Preferences application and then open the Users pane (or the Accounts pane in 10.2). Select your user and then hit "Edit User...". Look at (and remember!) your "Short Name"; you'll need it later. Open the Terminal application (It's in Applications -> Utilities). You should already be in your Home directory, but to be sure, type:

  cd ~
Make sure you hit return to execute the command. The ~ is the shift of the key to the left of the 1 on an English Keyboard.

WARNING: The next step is going to reset all the files in your home directory to be owned by the short name you enter, so BE SURE THAT YOUR short name IS THE RIGHT ONE!!! Type:
  sudo chown -R short_name *
Again, hit return to execute the command (of course replace the short_name with the short name you noted in the previous step. For example if your short name was myname, then you'd type:
sudo chown -R myname *
I hope that helps someone else out; it definitely fixed my brother's (seemingly random) system errors.

[Editor's note: This is one of those things you should not have to do from the Terminal, as the Get Info box has onwership information and an "Apply to enclosed items..." option. However, it also groups permissions with owernship, so if you were to try to simply set the owner for all items in Home, you would also change the permissions to the shown defaults ... which means, amongst other issues, you would break the "Public" folder, which has a different set of permissions!]

Comments (4)


Mac OS X Hints
http://hints.macworld.com/article.php?story=20020830051857940