I have been setting up a rock-solid server cluster for a client and ran into an interesting issue trying to install Phusion Passenger onto CentOS 5.2 on an x86_64 box (pretty stock config at the point of failure).
Installing the phusion pasenger gem went fine. but when running the passenger-install-apache2-module command, it crapped out on me telling me apache2 wasn‘t installed.
the tool tries to be helpful and tell you what is missing and how to install it, but in this case, it fails. It thought Apache2 was missing, but it wasn‘t. Turns out, there is an x86_64 library issues with another one of the components it had already decided was properly installed.
The solution?
yum install apr-devel
Even through apr-devel is already installed, only the i386 library is present. Sometimes the x86_64 versions of rpms still rely on the i386 versions for headers and such, so they are needed too. In this case, the i386 is installed, so passenger‘s install thought it was there, but a necessary x86_84 version of the package is also needed. we install it, and yum happily reports back:
Installed: apr-devel.x86_64 0:1.2.7-11
and now passenger installs just fine.
To be fair, this is probably an apache packaging issue. instaling the http-devel package on an an x86_64 box is smart enough to install the i386 and x86_64 versions of that rpm, and also the i386 versions or apr-util and apr-util-devel, but not the x86_64 versions… which brings me to my next discovery, you should probably also run
yum install apr-util-devel
While not necessary for passenger‘s install to be happy, seems to be it is a similar problem waiting for something else. You have all the i386 packages installed for http_devel, but are now missing this parallel x86_64 package. Sounds like a good thing to manually resolve.
