Tag: server2k8
PHP 5 and Windows Server 2008 (x64)
by Chris on Aug.02, 2009, under Computing, Programming, Windows
I recently set up a Windows Server 2008 x64 system using PHP 5.2.10 (soon to use 5.3.0, waiting for an upgrade of the memcache extension), and discovered that PHP running under FastCGI to talk to Apache performs alarmingly slower than on Windows Server 2003 (x86). Looking for a way back to performance bliss, I took a look at SAPI again.
It could be a configuration change, a side effect of using x64 edition, or a number of other reasons since the changes between Server 2008 and 2003 are so large. PHP on Windows has never really had a lot of love unless you’re willing to shell out incredibly massive amounts of cash for Zend’s proprietary offering, but frankly I could just use IIS 7 over that if I really wanted to.
Changing the way PHP communicates with Apache, from FastCGI to SAPI, results in an incredible speed increase and stability increase. I will be spending time to look for reasons to this, as I am still unsure of the actual cause. I will also try SAPI again for Server 2003 and see if, maybe, it’s just a FastCGI deal with Windows that I was previously unaware of.