Guest sign-in only but never had a password.

Started 4 months ago | Questions thread
Tom_N Forum Pro • Posts: 19,166
Re: Guest sign-in only but never had a password.
4

I would suggest the following, preferably after booting from the external drive and using a utility like Carbon Copy Cloner to make a complete backup of the internal drive on another (spare) external drive.

1. Boot up in single-user mode. Try to list all "regular" users by typing in the command dscl . list /Users | grep -v "^_"

I don't know if this works in single-user mode, but the objective is simply to check if the machine still has an entry for your Admin account. In my case, the output is

daemon
Guest
nobody
root
tnewton

2. If you see your Admin user name in the list, try doing a passwd yourusername to reset the account password.

3. You could also try doing a dscl . read /Users/yourusername IsHidden to see if by some remote chance you intentionally hid the account from Finder view.  I get "No such key: IsHidden" (good) and presume that if there was a key with value 0, it would also be good.

4. If the account is hidden, you could try doing a dscl . create /Users/yourusername IsHidden 0

5. If you don't see an Admin user name in the list, you may need to use CLI commands to create a new Admin account.  My main concern here would be permissions; the new Admin account probably would not have the same internal numeric user ID as the old (mysteriously disappeared) one; and maybe not the same name, which might complicate efforts to access any account-specific preference and data files on the internal drive.  If the old Admin user name is gone, it is also possible that whatever deleted the account also deleted the associated user directory (and data).

However, if you can recover or create an Admin account, you shouldn't need to reinstall the operating system or applications.

https://sterlingit.com.au/how-to-create-a-user-or-admin-user-in-osx-apple-mac-via-terminal-commands-in-9-simple-steps/

https://osxdaily.com/2016/07/05/list-user-accounts-command-line-mac/

https://osxdaily.com/2015/02/01/hide-specific-user-account-mac-os-x/

Keyboard shortcuts:
FForum PPrevious NNext WNext unread UUpvote SSubscribe RReply QQuote BBookmark MMy threads
Color scheme? Blue / Yellow