I want to implement the caching on my site.I am trying to implement the memcache but its not working.Following is the code i am trying to implement.If i use File,apc its woking fine but when i m using memcache is not working.so friend's please help to figure out my mistake.
$frontendOpts = array(
'caching' => true,
'lifetime' => 1800,
'automatic_serialization' => true
);
$backendOpts = array(
'servers' =>array(
array(
'host' => 'localhost',
'port' => 11211
)
),
'compression' => false
);
$cache2 = Zend_Cache::factory('Core', 'Memcache', $frontendOpts, $backendOpts);
//$cache2 = Zend_Cache::factory('Core', 'File', $frontendOpts, $backendOpts);
Zend_Registry::set('Memcache', $cache2);
when i use following command in linux ps -A | grep memcached
13451 pts/2 00:00:00 memcached //following is the result
So i suppose that memcached is install on my server.

New Topic/Question
Reply



MultiQuote



|