How to segfault Apache 2+ with mod_security

Build mod_security against the wrong set of headers, and Apache 2 will mysteriously begin to segfault in a persistent manner. Check which version you’re running with dpkg --get-selections | grep apache2.

Seems my shiny new Debian distro running the prefork version of Apache had the threaded (worker) headers installed against it. Duh. apt-get install apache2-prefork-dev reinstalled the correct prefork headers and Apache is happy again.

Mathiew Dessus has a great article about installing mod_securty on Debian for those interested.

The MySQL extension (php_mysql.dll) won’t load after upgrading PHP

Ugh. As usual, more weird problems while trying to upgrade PHP on a Windows box. Are we having fun yet?

If you find that the MySQL extension won’t load, then probably a previous PHP installer has placed a version of libmysql.dll somewhere else in your path. Look in c:\WINDOWS\system32\

The problem is almost certainly the reason for the following obscure comment

Although copying libmysql.dll to the Windows system directory also works (because the system directory is by default in the system’s PATH), it’s not recommended.

in the PHP MySQL documentation.

Make sure your home PHP directory is in your path, and that its finding libmysql.dll there and only there.

500 Can’t locate object method “configure” via package “Net::HTTP”

If you’re seeing this error from mod_perl, then probably your CPAN repository has changed. Try restarting Apache so that mod_perl can find everything again.

If you’ve upgraded Apache, you may need to rebuild mod_perl, depending on your deployment.

Anyway, don’t do what I did and waste half-a-day trying to debug the Perl when a simple boot to Apache’s head will show you what’s really going on.

Advanced Outlook Repair Crash

Well, for whatever reason AOR crashed when I tried to run the licensed version. Fortunately the kind souls at DataNumen let me upload my archive to their FTP server and did the repair for me.

When I asked why AOR wasn’t working here, I got the standard “must be your machine” answer:

Sorry but we don’t know the reason, as we cannot repeat the problem on our computers at all. We have used Advanced Outlook Repair to repair your file without any problems!

I guess the problem may be caused by incompabilities, but our computer installed with Vista and 2007 can also run correctly. So the problem may be related to other software or system confirgurations.

So with some good support here the results are what I was after.. though buyer beware.

Recovering impossibly corrupted Outlook email…

I’ve been through two fairly serious hard drive crashes over the last four months. This last one a few weeks ago was a doozy; even IBM’s (Lenovo’s?) wonderful little Rescue and Recovery app gave up hope.

Here’s how I recovered (mostly) what seemed to be some unrecoverable .pst email archives:

  1. When your disk appears to be beyond repair, check out the fantastic and free TestDisk. If the data is out there, TestDisk will find it. Boot from a DOS disk if, like me, your operating system is gone.
    • To grab files via TestDisk, run the app, select your disk, and go to Analyze. Continue through the partition summary screens, highlight the partition you want, and select “P” to list files. From here you can traverse the directory tree and copy “C“the files you want to rescue.
    • Under Vista, the Outlook .pst files will typically be under C:\Users\<User_Name>\AppData\Local\Microsoft\Outlook\
    • Be sure to copy to a destination drive with plenty of space. Most USB drives should be recognized these days, even when booting from DOS.
  2. Once you’ve got your (probably mangled) .pst file safely on a new disk, you’ll want to try to de-mangle it of course. There are a number of apps out there for this. Here are the ones with which I experimented:
    • Advanced Outlook Repair (~$250 USD)
      Recovered and/or identified over 800 messages as well as over 500 disembodied attachments (stored in a directory of their own). Unlike some of the other apps below, most of the attachements would appear to be intact. Some of the original folders are preserved. Unicode not supported.
    • Disk Doctors Outlook Mail Recovery
      Creates a new profile containing recovered messages in the Inbox as well as a new .pst file. Though the interface is clumsy, the Disk Doctors did manage to recover over 400 messages.
    • Kernel for Outlook (~$50 USD)
      Failed to recover anything. Clone of RecoveryFix below.
    • OutlookFIX Pro (~$200 USD)
      Great demo interface shows full text of messages (save is disabled), but only discovered about 100 messages in my case. Unicode not supported.
    • Outlook Recovery Toolbox (~$50 USD)
      Couldn’t really get this to work. Crashed on save and had to kill the process from the Task Manager.
    • PSTStation (~80 EUR)
      Appears as though it tried to repair the .pst directly but without luck.
    • RecoveryFix for Outlook (~$80 USD)
      Failed to recover anything. Clone of Kernel above
    • Recovery for Outook (~$250 USD)
      Recovered over 400 messages as well as identified and or recovered over 300 disembodied attachments (stored in a directory of their own; many corrupt). Not much is left of the original folder structures. Unicode supported!
    • R-Mail for Outlook (~$115 USD)
      Recovered some uncategorized folders, but only one message per folder. (Not sure if this is a limitation of the demo mode or not.)
    • Stellar Mailbox Professional (~$130 USD)
      Nice interface. Recovered over 400 messages. Unicode not supported.

Interestingly, all of the above seemed to recover different sets of email (if they could recover anything at all…) In the end I went with Advanced Outlook Repair given that only a small subset of my emails are Unicode (Japanese). Take a look at Recovery for Outlook if you need Unicode support.

If you just want to see what you might be lurking in your .pst archive, OutlookFIX’s demo will allow you to get a complete peak at the content of many recoverable messages.