Drupal 6. Quick organization of simple caching

    I looked on Habré and did not find anything about the use of such a Drupal module as cacherouter . I correct this misunderstanding, because This module allows you to significantly accelerate the work of Drupal even on such a demanding hosting as Majordomo (likes to disconnect the entire account when the load is exceeded).

    The module itself does not present anything new and cardinal - it only allows you to transfer cache tables from the database to other repositories, such as the file system, memcache, APC, etc.

    I, of course, have long been concerned about the question ... what Drupal developers put the cache in DB, but the story is not about that.

    So what do we have in terms of cacherouter capabilities?
    If you go to the module page using the link above, we get this list of additional repositories:
    • APC
    • Database
    • eAccelerator
    • File
    • Memcache
    • Memcached (Alpha)
    • XCache

    In my projects, I used only caching to the file system, so I will only talk about it.

    To start the module, perform the following steps:
    1. download and install the module in a standard way (I won’t talk about this standard action);
    2. Add the following settings to settings.php: change them according to your needs. In bold, I highlighted the changes to enable the file cache in the standard settings from the module page. 3. create a directory for writing cache files and give it the appropriate rights (you can simply 0777) After that, go to the admin panel, turn on the cacherouter in the modules, then turn on caching in "Settings", "Performance", then delete the cache and enjoy life.
    $conf['cache_inc'] = './sites/all/modules/contrib/cacherouter/cacherouter.inc';
    $conf['cacherouter'] = array(
    'default' => array(
    'engine' => 'file',
    'servers' => array(),
    'shared' => TRUE,
    'prefix' => '',
    'path' => 'sites/default/files/filecache',
    'static' => FALSE,
    'fast_cache' => TRUE,

    My projects then began to produce pages almost instantly.

    Also popular now: