I decided to be extra helpful and upgrade the existing installation of these three apps, which powers our corporate CMS. The only reason I proposed this idea (yeah, nobody asked me to do it, I volunteered) is because the previous installation is quite dated. PHP was the worst, it was running 4.1.x.
Apache installation went without a hitch. It was done in a matter of seconds. Next was PHP, so I grabbed a copy of version 4.4.2, extracted the archive to
C:\PHP and moved the files in
C:\PHP. Nothing difficult about that. However, when I restarted the Apache service, it failed. To cut a long story short, this was because
libmysql.dll from a previous installation being in
C:\WINDOWS\SYSTEM32. Deleted those two, and wallah! Apache can now be started and phpinfo() shows that I’m now running PHP 4.4.2.
Next came MySQL… the absolute major source of my pain. Well, looking back, I guess it’s mostly a compatibility (incompatibility?) issue of MySQL and PHP (more on this later), rather than solely a MySQL problem. Who would’ve thought that upgrading from 4.1.12 to 4.1.16 could be such a pain in the ass?
To be honest, I’ve used Apache, MySQL and PHP for more than five years. However, this experience is primarily on Linux. And let me just say this, for all the noise that the Windows fanboys are making about how easy it is to install software on Win32, installing the said three apps on Linux is much easier!
OK, to cut the story short, here’s the error that I got when trying to run PhpMyAdmin:
#1251 - Client does not support authentication protocol requested by server; consider upgrading MySQL client.
I literally went “WTF?!”, it’s not that I don’t understand what the error means, it’s the fact that I’m using binary builds of PHP and MySQL… and that there’s no way in hell I can compile it manually because the server hosting the CMS doesn’t have Visual Studio. Furthermore, the PHP connector DLLs downloads on the MySQL web site are just for PHP5. Yet another stumbling block, because I’m afraid that XOOPS which is what we used for the CMS, might probably be incompatible with PHP5.
Although dazed by all these complications, I proceed to download PHP 5.1.2, after confirming that XOOPS can run on PHP5. Initially, I was quite a happy guy considering that I can see the front page just fine. I proceed to click on the most frequently used module on the CMS, which is our Project Management module. It’s a highly hacked version of WebSlave Project… *bam!* blank page! Arrrgghhh!
In the end I did get PHP 4.4.2 and MySQL 4.1.16 to play nice with each other (old connector DLL and all) by adding the following line in the
Hell, that thing doesn’t even look like an INI file directive (which usually come in pairs; eg.
variable=value)! This particular post by Mark Rosenthal in the MySQL forums pretty much sums up my frustration with this whole damn exercise.
Painful lessons learned:
- Never assume upgrading/installing open source software on Windows to be easier or as easy as on Linux.
- Always make backups of existing data files regardless of how easy you foresee the upgrade/installation to be.
- Take more than five minutes to google for potential problems.