采用官方最新Nginx1.27.2版本。适用于国产化操作系统:银河麒麟V10版本,使用nginx-portable编译,默认路径为/app/nginx,如果从之前版本升级,建议检查路径是否一致,可以采用备份配置文件进行卸载之前的版本,然后安装此版本,或者使用软链接进行配置。后期nginx官方发布新版本后,博客会在第一时间进行编译升级。
适用于银河麒麟V10:
nginx-1.27.2.kylin.tar.gz
默认编译参数:
./configure --prefix=/app/nginx --with-http_realip_module --http-client-body-temp-path=tmp/client_body_temp/ --http-proxy-temp-path=tmp/proxy_temp/ --http-fastcgi-temp-path=tmp/fastcgi_temp/ --http-uwsgi-temp-path=tmp/uwsgi_temp/ --http-scgi-temp-path=tmp/scgi_temp/ --with-ipv6 --with-http_ssl_module --with-http_gzip_static_module --with-http_stub_status_module --with-http_v2_module --without-mail_pop3_module --without-mail_imap_module --without-mail_smtp_module --without-http_fastcgi_module > ../../logs/compile.log
程序内置nginx.service进行管理,请执行 bash start.sh 进行程序安装,然后可以使用service进行控制。
如何手动管理二进制包Nginx?
启动:./nginx 停止:./nginx -s stop 重启:./nginx -s reload 检查配置正确性:./nginx -t 查看Nginx版本信息:./nginx -v
我这个是x86的,arm的等我今晚发布最新版,已经编译好了
我的服务器是arm架构的,是不是和这个有关系
我换成麒麟的系统之后提示我-bash: ./nginx:无法执行二进制文件: 可执行文件格式错误,nginx没有cpu运行架构区分吧
你的系统版本和我这个不一致。你试试centos7的版本
你好博主,我在用你的命令执行完之后启动nginx发现报/app/nginx/sbin/nginx: error while loading shared libraries: libpcre2-8.so.0: cannot open shared object file: No such file or directory找不到pcre2,是否是因为版本问题导致的,我看过我的机器上面是有pcre2的