Memcached

Memcached

by Mr Blue -
Number of replies: 7

I have 2 application servers and a memcached server.. 

the following has been implemented in my config file..

$CFG->session_handler_class = '\core\session\memcached';  ** 

$CFG->session_memcached_save_path = '***.**.**.***';

$CFG->session_memcached_prefix = 'memc.sess.key.';

$CFG->session_memcached_acquire_lock_timeout = 120;

$CFG->session_memcached_lock_expire = 7200;       // Ignored if memcached extension <= 2.1.0


How can we confirm if Memcached is installed ?

Average of ratings: -
In reply to Mr Blue

Re: Memcached

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

Did you mean to use memcached for sessions (as opposed to the MUC)?

memcached has built in statistics that you can interrogate from the command line - Google 'memcached statistics'

In reply to Howard Miller

Re: Memcached

by Mr Blue -

Yes for session handling which is hopefully going to improve the performance in a multi-server environment.

On 2 off the app servers i have an application of moodle set up.. in both config files i have :


$CFG->session_handler_class = '\core\session\memcached';  ** 

$CFG->session_memcached_save_path = '***.**.**.***';

$CFG->session_memcached_prefix = 'memc.sess.key.';

$CFG->session_memcached_acquire_lock_timeout = 120;

$CFG->session_memcached_lock_expire = 7200;       // Ignored if memcached extension <= 2.1.0


I have the $CFG->session_memcached_save_path= 'set to the memcached server' when i run tcpdump port 11211 - i can see some activity 

$CFG->session_handler_class = '\core\session\memcached';  ** not quite sure what this is for ?

please advise...

In reply to Mr Blue

Re: Memcached

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

So - have you set up the MUC with its own memcached as well? That will make a substantially bigger difference than configuring the session handling. 

In reply to Howard Miller

Re: Memcached

by Mr Blue -

No i dont think so.. how do i go about doing that ?


In reply to Mr Blue

Re: Memcached

by Mr Blue -

We are currently using Moodle 2.7 and have been advised, to improve the performance of our multi-server environment memcached (which is supported) should be used.

We have taken steps to have our two app servers updated with Memcached and also a 3rd (stand alone server) also with memcached installed.

However i am not quite sure how to configure this altogether !

Any steps to proceed would be greatly appreciated !

Thanx