216 questions

223 answers

12 comments

334 users

Welcome to OSSbible, where you can ask Open Source Products questions and receive answers from members of the community. OSSbible has very active & vibrant community members whose knowledge is unparalleled.

How to install opcache for php 5.5 version

+1 vote
asked Dec 1, 2015 in Linux by Stuart (510 points)

1 Answer

+1 vote
 
Best answer
Opcache Installation:-

Install

# Install "pecl" via php-pear

$ sudo apt-get install -y php-pear

# Install build dependencies

$ sudo apt-get install -y build-essential php5-dev

# Install Zend OpCache

$ sudo pecl install zendopcache-7.0.2

vim /etc/php5/fpm/php.ini

Enable the Opcache:-

opcache.enable=0 to  opcache.enable=1

;opcache.memory_consumption=64 to opcache.memory_consumption=128

;opcache.max_accelerated_files=2000 to opcache.max_accelerated_files=4000

;opcache_revalidate_freq = 2 to opcache_revalidate_freq = 240

php5enmod opcache

sudo service nginx restart

sudo /etc/init.d/php5-fpm restart
answered Dec 1, 2015 by prithvi (2,660 points)
selected Dec 1, 2015 by Stuart

Related questions

+3 votes
1 answer
asked Dec 1, 2015 in Linux by William (500 points)
+2 votes
1 answer
asked Dec 1, 2015 in Linux by William (500 points)
+4 votes
1 answer
+1 vote
1 answer
asked Feb 5, 2014 in Linux by ktreeadmin (460 points)
...