Having A Panicless Kernel Panic

// May 9th, 2009 // Rambling

Kenn Bell, of the fabulous Dog Files (you don’t need a dog to be a fan), was having a problem with his MacBook Pro at startup. Turns out, it was kernel panic’ing. I couldn’t tweet everything I wanted to say in 140 chatracters, so I thought to myself “well, you’re a professional sysadmin by day, write out what you’d tell someone who dropped by the office with this problem.” So I did. Now, a kernel panic isn’t something you’ll see every day, but, if it happens to you, you’ll likely want to panic as well. It seems pretty dreadful when you get that ‘you must restart’ screen, but all may not be lost.

First, some background. The kernel is the heart and soul of your computer’s operating system. It’s quite resilient on its own, but we pile heaps and heaps (hehe… sorry… nerd joke…) of stuff on it in order to make our computers useful. But, if some near-catastrophic situation occurs where the kernel finds itself unable to continue/perform, it will ‘panic’. A panic is basically a software work stop. It’s saying to you “something is seriously wrong and I can’t (or won’t, for your protection) continue.” The problem could be hardware or it could be software. Let’s try to figure out which, shall we?

  1. Remove and then re-seat the RAM. The memory modules in your Mac are pretty easy to remove. Refer to Apple’s support pages or the booklet that came with the machine. If you have canned air, it wouldn’t hurt to blow out the socket too, but that’s low on the scale of ‘probable cause’. But RAM modules can work loose and just one less-than-adequate connection, especially if it’s intermittent, can cause no end of havoc for your computer. This is especially true of laptops.
  2. Do you have AppleCare? If so, boot from the CD that came in the box (hold down the “c” key at startup) and run the test utility included. If your kernel panics are constant and you don’t get one when booting from the CD (or a OSX disc), then your hard drive (or the OS install on it) have moved up the suspect list. Hopefully the utility will identify the culprit.
  3. If you can’t boot the machine without a panic, try booting in safe mode. http://support.apple.com/kb/HT1455
    If this works, then you’ll likely need to reinstall OSX at this point… You have a backup, right?
  4. If you can boot the machine (from hard drive or AppleCare CD or OSX CD/DVD), check your hard drive’s SMART status with Disk Utility. Click on the drive and look at the bottom of the Disk Utility window. If it says anything other than ‘Verified’, start cloning your data off this drive now, if you haven’t already. A little mild panic is allowed in this case. Got SuperDuper?
  5. If you can boot the machine (from hard drive – you don’t have SuperDuper on your CDs…) and have done all the above, clone your drive now. Hopefully you’ve already done this, but it bears pointing out. At the very least, have a backup of your data somewhere (via clone or Time Machine or whatever). Boot from the cloned drive (hold down the option key at starrtup and select your clone drive) — try it several times if the kernel panic is intermittent. If the kernel panic ceases, we can start suspecting your hard drive and not OSX. Otherwise, or if you don’t have a bootable clone, just a backup, let’s move on.
  6. If you can boot the machine from hard drive (your kernel panics are intermittent) and nothing above has worked, have you recently repaired permissions? Before we get into things that might make some people nervous (single user mode, etc.), let’s eliminate a simple permissions issue (or, maybe Disk Utility will error out and show that it’s the hard drive at fault). If you haven’t repaired permissions in a while, open up Disk Utility and do so now. With any luck, you won’t have a panic during this. But we have a clone/backup to fall back on, right?
  7. OK, I lied about single user mode. We’re not going there. If you’re familiar and comfortable with single user mode and fsck and and the like, you probably stopped reading this about 3 bullets ago. You may now panic. But only if you don’t have a backup. If you have a backup, it’s time to try the last-ditch-effort: reinstall OSX and restore your user data. Annoyed? Yes. Panicked? No.
  8. If reinstalling OSX does not help, it’s time to hit the Genius Bar or call AppleCare. There are other things you could attempt, but this is what you paid for. It’s time to let someone who gets paid to do it take your burden away. Deep breath… and repeat after me, “I’m so glad I got AppleCare.” You did get AppleCare, right? Oh, yes. Right. Let’s try that one too, “I’m so glad I’m still under warranty.”

There are other things you could try, but they’re outside of the scope of this post (i.e. – I’m too lazy at this point to type it all out). Good luck!

Comments are closed.



Read more nonsense at The Outhouse.

PHVsPjxsaT48c3Ryb25nPndvb19hYm91dDwvc3Ryb25nPiAtIDwvbGk+PGxpPjxzdHJvbmc+d29vX2Fib3V0bGluazwvc3Ryb25nPiAtIGh0dHA6Ly9tYWdnaWVtY2ZlZS5jb20vYWJvdXQ8L2xpPjxsaT48c3Ryb25nPndvb19hZHNfcm90YXRlPC9zdHJvbmc+IC0gdHJ1ZTwvbGk+PGxpPjxzdHJvbmc+d29vX2FkX2ltYWdlXzE8L3N0cm9uZz4gLSBodHRwOi8vd3d3Lndvb3RoZW1lcy5jb20vYWRzL3dvb3RoZW1lcy0xMjV4MTI1LTEuZ2lmPC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