What worked for me
1) Upgraded to Lion from Snow Leopard on a RAID
2) Could not login. Guest user disabled. Root user disabled. No other user accounts show up. F*(&
3) Booted up from Lion install CD. Went into Terminal. Typed resetpassword, which opens up a separate window behind the Terminal window where you can reset the password of the root user on another drive. I reset the root user password for my locked out drive.
4) At this time I also repaired permissions, and installed the 10.7.3 combo update from the terminal, on my RAID drive.
Notes:
Disk Utility in 10.7.0 cannot repair permissions on a RAID which is why I had to do it from terminal. This is the command to do it:
diskutil repairpermissions /Volumes/MyDrive/
diskutil also has other commands, google it or read the man page etc.
Also, in case you're wondering how I got the 10.7.3 combo update .pkg file into the mix: I copied the 10.7.3 combo update .pkg file onto a USB stick from a different computer, then inserted it into this one, and ran the installer from terminal using this command:
installer -pkg packageToInstall -target /Volumes/MyHD
(ignore the errors at the beginning, about missing bundles, as they are meaningless!)
5) Restarted and booted from the main drive again, logging in as root this time.
6) Went to System Preferences and added a new user, typed in the short name as being the same name as my pre-existing account, and entered the same exact password (I understand this bit is important); then I said YES when it asked me if I wanted to base this user account on the pre-existing user folder!
7) I had to go through all this same B.S. when I upgraded to Leopard or Snow Leopard, can't remember which, but I've been through this mess before, stupid Apple can't figure out how to make a damn system upgrade that "just works"... you would think that the user account part would BE IMPORTANT TO THEM...
8) If at this time you find that a bunch of your folders that were not in your user directory (but which you have placed at the root level of your hard drive, or elsewhere like in Applications directory or in the Library) have now changed their "owner" to a weird number like 502, here's how to fix it:
a) go to Terminal
b) type this command for a file:
sudo chown yourUserShortname:admin /Folder/path/To/filename.doc
type this command for a folder whose contents you want to all be owned by your new user account:
sudo chown -R yourUserShortname:admin /Folder/path/To/Folder/
c) If that doesn't work because it says "Operation Not Permitted" then do this command:
sudo chflags nouchg /Folder/path/To/filename.doc
or
sudo chflags -R nouchg /Folder/path/To/Folder/
then repeat step (b) and now it will work!
Hope this helps,
- guy who keeps thinking that THE MORE AND MORE TIME GOES ON, THE LESS AND LESS MAC-LIKE THE MAC BECOMES, UNTIL IT HAS FINALLY STARTED TO BECOME A PC-LIKE HUSK CRUFTING ITS WAY THROUGH REALITY, DISGUISED IN A BEAUTIFUL MAC EXTERIOR