Archived - Mac OS X 10.5, iMac (Mid 2007): Stuck in a "loop" at the login window after upgrading to Leopard
After installing Mac OS X 10.5 Leopard on a 20-inch or 24-inch iMac (Mid 2007) computer (ones that have an aluminum frame), you may not be able to log in at the login window. Your login name and password are apparently accepted, but after a blue screen appears for a few seconds, the login window reappears instead of your desktop.
If Leopard is installed
Start up from the Leopard Install DVD and perform an Archive and Install installation (and select Preserve Users and Network Settings).
After the Archive and Install is complete, you should be able to successfully log in. Use Software Update to install any other updates.
Important: Install the iMac Software Update 1.3 for Leopard after the Archive and Install is complete.
If Leopard is not yet installed
If you have not yet installed Leopard on your 20-inch or 24-inch aluminum iMac computer with a 2.0, 2.4, or 2.8 GHz processor running Mac OS X 10.4.x, but previously installed the iMac Software Update 1.2, you should install the iMac Software Update 1.2.1 (Tiger) or later, before installing Leopard.