My pain when migrating to PHP 5.3 from PHP 5.2 (related to Firebird and MySQL)
I was recently migrating my server to PHP 5.3. To be honest I don’t know why. I’m not using PHP often, only few applications and some simple web pages (really simple logic). And this blog. To make things worse, I’m using as my main database Firebird, not MySQL. And PHP driver for Firebird, say, it’s very average. But to keep myself in touch with “current” world I decided to go to PHP 5.3 (hoping also some bugs (mainly Firebird related
) to be fixed there). I faced two issues.
First was problem with loading php_interbase.dll. After some research I found, the gds32.dll isn’t part of PHP package as it was in 5.2. Using fbclient.dll from Firebird’s installation and renaming it to gds32.dll didn’t solve the issue. Surprisingly (thanks Process Monitor), the extension is looking for fbclient.dll (in PHP’s directory, not in ext). InterBase & Firebird mix.
Other problem was MySQL. I don’t like the database and also I’m not expert in PHP+MySQL stuff. I feel more strong around Firebird stuff. The incompatibility is known and it’s about MySQL’s new (longer) password hashes being mandatory to be able to connect from 5.3. And you get error saying it: mysqlnd cannot connect to MySQL 4.1+ using the old insecure authentication.. I’m not admin (logically or from privileges) of MySQL server I’m using, so some tips were not working. The final commands that solved my issue were:
set session old_passwords = 0;
set password = password('<password>');
I was kind of jumping around it, with similar commands or commands doing same thing only requiring higher privileges.
Although simple to solve, I spent some time doing wrong steps (and trying). Hope this will save yours.



There's 2 Comments So Far
April 6th, 2011 at 03:02
Just wondering if you prefer an alternative to PHP for firebird web applications. I had written a http server a few years age to do this sort of stuff but got tired of keeping it up to date with the web standards. So now I am in the process of migrating to using PHP & Apache. If there is a better way (non commercial, i.e. without paying and open) I would be grateful to hear about it.
April 13th, 2011 at 14:29
Apache (or httpd) is a nice piece of software. But because I’m also writing ASP.NET apps (and mod_mono isn’t mature enough) I’m right now using IIS (with PHP).
Share your thoughts, leave a comment!