宝塔面板安装nginx失败_卸载宝塔网站防火墙

宝塔面板安装nginx失败_卸载宝塔网站防火墙解压并转到目录下tar-zxvfnginx-1.9.15.tar.gzcdnginx-1.9.15设置一下配置信息./configure–prefix=/usr/local/nginx,或者不执行此步,直接默认配置编译安装makemakeinstallmake的过程是把各种语言写的源码文件,变成可执行文件和各种库文件;makeinstall是把这些编译出来的可执行文件和库文…

大家好,又见面了,我是你们的朋友全栈君。如果您正在找激活码,请点击查看最新教程,关注关注公众号 “全栈程序员社区” 获取激活教程,可能之前旧版本教程已经失效.最新Idea2022.1教程亲测有效,一键激活。

Jetbrains全系列IDE使用 1年只要46元 售后保障 童叟无欺

解压并转到目录下

tar -zxvf nginx-1.9.15.tar.gz cd nginx-1.9.15

设置一下配置信息 ./configure –prefix=/usr/local/nginx ,或者不执行此步,直接默认配置

编译安装

make make install

make的过程是把各种语言写的源码文件,变成可执行文件和各种库文件; make install是把这些编译出来的可执行文件和库文件复制到合适的地方。

可能出现错误

在配置信息./configure –prefix=/usr/local/nginx 的时,出现错误:

/configure: error: the HTTP rewrite module requires the PCRE library.

解决方法:安装pcre

yum -y install pcre pcre-devel

-y 是跳过所有需要手动确认的环节

缺少ssl错误,错误信息如下:

./configure: error: the HTTP cache module requires md5 functions from OpenSSL library. You can either disable the module by using –without-http-cache option, or install the OpenSSL library into the system, or build the OpenSSL library statically from the source with nginx by using –with-http_ssl_module –with-openssl= options.

解决方法:安装openssl

yum -y install openssl openssl-devel

缺少编译器,错误信息如下:

./configure: error: C compiler cc is not found

解决方法:安装gcc-c++

yum -y install gcc-c++ autoconf automake

autoconf是自动配置,automake是自动编译

缺少zlib包,错误信息如下:

./configure: error: the HTTP gzip module requires the zlib library. You can either disable the module by using –without-http_gzip_module option, or install the zlib library into the system, or build the zlib library

statically from the source with nginx by using –with-zlib= option.

解决方法:安装zlib

yum install -y zlib-devel

确实libxml2,错误信息如下:

./configure: error: the HTTP XSLT module requires the libxml2/libxslt

libraries. You can either do not enable the module or install the libraries.

解决方法:

yum -y install libxml2 libxml2-dev yum -y install libxslt-devel

http_image_filter_module是nginx提供的集成图片处理模块,需要gd-devel的支持,错误信息如下:

./configure: error: the HTTP image filter module requires the GD library. You can either do not enable the module or install the libraries.

解决方法:

yum -y install gd-devel

缺少ExtUtils,错误信息如下:

./configure: error: perl module ExtUtils::Embed is required

解决方法:

yum -y install perl-devel perl-ExtUtils-Embed

缺少GeoIP,错误信息如下:

./configure: error: the GeoIP module requires the GeoIP library. You can either do not enable the module or install the library.

解决方法:

yum -y install GeoIP GeoIP-devel GeoIP-data

检测是否安装成功

[root@localhost nginx-1.2.6]# cd /usr/local/nginx/sbin [root@localhost sbin]# ./nginx -t

启动nginx

[root@localhost sbin]# ./nginx

查看端口

[root@localhost sbin]# netstat -ntlp

打开浏览器访问此机器的 IP,如果浏览器出现 Welcome to nginx! 则表示 Nginx 已经安装并运行成功。

当时是下面错误用,了解决方法

http_image_filter_module是nginx提供的集成图片处理模块,需要gd-devel的支持,错误信息如下:

./configure: error: the HTTP image filter module requires the GD library. You can either do not enable the module or install the libraries.

解决方法:

yum -y install gd-devel

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请联系我们举报,一经查实,本站将立刻删除。

发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/197859.html原文链接:https://javaforall.net

(0)
全栈程序员-站长的头像全栈程序员-站长


相关推荐

  • BS架构和CS架构的区别

    BS架构和CS架构的区别介绍BS:(Browser/Server,浏览器/服务器模式),web应用可以实现跨平台,客户端零维护,但是个性化能力低,响应速度较慢。CS:(Client/Server,客户端/服务器模式),桌面级应用响应速度快,安全性强,个性化能力强,响应数据较快区别硬件环境不同C/S用户固定,一般只应用于局域网中,要求拥有相同的操作系统,如果对于不同操作系统还要相应开发不同的版本,并且对…

    2022年6月15日
    31
  • subline3 激活码(最新序列号破解)

    subline3 激活码(最新序列号破解),https://javaforall.net/100143.html。详细ieda激活码不妨到全栈程序员必看教程网一起来了解一下吧!

    2022年3月20日
    42
  • linux查看mysql用户权限_教您如何查看MySQL用户权限

    linux查看mysql用户权限_教您如何查看MySQL用户权限教您如何查看MySQL用户权限如果需要查看MySQL用户权限,应该如何实现呢?下面就为您介绍查看MySQL用户权限的方法,并对授予MySQL用户权限的语句进行介绍,供您参考。查看MySQL用户权限:showgrantsfor你的用户比如:showgrantsforroot@’localhost’;Grant用法GRANTUSAGEON*.*TO’discuz’@’local…

    2022年6月18日
    151
  • DelphiXE7取代默认的ActionList编辑器

    DelphiXE7取代默认的ActionList编辑器DelphiXE7取代默认的ActionList编辑器。其他XE版本应该可以用。Delphi5或7需要修改代码。默认的编辑器只能看到Action的名称,不能看到标题,因此做了这个编辑器。增加了以下功能:1、ListView显示Action的标题,图标,快捷键。2、Action自动命名的尾部序号宽度为3位数字。3、快速选择标准Action。4、收藏Action。代码修改自ECont…

    2022年8月30日
    5
  • Windows10系统设置定时关机「建议收藏」

    Windows10系统设置定时关机「建议收藏」1.输入cmd运行命令提示符2.输入 shutdown–s–t3600   [注:3600为倒计时的秒数,此语句为系统在一小时后关机]/*shutdown命令的参数:shutdown-a 取消关机shutdown-s关机shutdown-f 强行关闭应用程序shutdown-m计算机名 控制远程计算机shutdown-i 显示“远程关机”图形用户界面,…

    2022年5月15日
    42
  • 【单片机】51单片机最小系统

    【单片机】51单片机最小系统51单片机最小系统由三部分组成:主控电路、复位电路、晶振电路。添加LED电路和独立按键。原理图如下所示:

    2022年6月23日
    22

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

关注全栈程序员社区公众号