scotfl.ca

Lost System Keychain Password Fix

A little while back, I rebooted my PowerBook, and when I logged back in I was greeted with a dialog saying “Mac OS X wants to use keychain system,” and asking for the password of said keychain.

The problem is I don’t know the password. And yet, it wasn’t much of a problem because not entering the password appeared to have no effect whatsoever. There were only two entries in my system keychain: the password for my wireless network and the password for a friend’s wireless network. That’s it. And even though I wasn’t providing the correct credentials to the system, the keychain was being unlocked and the password read.

So I didn’t worry about it too much. The next time I rebooted I just hit escape and carried on with my normal life. Then I decided to add a SuperDuper ‘Sandbox’ to my system. This necessitated making sure my backup drive was up-to-date and rebooting off the backup so that I could repartition the internal drive. Then copying the files back to the main drive, rebooting off the main drive and setting up the sandbox. Then doing it all over again because I hadn’t allocated enough space for the sandbox. The point is, I was rebooting a lot more than usual. And that keychain started to bug me. So I went looking for a fix.

I found Ani Moller’s description of the exact same problem, with a fix from the Mac Fix It Forums. I’ve now superfluously rebooted my PowerBook twice and all is well. (Note that this process will remove any passwords you had in the system keychain, if any.)

  1. Start Terminal

  2. sudo mv /Library/Keychains/System.keychain /Library/Keychains/System.keychain.backup

  3. sudo systemkeychain -k /Library/Keychains/System.keychain -C "password" (where “password” is the new keychain password that you want to give to the System keychain)

  4. Reboot the system.

This entry was posted on 1 December 2005 at 07:41 and is filed under Uncategorized. You can follow any responses to this entry through the RSS 2.0 feed. Both comments and pings are currently closed.

4 Responses to “Lost System Keychain Password Fix”

  1. Dane — December 3rd, 2005 at 01:45

    You realize you’re going crazy, right?

  2. Karyn — January 12th, 2006 at 20:40

    I have this same problem, except the real problem is that occasionally I get asked for my wireless WEP key (particularly if I’ve been using another wireless and haven’t rebooted). The WEP key is in the system keychain (and when asked for the password to THAT, it won’t recognize the correct password, which is the same as my login password). Which means I can’t access the keychain to get the password to put in for the WEP key. I want to find out what my WEP key is (it’s written down elsewhere, but I want to verify what is actually being used on my system) before I try your fix. This doesn’t sound possible according to your post. If I run your fix, the password will be lost…is that correct? This has been discussed quite a bit on the Apple Discussion forum, so my recent post with my exact question has been getting ignored. Thanks for any help.

  3. scotflJanuary 14th, 2006 at 15:01

    You can’t get access to the passwords in the system keychain once the password is corrupted. On the other hand, it does prove the keychain encryption actually works…

  4. Eric Lansaw — August 30th, 2006 at 12:58

    Thank god for this… I really appreciate the unix help!! this worked for me