Sponsored in part by... Bare Bones Software Yojimbo 1.5 from Bare Bones Software: Your effortless, reliable
information organizer for Mac OS X. It will change your life,
without changing the way you work. Download the demo or buy it
today! <http://www.barebones.com/products/yojimbo/>

 [F] TidBITS  / TidBITS  / TidBITS Talk  /

Forgotten admin password - no OS X CD

[chris686]chris686 - 01:50am Sep 10, 2007 PST

A friend with a G3/500 mHz iMac (OS X 10.4.7) asked me to help her install the software for her new Hewlett Packard all-in-one printer/scanner/copier. The installer asked for her password.

She's forgotten it. She is the sole (admin) user.

I discovered that you can reset the password using the OS X installer CD.

She has either misplaced, or never had, an installer CD (the iMac was bought used).

Googling got me this:

"Here's how to reset your OS X password without an OS X CD. You need to enter terminal and create a new admin account:

1. Reboot

2. Hold apple + s down after you hear the chime.

3. When you get text prompt enter in these terminal commands to create a brand new admin account (hitting return after each line):

* mount -uw /

* rm /var/db/.AppleSetupDone

* shutdown -h now

4. After rebooting you should have a brand new admin account.

5. Change the password on your old account while logged in as your new Admin account, then log back in as yourself and delete your new Admin account."

My friend is retired and has zero technical knowledge, though she gets a big kick out of all the things this somewhat elderly iMac lets her do. I do NOT want to hose her machine.

Does anyone have an opinion as to whether the above tersely-described procedure will work, and is safe? I'm not clear how you can create a new admin account via Terminal apparently without entering a new username/password. How do you log in as the new user?

Another friend has an eMac with two OS X 10.3.? installer CDs. Might these be used to reset a password on another model Mac with 10.4?

I go into battle again with the iMac on Tuesday. Any advice will be much appreciated.

TIA, Chris Adams.


Mark as Read
  OutlineAll MessagesOlder MessagesOldest MessagesNewest MessagesNewer Messages

davidro (apparently) - Sep 10, 2007 7:06 am (#1 Total: 10)  

Reply to this message
via email  

Photo of Author
Posts: 21
Re: Forgotten admin password - no OS X CD

Hello Chris,

I have a nasty cold, so forgive me if parts of this are incoherent..
but here goes:

When you delete the AppleSetupDone file the Mac will run the "First
time bootup" process, which allows you to add other accounts, or
replace existing ones. It is a very safe process, I have used it in
the past to reset a used Mac to that "as new" state, while having
done all the Apple software updates (and installed extra software as
well).

As your source mentions, avoid recreating an existing account. It may
wipe out the current contents. You can also replace "shutdown -h now"
with "reboot" in your case.

Once you have reset her password you may also need to reset her
keychain password to match. The instructions are on the Apple support
site.

Cheers,

Dave

cdevers (apparently) - Sep 10, 2007 7:06 am (#2 Total: 10)  

Reply to this message
via email  

Photo of Author
Posts: 134
Re: Forgotten admin password - no OS X CD

On Sep 10, 2007, at 4:50 AM, chris686 wrote:

> "Here's how to reset your OS X password without an OS X CD. You
> need to enter terminal and create a new admin account:
>
> 1. Reboot
> 2. Hold apple + s down after you hear the chime.
> 3. When you get text prompt enter in these terminal commands to
> create a brand new admin account (hitting return after each line):
>
> * mount -uw /
> * rm /var/db/.AppleSetupDone
> * shutdown -h now
>
> 4. After rebooting you should have a brand new admin account.
> 5. Change the password on your old account while logged in as your
> new Admin account, then log back in as yourself and delete your new
> Admin account."

This approach is very "slash & burn", but would work.

Slightly better:

  * Make note of the short name for her account (among other places,
it will be the name for her home folder, in the Finder sidebar, in /
Users/<hername>, etc. as well as the Accounts panel of System
Preferences).

  * Then follow the steps above, using that short name verbatim when
you get to the account setup screen. If you use the exact same short
name (the long name doesn't matter, it's just a label for the short
name & can be completely unrelated), then the system will use the
same home folder, settings, etc along with the new password.

Slightly better than that, but more technical:

  * Modify the steps above to reset the password rather than re-run
the setup process:

    - figure out the account short name, as noted above
    - boot holding [apple]+[s]
    - launch core system services by typing
      sh /etc/rc
    = change the password for the account's short name, with
      passwd <hername>
    - enter the new password, press return, type it again, press
return, it should say something like "password changed"; it won't
repeat what you're typing, but it will be working, just trust it.
    - restart the computer, then log in with the new password, with
      reboot

That works, but is a bit more technical, and sometimes will go into a
state with a blue screen & a mouse cursor where you can't type any
more, so you're (as far as I can tell) stuck, and have to start over.

Better still,

   * Find someone with the Tiger CDs, or any PowerPC Tiger restore
discs (Intel versions won't work, but most G5/G4 ones from 2005-2006
should), and restore from that. Or bring in the machine to a local
store to have them help reset it, which is generally no big deal to do.

> Another friend has an eMac with two OS X 10.3.? installer CDs.
> Might these be used to reset a password on another model Mac with
> 10.4?

I don't *think* a 10.3 installer disc can reset a 10.4 password, but
feel free to try it. On the other hand, a 10.4 installer should be
able to reset a 10.3 (or even I think 10.2) password.


--
Chris Devers

Lewis Butler (apparently) - Sep 11, 2007 3:51 am (#3 Total: 10)  

Reply to this message
via email  

Photo of Author
Posts: 989
Re: Forgotten admin password - no OS X CD



On 10-Sep-2007, at 02:50, chris686 wrote:

> Does anyone have an opinion as to whether the above tersely-
> described procedure will work, and is safe? I'm not clear how you
> can create a new admin account via Terminal apparently without
> entering a new username/password. How do you log in as the new user?

Removing the file mens that when you reboot the initial startup
sequence for a new install runs, this sequence creates a new account,
asking for your name, contact info, etc.

And then it logs you in to this new account. You can then change the
password on the old account and log back in as the original admin.

I would keep the new admin account myself. Always good to have a
second account.

Well, actually, what I would do is demote the original admin account
to a standard user, but then I don't run my machines as the admin user.

Mark H. Anbinder (apparently) - Sep 11, 2007 3:51 am (#4 Total: 10)  

Reply to this message
via email  

Photo of Author
Posts: 445
Re: Forgotten admin password - no OS X CD

Chris muses...

> Does anyone have an opinion as to whether the above
> tersely-described procedure will work, and is safe?

What you're essentially doing is convincing the Mac that it's never
been through the initial setup procedure where it plays pretty music
and asks the user to create the first/main account. (The "rm
/var/db/.AppleSetupDone" line is simply removing the flag that tells
the Mac that's been done.)

I've used a similar procedure to fix a Mac that was hanging just
before it got to the login screen. Without actually trying it, it
seems that these steps ought to work, or at least shouldn't make
things worse.

Specifying a DIFFERENT username is important, so she can log in as
the new admin user and then change the previous user's password from
within System Preferences.

> How do you log in as the new user?

When the machine reboots after step 4, it will either ask her to log
in during startup, or it will bypass startup entirely because it's
set to log in automatically as one of the users. If it logs in as the
old user, she can choose "Log Out" from the bottom of the Apple menu,
and it will present a login window where she can log in as the new
user.

> Another friend has an eMac with two OS X 10.3.? installer CDs.
> Might these be used to reset a password on another model Mac with
> 10.4?

Probably, since her iMac is pretty old, though the discs that came
with the eMac might be limited to booting that model. It's worth a
try.

Good luck!

  Mark H. Anbinder
  Contributing Editor, TidBITS

David Weintraub (apparently) - Sep 11, 2007 3:56 am (#5 Total: 10)  

Reply to this message
via email  

Photo of Author
Posts: 214
Re: Forgotten admin password - no OS X CD

It looks like the ".AppleSetupDone" is a file that Mac OS X uses to
see whether you've set yourself up for the first time or not. If the
file isn't there, on reboot, it creates a new admin account. From
there, you can change the password on the original account.

This should be fairly safe and probably the least technical way of
resetting the password.

David Weintraub

big.smelly (apparently) - Sep 11, 2007 3:56 am (#6 Total: 10)  

Reply to this message
via email  

Photo of Author
Posts: 3
Re: Forgotten admin password - no OS X CD

You will have to re-start with the 10.3 disk in the drive. Hold down the option key to be able to choose the cd. It has the password reset utility on it, I've had to do this with my mothers Imac. Unless there is a problem with her system she probably doesnt want to start over with a clean mac. Regards C

chris686 - Sep 12, 2007 3:06 am (#7 Total: 10)  

Reply to this message
 

Photo of Author
Posts: 3
Re: Forgotten admin password - no OS X CD

Success!

The puritan in me ruled out the "passwd short-name" short-cut, so I went the longer route of deleting the .AppleSetupDone file, then going through all the "Welcome to OS X!" setup screens after reboot.

There was a nervous moment when the eMac demanded to know the AirPort network password (user had forgotten it - arrgghhhh!), but I lied and told it there was no network. After that it was all plain sailing.

My friend bought a Hewlett-Packard printer/scanner last December. Now for the first time she can use it, as she had a valid password when HP's software installer asked for it.

Thanks to all who responded.

Cheers, Chris Adams.

Mr. Kerchak - Feb 9, 2008 1:54 pm (#8 Total: 10)  

Reply to this message
 

Photo of Author
Posts: 3
Re: Forgotten admin password - no OS X CD

Just wanted to say thank you as the 1st solution worked for my problem too.

I'll detail my situation in case anyone else ever has my problem. Hopefully a search will lead them here.

I have an eMac running OSX 10.3.9 (panther). I created an account for my 3 yr old so she couldn't mess up my stuff. After weeks of having no problem switching between accounts, suddenly it wouldn't accept my password for my account. The pw is hidden so I can't see what I'm typing. After a few tries I looked to the internet for a solution but noticed the characters I typed weren't the characters that came up on screen. I assume that's why my password wasn't working. When I typed 'superman' it was probably coming out something like 'ß¨π´®µå˜'.

So I fired up IE on the old OS9 iMac & found this thread. Thanks again.

Anyone have any idea what my daughter could have done? Could she have changed the character set somehow?

tekelenb (apparently) - Feb 9, 2008 6:33 pm (#9 Total: 10)  

Reply to this message
via email  

Photo of Author
Posts: 257
Re: Forgotten admin password - no OS X CD

At 12:54 -0800 UTC, on 2008-02-09, Mr. Kerchak wrote:

> [...] OSX 10.3.9 (panther). I created an account for my 3 yr old so she
>couldn't
> mess up my stuff. After weeks [...] my password wasn't working. When I typed
> 'superman' it was probably coming out something like 'ߨ&#960;´®µå˜'. [...]
>
> Anyone have any idea what my daughter could have done? Could she have
> changed the character set somehow?

Probably, yes. Mac OS X's Limited Users (Parental Control) aren't that
limited at all... It seems to have been bolted on, as an afterthought.
(Although I believe it is slightly better in Tiger. Possibly again slightlier
better in Leopard.)

For this particular issue, you can enable the Input menu in the Login window,
so that you can always change the input right there, when needed. In Tiger
it's at Apple Menu->System Preferences->Accounts->ligin Options: Show Input
menu in Login window.


--
Sander Tekelenburg, <http://www.euronet.nl/~tekelenb/>

h-pe_so_J - Apr 27, 2008 3:54 am (#10 Total: 10)  

Reply to this message
 

Photo of Author
Posts: 1
Re: Forgotten admin password - no OS X CD

um hi i did all of that and it worked prefectly but... i was really stupid and forgot to change the password to the account i made aministrater.. and then i took the privileges away from the new admin.. and i was reaaly bummed.. i tryed doing it all again but it didnt create a new admin.. iz there something that i can do to do it again???



  OutlineAll MessagesOlder MessagesOldest MessagesNewest MessagesNewer Messages


 [F] TidBITS  / TidBITS  / TidBITS Talk  / Forgotten admin password - no OS X CD




Add a message

To add a message to this discussion, you must be a registered user. Enter your email address below. If you have an account associated with the email address you enter, you will be prompted for your password. If not, you'll be able to create a new account with no fuss.

Enter your email address:

Submit