Running Drupal 7 on shared hosting
As I’ve recently disovered to my cost, a pretty bog-standard Drupal 7 install doesn’t play nice with a shared hosting package I’m using – and it doesn’t appear I’m alone in the situation I find myself in.
I’ve used Drupal 6 for my last 5-6 jobs (on many different types of large-scale hosting environments), as well as many freelance projects that are predominantly hosted on shared environments. Load times for the latter (with Drupal cache_page enabled) were surprisinly impressive. I recently undertook a re-design of my Mum’s (who practices , UK) site, and decided to give Drupal 7 a go, after reading some of the theming improvements. However, load times were extremely poor; around 2-3 second page generation, and 2 seconds through cache_page. But surely you could use a caching module to improve performance, no?
The Boost module
I’ve used Boost a couple of times before when embarking on freelance projects. I can categorically say, that apart from the modules for D6 that have since made core in D7 (CCK, image cache, etc), it’s one of the most useful modules available. Essentially, it supersedes the core Drupal cache_page mechanism, by bypassing the need for PHP processing and associated database calls altogether, by caching page requests into static HTML files (gzip’ped versions are also generated for browsers that support gunzip
). Requests are served purely through mod_rewrite (Drupal clean URLs is a prerequisite for the module), meaning that anonymous users are served static files.
One really useful feature of the D6 version of Boost, is that it incorporates it’s own crawler, giving you the ability to preemptively cache pages in your url_alias
table on cron jobs. The issues with the Drupal 7 version, is that it doesn’t include a crawler, meaning that unless you hack a makeshift script, then you’re reliant on anonoymous users hitting your pages, thus invoking Boost’s caching mechanism. This wouldn’t be such an issue if load times weren’t so hideous, but I’m simply not prepared for any user to wait around 2 seconds per page load.
Of course, my mother could invest in a small-scale VPS, but I’m of the opinion that version releases of a CMS shouldn’t dictate the specification of the environments they can run on. Drupal has of course got a lot more enterprise-level exposure recently, and that’s no doubt a good thing, but it needs to remain a viable solution for small-scale sites too.
Comments are closed.