Apache and mod_gnutls
Filed under: apache gnutls dbmI had a client with a problem: Apache would suddenly become unresponsive, consuming all CPU and tons of memory. While this seemed to me like normal Apache behavior, apparently he found it unacceptable, so I was forced to investigate.
His Apache error log was filled with this message:
PANIC: fatal region error detected; run recovery
I googled this message but all I found were references to Berkeley DBM issues. This seemed odd as I wasn't aware of any DBM usage on his system. However I decided to grep his Apache configs and found this:
GnuTLSCache dbm /var/cache/apache2/gnutls_cache
Aha. I had set him up with mod_gnutls at some point while doing some SNI testing. I switched back to OpenSSL and the problem is solved.
Anyway, I'm writing this article in hopes it will prove useful to others, since it's always nice to google an error message and find the actual cause.







mod_gnutls version 0.5.10: fixes the memory consumption bug.
For correctly configuring mod_gnutls' Cache, please refer to: http://modgnutls.sourceforge.net/downloads/docs/mod_gnutls_manual-0.1.html
Basically your options are: dbm | gdbm | memcache | none
Also, you might have to delete & re-create the Cache File.
Hope this helps.