Integrity constraint violations on the Drupal 7 block table Jul 20, 2015 One of our Drupal 7 sites was giving a lot of white pages of death. Looking through the Drupal logs we saw a lot of integrity constraint violations and decided to dive deeper in the code. It turns out it was quite a complex Drupal core problem but we managed to find a fix for it. ...
Reverse proxy configuration for Apache or nginx with varnish Jul 13, 2015 If you want to have the correct ip address in your Apache or nginx logs when running a Drupal 7 website with a varnish cache, you need to add some configuration to your server. This post shows you what to do. ...
Performance debugging basics: the MySQL slow log Jun 25, 2015 In this blog post I'll show you how simple and usefull the MySQL slow query log can be to find performance problems in a Drupal 7 site running a complex import task as a drush batch process. ...
Apache, Varnish, mod_deflate and 503 errors Jun 24, 2015 About 90% of the unexplainable Varnish 503 errors I've seen the last year have been caused by Apache having mod_deflate enabled while there's a varnish cache in front of it. ...
One hour of New Relic to solve a critical performance issue Jun 3, 2015 This post shows an example how easy it was to find a performance problem on a production website using New Relic's APM. ...
How to add useful logging to your Drupal 7 code May 24, 2015 In this blog post I will give you an overview how you should add proper logging to your Drupal 7 code. ...
Netiquette: email signature separator May 22, 2015 It’s time for another netiquette rant: There are way too many people not using the double dash marker as the first line of their email signature. The Usenet standards specify that a signature block should be delimited from the body of the message by a single line consisting of exactly two hyphens, followed by a space, followed by the end of line (i.e., “– \n”). This latter prescription, which goes by many names, including “sig dashes”, “signature cut line”, “sig-marker”, “sig separator” and “signature delimiter”, allows software to automatically mark or remove the sig block as the receiver desires. ...
Debugging Drupal 7 development May 17, 2015 There are a lot of ways to debug your Drupal code while developing or when it’s running on production. In this blog post I’ll give an overview of all the tools I’ve been using the past years, going from some simple Drupal or PHP commands to external web services. 1. Drupal and PHP commands The Drupal devel module The Drupal devel module is basically the first Drupal module you install when you are developing a new site. ...
Enforce SSL for an Apache vhost May 13, 2015 Here’s a proper way to enforce SSL with the apache2 web server, without hardcoding the ServerName in the config. You can also use this in a .htaccess file: <IfModule mod_rewrite.c> <IfModule mod_ssl.c> RewriteEngine on RewriteCond %{HTTPS} !^on$ [NC] RewriteRule . https://%{HTTP_HOST}%{REQUEST_URI} [L] </IfModule> </IfModule> You need the rewrite module and ssl module enabled (obviously), which can be easily enabled with the a2enmod commands: a2enmod ssl a2enmod rewrite
Drupal watchdog logging: dblog vs syslog May 12, 2015 Sometimes logging events to your Drupal database is not the best way to go and can be quite a performance killer. This is when you want to start using a syslog server. ...