银河麒麟下载地址 兆芯 arm 架构64
点击下载
安装lnmp
下载相关文件
链接:https://pan.baidu.com/s/1YqFLfGpE5DP3Sf_2GsXqNg?pwd=ptsn
–来自百度网盘超级会员V7的分享
上传到服务器
我所选择上传的地方是 /home/npf/nginx-server
, php
放在跟nginx-server
的同级目录
cd /
mkdir home /home/npf cd /home/npf
mkdir nginx-server cd nginx-serve
解压所有的软件
tar -xvf pcre-8.38.tar
tar -xvf openssl-1.0.2n.tar
tar -xvf zlib-1.2.11.tar
tar -xvf nginx-1.8.1.tar
编译安装相关配置文件
cd pcre-8.38
./configure
make
make install
cd ..
cd openssl-1.0.2n
./config
make
make install
cd ..
cd zlib-1.2.11
./configure
make
make install
cd ..
cd nginx-1.8.1
./configure --prefix=/home/npf/nginx-server --with-pcre=/home/npf/nginx-server/pcre-8.38 --with-openssl=/home/npf/nginx-server/openssl-1.0.2n --with-zlib=/home/npf/nginx-server/zlib-1.2.11
make
make install
make nginx 报错一
src/core/ngx_murmurhash.c: 在函数‘ngx_murmur_hash2’中:
src/core/ngx_murmurhash.c:37:11: 警告:this statement may fall through [-Wimplicit-fallthrough=]
h ^= data[2] << 16;
~~^~~~~~~~~~~~~~~~
src/core/ngx_murmurhash.c:38:5: 附注:here
case 2:
^~~~
src/core/ngx_murmurhash.c:39:11: 警告:this statement may fall through [-Wimplicit-fallthrough=]
h ^= data[1] << 8;
解决办法
cd /home/npf/nginx-server/nginx-1.8.1/objs
vim Makefile ## 第三行左右删除 error
# CFLAGS = -pipe -O -W -Wall -Wpointer-arith -Wno-unused error -g 删除掉
# CFLAGS = -pipe -O -W -Wall -Wpointer-arith -Wno-unused -g 删除之后的
makenginx
报错 二
src/core/ngx_murmurhash.c: 在函数‘ngx_murmur_hash2’中:
src/core/ngx_murmurhash.c:37:11: 错误:this statement may fall through [-Werror=implicit-fallthrough=]
h ^= data[2] << 16;
~~^~~~~~~~~~~~~~~~
src/core/ngx_murmurhash.c:38:5: 附注:here
case 2:
^~~~
src/core/ngx_murmurhash.c:39:11: 错误:this statement may fall through [-Werror=implicit-fallthrough=]
h ^= data[1] << 8;
~~^~~~~~~~~~~~~~~
src/core/ngx_murmurhash.c:40:5: 附注:here
case 1:
cd /home/npf/nginx-server/nginx-1.8.1/src/os/unix
vim ngx_user.c
## 大概在36 行左右
## 注释掉这行代码 /*cd.current_salt[0] = ~salt[0];*/
继续make
把php
安装包移动到跟nginx
同级目录
tar-xf php-7.02
cd php-7.02
./configure --prefix=/home/npf/php-7.0.2 --with-config-file-path=/home/npf/php-7.0.2/etc --with-config-file-scan-dir=/home/npf/php-7.0.2/etc/php.d --enable-mysqlnd --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd --enable-fpm --with-fpm-user=www --with-fpm-group=www
make
make install
cd etc
# php-fpm.conf 把这个复制进去
cd php-fpm.d
cp www.conf.default www.conf
groupadd www
useradd -g www www
启动数据库
systemctl start mariadb
systemctl enable mariadb #开机自启
#进入数据库
mysql -uroot
use mysql; #表
#更新数据库密码
update user set password=password("数据库密码") where user="root";
#开启远程访问,密码是远程访问的密码
grant all privileges on *.* to 'root'@'%' identified by '密码';flush privileges;
# 刷新表
flush privileges;
离线安装chrome
安装包链接:https://pan.baidu.com/s/1RXWXKS_qzZJoHWzwpIxRKw?pwd=yydt
官方:Google Chrome 网络浏览器 (gooogleweb.com)
下载完成拖动进去
# 切换到安装路径
rpm -i 安装包名字