Experimental Project

This is a sandbox project, which contains experimental code for developer use only.

Memcache

The Memcache module is a fork of
http://drupal.org/project/memcache

With several performance improvements.
This improvements going to cost of some functions.

You can not further use wildcards in cache_clear_all().
But i dint found anny modules with use this feature.

In a cluster it could get problems will writing cause of the key exist cache "memcache_bins"
But on our 3 WebServer instance there we currently may not find problems.

For php there are 2 memcache modules "memcache" and "memcached"
For max performance use "memcached" + "igbinary", if you run into odd problems with huge caching pages.
Better use "memcache" but dont use the debian version. Use a self compiled downgrade.
http://pecl.php.net/get/memcache-2.2.6.tgz
The actual one is faster but, we got big problems will saving (loose complete nodes)

To use memcache: add to your settings.php

$conf['memcache_servers'] = array('127.0.0.1:11211' => 'default');
$conf['cache_inc']   = './sites/all/modules/memcache/memcache.inc';

Session

Another big improvement is the file system based session handler.
Cause a db update request for each page request from each user force each db server into knee.
And with this session handler you store the session on local file system and not to db.
With helps you to distribute the performance better to the single servers.

But by using this session handler you loose the "current not logged in user" counter. Cause each Server in cluster count for it self.

To use sessions: add to your settings.php

$conf['session_inc'] = './sites/all/modules/memcache/default-php-session.inc';

And add a cron job to cleanup old sessions

# Look for and purge old sessions every 30 minutes
10,40 *     * * *     root   [ -x /usr/lib/php5/maxlifetime ] && [ -d /var/lib/php5 ] && find /tmp/ -type f -iname "session_*" -cmin +$(/usr/lib/php5/maxlifetime) -delete
12,42 *     * * *     root   [ -x /usr/lib/php5/maxlifetime ] && [ -d /var/lib/php5 ] && find /tmp/ -type f -iname "user_sess_*" -cmin +$(/usr/lib/php5/maxlifetime) -delete

Caching

To get another bit of performance appy the 2 patches.
This will add 2 big caching systems. With helps drupal 6 to handle to work with alot of modules
For Drupal 6.22

patch includes/boostrap.inc < boostrap.inc.patch
patch includes/module.inc < module.inc.patch

Maintainers for memcache, session and other performance issues

Issues for memcache, session and other performance issues

To avoid duplicates, please search before submitting a new issue.
All issues
Bug reports
Statistics (2 years)
New issues
Open bugs
Participants
nobody click here