Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'A GUI tool to change the short username' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
A GUI tool to change the short username
Authored by: phillymjs on May 28, '04 02:47:43PM

I've been using the procedure in the older hint for ages with machines I've built for clients, and never had any problem in either Jaguar or Panther.

For those too lazy to click the old hint :-), here's the manual way to do this that I have been using problem-free:
----------
1. Log in as an admin user other than the account you're messing with.
2. Change the shortname in Netinfo Manager. Every property whose value is the old shortname should be changed to the new shortname.
3. If the user is an admin, be sure to go into the admin group and change the value of the users property whose value is the old shortname.
4. Save your changes and quit Netinfo Manager.
5. Open up Terminal, and do a "sudo mv /Users/[oldshortname] /Users/[newshortname]" to change the name of the user's home directory.
6. Log out of the admin account and go in as the user you edited. Everything should be peachy keen.
----------

I was actually going to fool around with scripting this myself this weekend using niutil commands stuck in an Applescript applet.

~Philly

---
--
Ohhh, WHY did I register with Insta-Trace???



[ Reply to This | # ]
A GUI tool to change the short username
Authored by: DanFrakes on May 28, '04 10:00:41PM
phillymjs, for the most part, those steps are accurate, and that's exacty what ChangeShortName does. However, your steps are actually missing a number of things if you want the change to be "complete." ChangeShortName actually does all of the following:

1. Backs up all local NetInfo databases.
2. Replaces all instances of the user's short name in the /users/ NetInfo record.
3. Changes the long name (if a new long username is supplied).
4. Finds all groups to which the user belongs and updates the short name in each group to the new short username.
5. In Mac OS X 10.3, renames the user's "personal" group, if present.
6. Renames the user's home directory.
7. Renames the user's keychain file.
8. Renames and reconfigures the user's httpd (Personal Web Sharing) config file.
9. Renames any Samba access files.
10. Renames the user's crontab file.

That's really why we wrote ChangeShortName. Even Apple's Knowledge Base instructions missed a few things. Plus James added some nice error-correction code.

[ Reply to This | # ]