I recently bought a refurbished iMac from Best Buy. When I inspected the unit after I unpackaged it, nothing appeared wrong externally. Also, the setup and installation of the OS went smoothly. However, after turning it on and browsing the web on Safari, the iMac suddenly shuts down. I thought that the power cord might've had a short in it at first, but have since moved away from that conclusion. Now, whenever I turn on the computer it will boot up fine and then suddenly shutdown or restart.
And as I write this, there is a new symptom: as soon as the iMac loads the desktop, the fans start up really loudly and then the computer shuts down.
On the machine that I was working on, which also happens to be my iMac 24" Mid 2007, I have found the solution, tested it, fixed, and retested!
In my case, as unlikely as it seems, the problem is the cable that connects the logic board to the optical drive.
I detached the cable, tested, machine came to life! re attached the cable, machine went back to freezing, restarting randomly, or not working at all.
Replace the cable the machine worked flawlessly, to further test this I placed the bad cable into another machine, same model as mine, and that machine experienced the same problems instantly!
Hope that helps! Let me know, meanwhile I'm off to play Wii and drink Dr. Pepper. Yay Weekends!
~Rivers
Those following this thread might like to know that there's another thread on an almost identical topic at <http://discussions.apple.com/thread.jspa?messageID=9202685#9202685>
Just to update: I've now had my iMac returned from the repairers with a note saying "logic board failed on processor testing, new part supplied by Apple." It's up and running OK at the moment - fingers crossed it stays this way!
I want to echo what Rivers reported and say that Apple has confirmed this is the fix. Mine is being done today. BE SURE TO ASK APPLE TO REPLACE THE CABLE. Getting a new logic board and power supply is all well and good, but if you don't get the cable, your problem will likely return