6

I changed a username in Yosemite, and now everything under that username is wrecked.

  • Chrome won't work at all, saying it can't read or write to a data file.
  • All of my son's Minecraft data is lost, and the minecraft launcher won't run, saying something about Java not being able to set up a directory.

Both these things run fine under all other usernames. Also, I can't establish Read/Write permissions for any folders at all, though the problem username is an admin account, and I have all the passwords to unlock the permissions manually and changed them in the "get info" area, and have changed them many times, the change never sticks.

I have tried Repair permissions, in the disk utility, and that hasn't worked either. How can I salvage Minecraft or possibly all user data?

  • I won't expect my Minecraft questions to be answered here, but any help at all will be sooooo appreciated. Oh, and of course, I didn't have Time Machine turned on, so I can't fix it that way. Dummy – Kate S Jan 6 '15 at 2:29
  • Kate, Welcome to Ask Different. This is very much on topic. One question, when was the last time the Mac was backed up? – bmike Jan 6 '15 at 2:58
  • Well, as I didn't have Time Machine turned on, and just turned it on tonight, I have back ups ongoing from about an hour ago. I changed the username about a week ago. – Kate S Jan 6 '15 at 3:01
  • Yes, you can change your name, from [Apple technical support][1] you can find the right way to do that. But now there is something wrong, so please describe some detail, how do you change your name, e.g. [1]: support.apple.com/en-us/HT201548 – nelson Jan 6 '15 at 3:06
  • Kate - Making the backups now is very important. That lets you try some things and not make things worse than they are and protect the rest of the users/apps. I'm not going to have time tonight to make an answer, but you'll basically delete the "broken user" and tell the system to not delete account. Then you'll go in terminal (or use admin permissions of another account) to rename the deleted user to be what you want. Lastly, you'll recreate that user to match the short name and the system will fix all the permissions. From there we can attack minecraft, etc... – bmike Jan 6 '15 at 3:16
3

When you changed your username, did you also change the name of your home folder. Without more information, my best guess would be that you changed your username by going to System Preferences→Users & Groups, right clicking on your account and choosing "Advanced Options". There are fields there where you can change your username (inexplicably labeled "Account name") and your home directory.

You should never change either of these for the account you're currently logged in as! Log in as a different user.

Changing the "Home directory" field only changes where the account looks for its home directory. It does not actually rename the folder.

Continuing to guess, I will surmise that that's exactly what you did. You wanted to change your username from oldyou to newyou and at the same time changed the name of your home folder from /Users/oldyou to /Users/newyou, but made the change only in the dialog, not on disk. The next time you logged in, the system noticed your home folder (/Users/newyou) was not present, so it made one for you as if for a new user.

The good news is that your old home folder, /Users/oldyou, is still there with all your data (Minecraft included), exactly as you left it.

There are two possible paths you can take here, both depending on your still being able to perform admin functions.

One method is to go back to System Preferences and change the "Home directory" field back to /Users/oldyou. You'll have to restart, but when you log in all your data will be back. You'll have a now-useless folder /Users/newyou, which you can delete.

It'll mean that the name of your home folder no longer conforms to the /Users/username convention, but that should be OK. It's just a convention, and only poorly written software will get confused by it. Sadly, we live in a world where poorly written software exists.

Which leads to the second method for resolving your problem. If you can still create accounts, make a new admin account. In that account, delete /Users/newyou and rename /Users/oldyou to /Users/newyou.

These folders are marked as deny delete, which also means you can't rename them. (Renaming is tantamount to deleting and then adding.) Finder probably won't even let you try. You can do it from Terminal, though, by first:

sudo mv /Users/newyou /Users/trashme
sudo mv /Users/oldyou /Users/newyou

Be sure you've replaced newyou and oldyou with the proper names. Verify that you can log in to your newyou account. Once you're sure that everything is working as it should, you can delete the /Users/trashme folder with:

sudo rm -rf /User/trashme

Be very sure you've entered that exactly as I've given it. Copy/paste might be a good idea. Punctuation, including spaces, is very important here.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .