安装源
yum install epel-release
rpm -ivh http://rpms.famillecollet.com/enterprise/remi-release-7.rpm
安装PHP
yum --enablerepo=remi install php74-php php74-php-cli php74-php-common php74-php-fpm php74-php-gd php74-php-mbstring php74-php-mysql php74-php-pdo php74-php-pear.noarch php74-php-pecl-imagick php74-php-process php74-php-xml php74-php-intl
查看版本
php74 -v
设置开机启动
systemctl enable php74-php-fpm
配置
如果使用NGINX,需要修改文件 /etc/opt/remi/php74/php-fpm.d/www.conf
user = nginx
group = nginx
listen = 127.0.0.1:9000
listen.owner = nobody
listen.group = nobody
listen.mode = 0660
启动
systemctl restart php74-php-fpm
查看是否已启动
netstat -anp | grep 9000
Hits: 4083