I was stuck re-compiling Apache today to enable support for mod_proxy so I could pass requests through our existing webserver seamlessly to our new PHP5-sporting webserver. Of course I decided to make some other “optimizations” along the way with our Apache configuration, so I ended up breaking everything.

Recompiling Apache threaded of course required that I recompile PHP so it had thread support, and recompiling PHP meant I had to re-tackle the problem of Oracle support in PHP which has always been quite shady anyway.

To make a long story short, one of the things I needed to know was which parameters to pass into each ./configure command. PHP’s handy-dandy phpinfo(); page shows you the configure command used, but I didn’t know off hand how to find out which parameters Apache had been built with.

After poking around in the Apache root directory, I found my answer. Apparently the Apache configure command saves a pretty format of itself every time it’s compiled. On our box at work, I found it in <server_root>/build/config.nice - I presume it’s in a similar location for everyone.

For anyone wondering, yes, I did get mod_proxy up and running, and everything works like a charm. I’ll probably toss together another quick entry tomorrow about our specific use case, since I had to piece together all the information I found from dozens of different sites, none of which seemed to have the whole picture.

In the mean time, happy compiling!

Originally published and updated .
comments powered by Disqus