Blue Screen of Death for Mac OS X
An anonymous reader writes "Possibly nothing in the OS world has as much of a bad rap as the infamous BSOD (blue screen of death) in Microsoft Windows. On the other hand Apple hides the ugly kernel panics behind a nice looking GUI which only tells you its time to restart your dead system. Interestingly Mac OS X kernel has a secret API which lets you decide what your kernel panics are going to look like! In this Mac OS X Internals article Amit Singh explains how to use this API. Apparently you can upload custom panic images into the kernel and there's even a way to test these images by causing a fake panic. The article also shows the ultimate joke is to upload an actual BSOD image for authentic Windows looking panics right inside of OS X."
It's not like Microsoft invented it, either. I remember these quite unfondly. Before that I had a frozen screen on a C64. And before that I had stopped lights on the PDP-11 display. And before that we had random characters all over the screen of Ohio Scientific (OSI) computers.
But Microsoft is widely credited with perfecting the BSoD and giving it fame.
A system crash with a tasteful little box can be as easily dispised as all the the preceding. I suppose, like everything Apple is doing these days, they've given it a certain panache and now everybody will want one.
A feeling of having made the same mistake before: Deja Foobar
Likewise in windows you can change the background color and text color of the BSOD (or at least you could uder 98, I haven't had the desire to play around with it under 2000 / XP since they crash much less frequently).
Philosophy.
That's not NEARLY as cool as the car crash sound Macs used to make when they really, really, REALLY blew up fierce. Get a good pair of speakers, and that sound would scare the tar out of everybody in the area!
I think it only happened to me once, on a junky old LCIII, while I was just working. There was a key combo to induce it on boot, though, and I got a lot of mileage out of that...
Why yes, I AM a rocket scientist!
I have gotten the gray screen of death twice on my Quad.
When capturing QuickTime video, QuickTime writes one copy of the file and then makes another. If you are capturing to a mastering codec (ie animation) minutes can become gigabytes. It is easy to fill up the internal HD in this case.
What can easily happen in this case is the file writing routines will start writing over allocated blocks. System files, even track zero. If it writes over track zero, your internal hard drive will be destroyed.
How do I know this? It happened to me twice.
The second time, I was left with a 17 GB file on my hard drive that can not be deleted by any means other than reformatting the disk. The first time it happened, the HD was borked so bad that plugging it into another Mac caused that mac to kernel panic. Apple replaced the drive but I lost everything minus my backups.
As I was told by an Apple tech, when a hd starts up the dirve itself checks the validity of track zero. If it is invalid, you have a hardware fault and this generates a kernel panic.
This was all validated by Apple techs.
You have been warned. Hope this helps someone.
- Zav - Imagine a Beowulf cluster of insensitive clods...
Kernel panic information gets logged on reboot to a file and you can capture a kernel core dump if you want.
Review... TN2063, TN2118, Debugging the Kernel, etc.
Actually, it's possible on Windows as well. Not that I particularly *like* Windows by any stretch of the imagination, but XP and 2003, at least, will write a memory dump to the system swap file to be copied into %systemroot%\memory.dmp on the following startup, provided that it's configured to do so. The memory dump can then be loaded into a debugger to do post-mortem debugging. It does have a talent for not being the most useful on some configurations - I've run into issues on systems with >2G of memory, generally with the end of the dump file being truncated, but it certainly does save those details for later analysis.
Dogma: Dead (mostly because your Karma ran it over)
Funny - about the same amount of time since I saw one on any of my Windows boxen. YMMV.
The graphical version takes slightly fewer resources. You have to run a single buffer through an RLE decompression routine directly out into a linear mapped framebuffer. To display text you actually have to use all of the console code. Remember, there is no hardware console, so you have to actually do all the text element positioning in software, and the graphics card is in exactly the same mode either way.
It does not take appreciably more resources either way, and both code paths are fairly simple and well tested.
Today no less, at the local Apple store I got a kernal panic "You need to restart your computer" message. All I did was put OmniDazzle on a new Mac Pro.
What surprised me was that I had only ever seen the kernal panic only once before after using OS X daily over two years... and that was when I was trying to crash it. (Hint: disabling network adapters and enabling others while connected to an SMB share can cause unpredictable results under 10.3)
While changing the crash message is interesting, it's not something that will make that much of a difference. I'm not going to say that OS X doesn't crash; after all, I managed to crash one by doing something rather safe. It's just not going to be a practical joke that has a quick payoff.
From TFA, the crash screen is a single image file, a screenshot. It's probably no harder to load a single screen than a stream of text. And OSX does have an option to display text error messages if you really want to see them.