[CentOS7] Redis 설치 및 php연동
LEMP Stack 의 경우 링크 사이트를 참고해 주세요. http://docs.crois.net/linux/linux/#lemp-stack
LEMP Stack 이후 부터 설치 하시면 됩니다.
Source 로 설치 하는 방법도 있지만 간단하게 yum 으로 설치 하는 방법을 기술 합니다.
Redis 의 자세한 내용은 차후 정리 하도록 하겠습니다.
- Redis 설치
[root@centos-nginx ~]# yum install -y redis php71-php-pecl-redis php71-php-phpiredis php-redis
- 설치확인
[root@centos-nginx ~]# php -i |grep redis /etc/php.d/50-redis.ini redis redis.arrays.algorithm => no value => no value redis.arrays.auth => no value => no value redis.arrays.autorehash => 0 => 0 redis.arrays.connecttimeout => 0 => 0 redis.arrays.consistent => 0 => 0 redis.arrays.distributor => no value => no value redis.arrays.functions => no value => no value redis.arrays.hosts => no value => no value redis.arrays.index => 0 => 0 redis.arrays.lazyconnect => 0 => 0 redis.arrays.names => no value => no value redis.arrays.pconnect => 0 => 0 redis.arrays.previous => no value => no value redis.arrays.readtimeout => 0 => 0 redis.arrays.retryinterval => 0 => 0 redis.clusters.auth => no value => no value redis.clusters.cache_slots => 0 => 0 redis.clusters.persistent => 0 => 0 redis.clusters.read_timeout => 0 => 0 redis.clusters.seeds => no value => no value redis.clusters.timeout => 0 => 0 redis.pconnect.connection_limit => 0 => 0 redis.pconnect.pooling_enabled => 1 => 1 redis.session.lock_expire => 0 => 0 redis.session.lock_retries => 10 => 10 redis.session.lock_wait_time => 2000 => 2000 redis.session.locking_enabled => 0 => 0 Registered save handlers => files user redis rediscluster This program is free software; you can redistribute it and/or modify [root@centos-nginx ~]#
- php-fpm 데몬 재시작
[root@centos-nginx ~]# systemctl restart php-fpm
- phpinfo 페이지 확인