1,下载 php7文件
2,安装依赖库
yum -y install gcc-c++ gd zlib zlib-devel openssl openssl-devel libxml2 libxml2-devel libjpeg libjpeg-devel libpng libpng-devel
3,配置编译环境
./configure --prefix=“解压位置” --with-gd --enable-gd-jis-conv --enable-mysqlnd --with-pdo-mysql=mysqlnd --with-openssl --enable-mbstring --enable-fpm
make && make install
4,cp 源码./php.ini-development /usr/local/php/php.ini
cd /usr/local/php/etc
nginx 最终是要跟我们的 php-fpm 进程沟通,所以我们一起来测试下 php-fpm 应用能否启动.
cd ../sbin
./php-fpm
vim nginx.conf
mysql
[mysqld]
basedir = /usr/local/mysql
datadir = /usr/local/mysql/data
port = 3306
server_id = .....
socket = /usr/local/mysql/mysql.sock
user = mysql
[mysqld_safe]
basedir = /usr/local/mysql
basedir = /usr/local/mysql
datadir = /usr/local/mysql/data
port = 3306
server_id = .....
socket = /usr/local/mysql/mysql.sock
user = root
./bin/mysqld --initialize --user=mysql
/support-files/mysql.server start
./bin/mysql -u用户名 -p
mysql 远程访问
网友评论