• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Zend opcache question

#1
Hi,

I use PHP Version 5.6.12 and Zend Opcache is enabled.
Is there anything specific that I need to add to my config.php file for Xenforo? (I thought not but now I have a doubt).

All I have in my config.php is:
Code:
$config['cache']['enabled'] = true;
$config['cache']['frontend'] = 'Core';
$config['cache']['frontendOptions']['cache_id_prefix'] = 'xf_';
Screenshot_1.png

Am I missing something?

Thanks
 
#5
Ok, so Opcache works with PHP anyway.
So if I want even better cache I need to use memcached or APC (not sure if that works with PHP5.6 and my configuration. That's what you mean?
 
#13
I get much better results with redis instead of memcached for wp sites but redis is not officially supported in XenForo.
Can you quantify that?

Whenever I've benchmarked them, they're about equal, it's just redis was a lot more convenient to develop against because of all the extra data structures it supports.
 

Solidus

Well-known member
#14
Thanks all for your responses.
Would someone be able to share how they have their memchached configured in config.php?
Code:
$config['cache']['backend'] = 'Memcached';
$config['cache']['backendOptions'] = array(
    'compression' => false,
    'servers' => array(
        array(
            // your memcached server IP /address
            'host' => 'localhost',
           
            // memcached port
            'port' => 11211,
        )
    )
);
 

Puntocom

Well-known member
#16
Can you quantify that?

Whenever I've benchmarked them, they're about equal, it's just redis was a lot more convenient to develop against because of all the extra data structures it supports.
Just subjetive experience, I did not measure the performance scientifically. But it feels noticeably faster in my setup. Maybe the plugin affects this result (Redis object cache vs. Memcached is your friend). A good advantage of redis vs memcached is the persistence support, specially for small sites.
 
#17
I ended up with "An exception occurred: The memcache extension must be loaded for using this backend !"

I think that it would have been much clearer if the documentation said that memcache (without 'd') MUST be installed and loaded too.


I performed a quick test on server response time which I was hoping to improve a little bit but it turns out that it didn't help at all for response time to enable memcache (d).
 
Last edited:

Solidus

Well-known member
#18
I ended up with "An exception occurred: The memcache extension must be loaded for using this backend !"

I think that it would have been much clearer if the documentation said that memcache (without 'd') MUST be installed and loaded too.


I performed a quick test on server response time which I was hoping to improve a little bit but it turns out that it didn't help at all for response time to enable memcache (d).
Memcached helped more with page load times for me, no response times.
 
#19
I was about to add this. I think that there is an improvement in page loads yes, Not very much but it's there.
I'm still trying to find a solution to the server response time (not using a cheap server).