리눅스 php 성능향상(가속) eAccelerator 설치
본문
소스 다운로드, 압축해제
# wget https://github.com/eaccelerator/eaccelerator/tarball/master # tar jxvf master |
환경 변수 설정, 설치
해당 디렉토리로 이동하여
# phpize |
이 때 명령이 없다고 뜨면
# sudo apt-get install php5-dev # cat /etc/apache2/envvars | grep USER= # ./configure --enable-shared --with-php-config=/usr/bin/php-config --with-eaccelerator-userid=www-data configure: creating ./config.status config.status: creating config.h config.status: executing libtool commands
# make # make install Installing shared extensions: /usr/local/php-5.2.17/lib/php/extensions/no-debug-non-zts-20060613/ |
php 설정 파일에 추가
# vi /etc/php5/apache2/conf.d/99-eaccelerator.ini |
[eaccelerator] extension="eaccelerator.so" eaccelerator.shm_size="16" eaccelerator.cache_dir="tmp/eaccelerator" eaccelerator.enable="1" eaccelerator.optimizer="1" eaccelerator.check_mtime="1" eaccelerator.debug="0" eaccelerator.filter="" eaccelerator.shm_max="0" eaccelerator.shm_ttl="0" eaccelerator.shm_prune_period="0" eaccelerator.shm_only="0" eaccelerator.compress="1" eaccelerator.compress_level="9" |
apache 재시작
# /etc/init.d/apache2 restart |
php 버전 확인
# php -v |
PHP 5.3.10-1ubuntu3.8 with Suhosin-Patch (cli) (built: Sep 4 2013 20:00:51) Copyright (c) 1997-2012 The PHP Group Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies with eAccelerator v1.0-dev, Copyright (c) 2004-2012 eAccelerator, by eAccelerator |
댓글목록
등록된 댓글이 없습니다.