How to Install Zend Optimizer

Please note that Zend Optimizer is only available up to PHP 5.3. For newer versions, this function is performed by Zend Guard Loader.
First, check whether Zend Optimizer is already installed on the server. To do this, run
php -m | grep Zend
If nothing is found, proceed with the installation.
First, find out which operating system your server runs and whether it is 32-bit or 64-bit:
cat /etc/issue
– the command to find out the operating system.
uname -m
– to find out whether it is 32-bit or 64-bit.
How to install Zend Optimizer on Debian
1. Download the distribution for your operating system:
wget http://downloads.zend.com/optimizer/3.3.9/ZendOptimizer-3.3.9-linux-glibc23-i386.tar.gz
- for 32-bit operating systems,
wget http://downloads.zend.com/optimizer/3.3.9/ZendOptimizer-3.3.9-linux-glibc23-x86_64.tar.gz
- for 64-bit ones.
2. Then unpack the archive:
tar xzvf Zend*
3. Find out the PHP version with the command
php -v
And copy the required ZendOptimizer module to the folder where the PHP modules are located.
For PHP 5.2
For 32-bit systems:
cp ZendOptimizer-3.3.9-linux-glibc23-i386/data/5_2_x_comp/ZendOptimizer.so /usr/lib/php5/modules/
For 64-bit systems:
cp ZendOptimizer-3.3.9-linux-glibc23-x86_64/data/5_2_x_comp/ZendOptimizer.so /usr/lib/php5/modules
4. Add the path to the Zend Optimizer module to the PHP configuration.
For 32-bit systems:
echo "zend_extension=/usr/lib/php5/ZendOptimizer.so" >> /etc/php5/conf.d/zend.ini
For 64-bit systems:
echo "zend_extension=/usr/lib64/php/modules/ZendOptimizer.so" >> /etc/php5/conf.d/zend.ini
5. Restart the Apache server (service apache2 restart).
How to install Zend Optimizer on CentOS
1. Download the distribution for your operating system.
For 32-bit systems:
wget http://downloads.zend.com/optimizer/3.3.9/ZendOptimizer-3.3.9-linux-glibc23-i386.tar.gz
For 64-bit systems:
wget http://downloads.zend.com/optimizer/3.3.9/ZendOptimizer-3.3.9-linux-glibc23-x86_64.tar.gz
2. Then unpack the archive:
tar xzvf Zend*
3. Find out the PHP version with the command
php -v
And copy the required ZendOptimizer module to the folder where the PHP modules are located.
For PHP 5.2
For 32-bit systems:
cp ZendOptimizer-3.3.9-linux-glibc23-i386/data/5_2_x_comp/ZendOptimizer.so /usr/lib/php/
For 64-bit systems:
cp ZendOptimizer-3.3.9-linux-glibc23-x86_64/data/5_2_x_comp/ZendOptimizer.so /usr/lib64/php/modules/
4. Add the path to the Zend Optimizer module to the PHP configuration.
For 32-bit systems:
echo "zend_extension=/usr/lib/php/ZendOptimizer.so" >> /etc/php/conf.d/zend.ini
For 64-bit systems:
echo "zend_extension=/usr/lib64/php/modules/ZendOptimizer.so" >> /etc/php.d/zend.ini
5. Restart the Apache server (/etc/init.d/httpd restart).
If you don't have time to do this yourself, use the services of professionals. UkrHost is one of the best hosting providers in Ukraine!