当前位置:论坛首页 > Linux面板 > 求助

【已解答】Nginx安装失败

发表在 Linux面板2023-10-20 15:55 [复制链接] 11 6965

本帖最后由 堡塔运维小林 于 2023-10-25 22:23 编辑

为了能快速了解并处理您的问题,请提供以下基础信息:
面板、插件版本:
系统版本:CentOS 7.9.2009 x86_64(Py3.7.9)
问题描述:Nginx安装失败
相关截图(日志、错误):

使用道具 举报 只看该作者 回复
发表于 2023-10-20 16:44:44 | 显示全部楼层
您好,请把nginx安装失败的执行日志发出来看看,仅凭上面的信息是无法判断问题的
QQ截图20231020164428.png
使用道具 举报 回复 支持 反对
发表于 2023-10-20 16:49:17 | 显示全部楼层
checking for SO_SETFIB ... not foundchecking for SO_REUSEPORT ... foundchecking for SO_ACCEPTFILTER ... not foundchecking for SO_BINDANY ... not foundchecking for IP_TRANSPARENT ... foundchecking for IP_BINDANY ... not foundchecking for IP_BIND_ADDRESS_NO_PORT ... foundchecking for IP_RECVDSTADDR ... not foundchecking for IP_SENDSRCADDR ... not foundchecking for IP_PKTINFO ... foundchecking for IPV6_RECVPKTINFO ... foundchecking for TCP_DEFER_ACCEPT ... foundchecking for TCP_KEEPIDLE ... foundchecking for TCP_FASTOPEN ... foundchecking for TCP_INFO ... foundchecking for accept4() ... foundchecking for int size ... 4 byteschecking for long size ... 8 byteschecking for long long size ... 8 byteschecking for void * size ... 8 byteschecking for uint32_t ... foundchecking for uint64_t ... foundchecking for sig_atomic_t ... foundchecking for sig_atomic_t size ... 4 byteschecking for socklen_t ... foundchecking for in_addr_t ... foundchecking for in_port_t ... foundchecking for rlim_t ... foundchecking for uintptr_t ... uintptr_t foundchecking for system byte ordering ... little endianchecking for size_t size ... 8 byteschecking for off_t size ... 8 byteschecking for time_t size ... 8 byteschecking for AF_INET6 ... foundchecking for setproctitle() ... not foundchecking for pread() ... foundchecking for pwrite() ... foundchecking for pwritev() ... foundchecking for strerrordesc_np() ... not foundchecking for sys_nerr ... foundchecking for localtime_r() ... foundchecking for clock_gettime(CLOCK_MONOTONIC) ... foundchecking for posix_memalign() ... foundchecking for memalign() ... foundchecking for mmap(MAP_ANON|MAP_SHARED) ... foundchecking for mmap("/dev/zero", MAP_SHARED) ... foundchecking for System V shared memory ... foundchecking for POSIX semaphores ... not foundchecking for POSIX semaphores in libpthread ... foundchecking for struct msghdr.msg_control ... foundchecking for ioctl(FIONBIO) ... foundchecking for ioctl(FIONREAD) ... foundchecking for struct tm.tm_gmtoff ... foundchecking for struct dirent.d_namlen ... not foundchecking for struct dirent.d_type ... foundchecking for sysconf(_SC_NPROCESSORS_ONLN) ... foundchecking for sysconf(_SC_LEVEL1_DCACHE_LINESIZE) ... foundchecking for openat(), fstatat() ... foundchecking for getaddrinfo() ... foundconfiguring additional modulesadding module in /www/server/nginx/src/ngx_devel_kit+ ngx_devel_kit was configuredadding module in /www/server/nginx/src/lua_nginx_modulechecking for LuaJIT library in /usr/local/lib and /usr/local/include/luajit-2.0/ (specified by the LUAJIT_LIB and LUAJIT_INC env, with -ldl) ... foundchecking for export symbols by default (-E) ... foundchecking for export symbols by default (--export-all-symbols) ... not foundchecking for SO_PASSCRED ... foundchecking for __attribute__(constructor) ... foundchecking for malloc_trim ... found+ ngx_http_lua_module was configuredadding module in /www/server/nginx/src/ngx_cache_purge+ ngx_http_cache_purge_module was configuredadding module in /www/server/nginx/src/nginx-sticky-module+ ngx_http_sticky_module was configuredadding module in /www/server/nginx/src/ngx_http_substitutions_filter_module-master+ ngx_http_subs_filter_module was configuredadding module in /www/server/nginx/src/nginx-dav-ext-module+ ngx_http_dav_ext_module was configuredchecking for zlib library ... not found./configure: error: the HTTP gzip module requires the zlib library.You can either disable the module by using --without-http_gzip_moduleoption, or install the zlib library into the system, or build the zlib librarystatically from the source with nginx by using --with-zlib= option.make: *** No rule to make target `build', needed by `default'. Stop.make: *** No rule to make target `install'. Stop.

使用道具 举报 回复 支持 反对
发表于 2023-10-20 16:52:35 | 显示全部楼层
堡塔运维小林 发表于 2023-10-20 16:44
您好,请把nginx安装失败的执行日志发出来看看,仅凭上面的信息是无法判断问题的 ...
  1. checking for SO_SETFIB ... not found
  2. checking for SO_REUSEPORT ... found
  3. checking for SO_ACCEPTFILTER ... not found
  4. checking for SO_BINDANY ... not found
  5. checking for IP_TRANSPARENT ... found
  6. checking for IP_BINDANY ... not found
  7. checking for IP_BIND_ADDRESS_NO_PORT ... found
  8. checking for IP_RECVDSTADDR ... not found
  9. checking for IP_SENDSRCADDR ... not found
  10. checking for IP_PKTINFO ... found
  11. checking for IPV6_RECVPKTINFO ... found
  12. checking for TCP_DEFER_ACCEPT ... found
  13. checking for TCP_KEEPIDLE ... found
  14. checking for TCP_FASTOPEN ... found
  15. checking for TCP_INFO ... found
  16. checking for accept4() ... found
  17. checking for int size ... 4 bytes
  18. checking for long size ... 8 bytes
  19. checking for long long size ... 8 bytes
  20. checking for void * size ... 8 bytes
  21. checking for uint32_t ... found
  22. checking for uint64_t ... found
  23. checking for sig_atomic_t ... found
  24. checking for sig_atomic_t size ... 4 bytes
  25. checking for socklen_t ... found
  26. checking for in_addr_t ... found
  27. checking for in_port_t ... found
  28. checking for rlim_t ... found
  29. checking for uintptr_t ... uintptr_t found
  30. checking for system byte ordering ... little endian
  31. checking for size_t size ... 8 bytes
  32. checking for off_t size ... 8 bytes
  33. checking for time_t size ... 8 bytes
  34. checking for AF_INET6 ... found
  35. checking for setproctitle() ... not found
  36. checking for pread() ... found
  37. checking for pwrite() ... found
  38. checking for pwritev() ... found
  39. checking for strerrordesc_np() ... not found
  40. checking for sys_nerr ... found
  41. checking for localtime_r() ... found
  42. checking for clock_gettime(CLOCK_MONOTONIC) ... found
  43. checking for posix_memalign() ... found
  44. checking for memalign() ... found
  45. checking for mmap(MAP_ANON|MAP_SHARED) ... found
  46. checking for mmap("/dev/zero", MAP_SHARED) ... found
  47. checking for System V shared memory ... found
  48. checking for POSIX semaphores ... not found
  49. checking for POSIX semaphores in libpthread ... found
  50. checking for struct msghdr.msg_control ... found
  51. checking for ioctl(FIONBIO) ... found
  52. checking for ioctl(FIONREAD) ... found
  53. checking for struct tm.tm_gmtoff ... found
  54. checking for struct dirent.d_namlen ... not found
  55. checking for struct dirent.d_type ... found
  56. checking for sysconf(_SC_NPROCESSORS_ONLN) ... found
  57. checking for sysconf(_SC_LEVEL1_DCACHE_LINESIZE) ... found
  58. checking for openat(), fstatat() ... found
  59. checking for getaddrinfo() ... found
  60. configuring additional modules
  61. adding module in /www/server/nginx/src/ngx_devel_kit
  62. + ngx_devel_kit was configured
  63. adding module in /www/server/nginx/src/lua_nginx_module
  64. checking for LuaJIT library in /usr/local/lib and /usr/local/include/luajit-2.0/ (specified by the LUAJIT_LIB and LUAJIT_INC env, with -ldl) ... found
  65. checking for export symbols by default (-E) ... found
  66. checking for export symbols by default (--export-all-symbols) ... not found
  67. checking for SO_PASSCRED ... found
  68. checking for __attribute__(constructor) ... found
  69. checking for malloc_trim ... found
  70. + ngx_http_lua_module was configured
  71. adding module in /www/server/nginx/src/ngx_cache_purge
  72. + ngx_http_cache_purge_module was configured
  73. adding module in /www/server/nginx/src/nginx-sticky-module
  74. + ngx_http_sticky_module was configured
  75. adding module in /www/server/nginx/src/ngx_http_substitutions_filter_module-master
  76. + ngx_http_subs_filter_module was configured
  77. adding module in /www/server/nginx/src/nginx-dav-ext-module
  78. + ngx_http_dav_ext_module was configured
  79. checking for zlib library ... not found

  80. ./configure: error: the HTTP gzip module requires the zlib library.
  81. You can either disable the module by using --without-http_gzip_module
  82. option, or install the zlib library into the system, or build the zlib library
  83. statically from the source with nginx by using --with-zlib=option.

  84. make: *** No rule to make target `build', needed by `default'. Stop.
  85. make: *** No rule to make target `install'. Stop.
复制代码


使用道具 举报 回复 支持 反对
发表于 2023-10-20 16:56:12 | 显示全部楼层

您好,复制下面的命令到终端中执行,执行成功后再去安装nginx
  1. yum -y install zlib-devel
复制代码
使用道具 举报 回复 支持 反对
发表于 2023-10-20 17:06:13 | 显示全部楼层
堡塔运维小林 发表于 2023-10-20 16:56
您好,复制下面的命令到终端中执行,执行成功后再去安装nginx

下图是运行之后的结果
微信截图_20231020170536.png
使用道具 举报 回复 支持 反对
发表于 2023-10-20 17:18:39 | 显示全部楼层
宝塔用户_xybewa 发表于 2023-10-20 17:06
下图是运行之后的结果

您好,复制下面的命令去修复一下您系统的软件安装源,再去执行上面的命令,你这个报错是软件安装源报错了
  1. bash <(wget --no-check-certificate -qO- https://120.78.156.100/new/auto_node.sh)
复制代码
使用道具 举报 回复 支持 反对
发表于 2023-10-20 17:24:04 | 显示全部楼层
堡塔运维小林 发表于 2023-10-20 17:18
您好,复制下面的命令去修复一下您系统的软件安装源,再去执行上面的命令,你这个报错是软件安装源报错了 ...

执行完修复之后安装还是一样
1.png
使用道具 举报 回复 支持 反对
发表于 2023-10-20 17:53:18 | 显示全部楼层
宝塔用户_xybewa 发表于 2023-10-20 17:24
执行完修复之后安装还是一样

您好,私信我您的todesk或向日葵,我远程连接看看,私信后这里回复一下
使用道具 举报 回复 支持 反对
发表于 2023-10-20 17:57:52 | 显示全部楼层
堡塔运维小林 发表于 2023-10-20 17:53
您好,私信我您的todesk或向日葵,我远程连接看看,私信后这里回复一下

私信已发
使用道具 举报 回复 支持 反对
发表于 2023-10-23 09:13:57 | 显示全部楼层
堡塔运维小林 发表于 2023-10-20 17:53
您好,私信我您的todesk或向日葵,我远程连接看看,私信后这里回复一下

上周站点搭建弄好了,周末休息,没有在去管他,今天创建好站点,给站点绑定了IP,结果访问不了,不知道什么原因
微信截图_20231023091334.png 1698023605301.jpg
使用道具 举报 回复 支持 反对
发表于 2023-10-25 22:23:17 | 显示全部楼层
宝塔用户_xybewa 发表于 2023-10-23 09:13
上周站点搭建弄好了,周末休息,没有在去管他,今天创建好站点,给站点绑定了IP,结果访问不了,不知道什 ...

您好,您先检查一下nginx是否在正常运行,如果是在正常运行,您需要去排查一下您的80端口是否在系统的防火墙和安全组中的端口是否开放了,可以使用这个工具(https://tool.chinaz.com/port)去扫描端口,如果您80端口是开放的,但还是访问不了,请联系服务器运营商排查是不是80端口限制了不能访问
使用道具 举报 回复 支持 反对
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

普通问题处理

论坛响应时间:72小时

问题处理方式:排队(仅解答)

工作时间:白班:9:00 - 18:00

紧急运维服务

响应时间:3分钟

问题处理方式:宝塔专家1对1服务

工作时间:工作日:9:00 - 18:30

宝塔专业团队为您解决服务器疑难问题

点击联系技术免费分析

工作时间:09:00至18:30

快速回复 返回顶部 返回列表