Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I use the following set up:

  • PHP Version 5.2.17
  • Apache/2
  • Zend Optimizer v3.3.3
  • Drupal 7.8

As far as I read other articles and questions, Zend Optimizer doesn't do any good neither for PHP5 nor for D7.

I would like to use APC as PHP cache but APC is not compatible with Zend Optimizer.

Can I disable Zend Optimizer for selected subdomains ?


  • redirects to an app that requires Zend Optimizer
  • redirects to a Drupal app that doesn't require Zend Optimizer (I would like to disable Zend Optimizer for this subdomain)
share|improve this question
up vote 1 down vote accepted

Webhosting talk seems to think you may be able to use the php_value flag in your .htaccess (or VirtualHost def) in order to selectivly disable it in certain hosts:

php_value zend_optimizer.optimization_level = 0

share|improve this answer
Thank you, I tried this on one subdomain and included php_value in my .htaccess but it didn't help disable Zend Optimizer I am afraid. – Refineo Sep 21 '11 at 17:40
I checked this again and used this php_value in php.ini instead of .htaccess then after httpd -k restart it disabled all Zend Optimizer optimization passes but this was for the whole server not for one subdomain. I am looking further for a solution. – Refineo Sep 21 '11 at 18:16
I've tried it again in my .htaccess but without success. What should be done in order to enable setting php_value in .htaccess ? – Refineo Sep 21 '11 at 20:17
Instead of putting it in your .htaccess, try php_admin_value in your virtual host definition. Some settings are restricted to where they can be set from; the php/zend documentation leaves a bit to be desired on this front, unfortunately! – Kirrus Sep 21 '11 at 22:23

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.