Apple Releases Security Update 2008-007 and Breaks my Apache

As soon as I installed the Apple Security Update 2008-007 this afternoon, restarted and re-opened firefox to all my previous tabs I knew something was upĀ  when my localhost suddenly wasn’t responding.

According to Apple, this fix updates to a new version of Apache 2:

Apache is updated to version 2.2.9 to address several vulnerabilities, the most serious of which may lead to cross site request forgery.

In order to get Apache Running, the first thing I tried was openening System Preferences and enabling/disabling web sharing a couple of times – which did nothing.

Second thing was trying to run httpd from the command line. Again, no success but it gave me some useful errors. For some reason it was attempting to load some old set of config files that I hadn’t used for ages – so I promptly removed those and solved those ‘syntax errors’ (cleanups are good!)

Once my config files were in order, I was back to square one with this error…

httpd: Syntax error on line 116 of /private/etc/apache2/httpd.conf: Cannot load /usr/libexec/apache2/libphp5.so into server: dlopen(/usr/libexec/apache2/libphp5.so, 10): no suitable image found.  
Did find:\n\t/usr/libexec/apache2/libphp5.so: mach-o, but wrong architecture

All this meant was that the compiled version of PHP5.3 I had (see my other post on running php 5.3) was compiled at 32bit, and Apple had set Apache back to 64Bit. Two commands solved this problem…

sudo cp /usr/sbin/httpd /usr/sbin/httpd-fat
sudo lipo /usr/sbin/httpd -thin i386 -output /usr/sbin/httpd

Note that the first command simply backs up httpd.

Since I’ve got web-sharing enabled, I assume that there’s some system that keeps track of the httpd processes, – as soon as killed the running 64bit httpd processes in Activity Monitor, it all seemed to be working again.

Just one note here: I did re-compile PHP again with the command line I posted earlier. There were no errors, and no differences so I don’t think that it was necessary, but I did try it.

Share this article:
  • Digg
  • del.icio.us
  • Facebook
  • Google Bookmarks
  • LinkedIn
  • DZone
  • Furl
  • Ma.gnolia
  • NewsVine
  • Reddit
  • Slashdot
  • StumbleUpon
  • Technorati
This entry was posted in Everything Everything and tagged , , . Bookmark the permalink.

One Response to Apple Releases Security Update 2008-007 and Breaks my Apache

  1. jmar says:

    Hi,
    I use entropy’s php package, and all I did was issue the 2 commands you suggested:
    sudo cp /usr/sbin/httpd /usr/sbin/httpd-fat
    sudo lipo /usr/sbin/httpd -thin i386 -output /usr/sbin/httpd

    and all was completely back to normal! Thanks a bunch for this. My sites are all back to normal.
    Jim

Leave a Reply