Log in

No account? Create an account
Lord Yupa

February 2010

Powered by LiveJournal.com
Frog Wizard

Oracle + PostgreSQL + PHP == huge pain

This just boggles the mind. This should absolutely not be this difficult, complicated, or frustrating.

At work, I need a web server (RHEL4) with PHP installed, along with the support libraries for PostgreSQL and Oracle. With the stock RPMs for PHP, adding PostgreSQL support is a piece of cake, you just install the PostgresSQL client libraries and php-pgsql.

So then I go to add Oracle support. I download the Oracle instantclient libraries (we're not running a database on this box, just connecting to an existing one), and figure there's probably a php-oracle or php-oci8 RPM from Oracle to add the PHP glue, right? Wrong. All of the documentation from Oracle describes how to take your RHEL4 box, download Apache, from source, download PHP, from source, and then recompile both.

What the hell? I'm going to have to duplicate this on a dozen machines, and then maintain them. In this day and age of software management, why in the hell am I supposed to recompile major parts of the system from source? And for one little oci8.so? Is this a joke?

So then I find Zend Core, which advertises it's "Universal Database Support", and built-in Oracle module. Wow! Cool! That'll solve this. . . assuming I don't mind using an alternately supplied install of PHP that will no longer be supported with security fixes from my OS vendor, nor do I have any kind of upgrade roadmap for it. But at least I have Oracle and Postgres support, right? Well, erm, no. Actually, the "Universal Database Support" just means that it supports the big guys with money, like Oracle, IBM DB2, and SQL Server. Oh, and MySQL. Wait, what's the obvious exclusion? Where's PostgreSQL? And Zend Core is a binary install, so I can't recompile it to add PostgreSQL support, even if I wanted to?

I went through some crap like this back when I was trying to get Oracle support compiled for Perl a year or two ago, though I'd forgotten how annoying it is. It honestly makes me wonder how in the hell Oracle ever managed to convince anyone to develop against them. This is just asinine.

At this point, I'm really annoyed at Oracle for not offering a php-oci8 RPM from their freakin' "PHP for Oracle" portal page, and at Zend for making it really hard to add any additional extensions that they don't feel you need.
Tags: , ,


It is my considered technical opinion that the Zend people are, if you'll pardon my French, fucking idiots.

Zend. . .

It is my considered technical opinion that you are correct, Sir.


You're in luck

You can download the Oracle PHP RPMs here:


We have just released them. :-)

Please give us feedback on the OTN PHP discussion forum or through the mailing list if you have any problems or questions.


Re: You're in luck

Wow. That's very cool.

Now I just have to figure out how to get you to read my mind the next time I'm dealing with a difficult problem like this, so you can point me at the fix before I spend half a day on it (and then eventually post a journal entry on it). ;-)

Thanks a lot for the tip, I'll definitely be giving this a shot tomorrow.


Re: You're in luck

Its only taken me a few hours to find the link to this page, but having found it I have to say it was like landing in heaven - now have PHP and Oracle installed in RHEL5, just need to test it all out now.

Many Thanks.


We're not so bad after all, hey?

We've (Oracle) done a lot of work with the PHP community over the last couple of years, and I think we're much easier to work with nowadays. If there's anything else you want, just let us know on the OTN PHP discussion forum.

Links to lots of Oracle/PHP material is here, including my blog and the discussion forum:


As for mind reading, I'm trying, but I still can't quite get through the static of all these wireless networks. :-)