Drupal 6, trying to get the Cache Backport module working. Every time I load a page, this error fires:

Call to undefined function _cache_get_object() in /var/www/sites/all/modules/cache_backport/cache_backport.admin.inc on line 60,

That is defined in cache.inc within the cache_backport module's folder. It would appear that the file isn't being loaded. Here's the relevant portion of my settings.php file.

$conf['cache_inc'] = 'sites/all/modules/cache_backport/cache.inc';

Simple enough.

I'm using the Domain module and looking around the config files, I did notice references to cache but I can't really tell their purpose. Also, and this may or may not be related, but prior to trying the cache backport module I tried just doing the Drupal 6 memcache module and it never seemed to send anything to it. The memcache area in Reports would load, it was communicating with Memcached, but it never seemed to write anything to it. I feel like it was caused by the same thing.

1 Answer 1


The Domain module was in fact responsible for this. I moved include './sites/all/modules/domain/settings.inc'; to the very end of my settings.php file and everything started working.

I then added the following code to ensure a different cache_prefix for each of the domains.

$thishost = $_SERVER['HTTP_HOST'];
$site_arr = explode('.', $thishost);
$sitename = $site_arr[1] . '_';
$conf['cache_prefix'] = $sitename;

Credit for that code goes to Drupal 6 APC with domain access module not working for (sub-)domains. In fact, now that I look at that page again, I notice that he has the domain access include on the last time, too. Audible sigh. Don't know how I didn't notice that before.

It also appears that if you want to move Domain's settings.inc to the bottom, you need to make a tweak to that file. Modify modules/domain/settings.inc so the domain_settings_setup_ok function looks like this:

function domain_settings_setup_ok() {
  static $state = NULL;
  if ($state === NULL) {
    if (!empty($conf['cache_include'])) {
      $state = TRUE;
    else {
      $state = !function_exists('cache_get');
  return $state;

That is an adapted version of the patch for D7 discussed at https://drupal.org/node/1240472.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.