0

my environment

ubuntu 14.04 , php 5.5 , nginx 1.76

i am using both opcache and xcache concurrently

PHP 5.5.19-1+deb.sury.org~trusty+1 (cli) (built: Nov 19 2014 19:33:43) 
Copyright (c) 1997-2014 The PHP Group
Zend Engine v2.5.0, Copyright (c) 1998-2014 Zend Technologies
    with XCache v4.0.0-dev, Copyright (c) 2005-2013, by mOo
    with Zend OPcache v7.0.4-dev, Copyright (c) 1999-2014, by Zend Technologies
    with XCache Optimizer v4.0.0-dev, Copyright (c) 2005-2013, by mOo
    with XCache Cacher v4.0.0-dev, Copyright (c) 2005-2013, by mOo
    with XCache Coverager v4.0.0-dev, Copyright (c) 2005-2013, by mOo

i am just wondering can i use both opcache and xcache at the same time .. i dont know whether this allowed or not ? I know that both do almost the same job, but not sure if that would make any difference on the performance and speed.

suggestions invited ? so can i use both ?

doydoy44
  • 5,720
  • 4
  • 29
  • 45
Dev
  • 371
  • 1
  • 4
  • 19
  • 1
    Using two opcaches at the same time is almost certainly going to cause conflicts, and there isn't really any reason I can think of to try using two opcaches at the same time – Mark Baker Dec 31 '14 at 13:30
  • No you can't use Opcache and Xcache together, so don't even try. – TerryE Dec 31 '14 at 16:23
  • thanks for your replies. So i should not use both together – Dev Dec 31 '14 at 16:38
  • @TerryE can i use both opcache and memchached together ? – Dev Dec 31 '14 at 16:51
  • Yes, or even Opcache, APCu and memcached. Opcache is a opcode cache only -- that is it caches the compiled output from the PHP internal compile phase. APCu and memcached are *data* caches; the former is in-process using an SMA; and the latter out of process. – TerryE Jan 01 '15 at 18:12

1 Answers1

0

I have similar environment (Ubuntu 14.04, PHP 5.6, XCache 3.2, Apache). In my tests when Zend and XCache enabled, the response time is the same of the XCache only. When I disable XCache, and use only Zend OPcache the time resquest reduced in 10ms. Maybe you be try OPCache + Redis (for variables), or use only XCache if the time response not make diference for you.