如何解决nginx-1.24模块不兼容错误?

网站提示:
面板默认组件 nginx-1.24 软件已经出错,
请您及时修正错误,避免面板无法正常启动。
(点击『检测』可查看具体报错信息)

点检测后出现以下提示:

nginx-1.24 检测失败
=============================================================
[Linux] AMH 7.2
https://amh.sh

[nginx-1.24 check]
=============================================================
nginx-1.24
[OK] nginx-1.24 is already installed.
nginx: [emerg] module "/var/adm/0c93418f-3fd9-444f-806f-78db29e904ca/nginx/module.so" is not binary compatible in command line
nginx: configuration file /usr/local/nginx-1.24/conf/nginx.conf test failed 

这样情况如何修复?是不是可以重新安装LNMP? 重新安装会不会导致网站的数据丢失?

  1. 点检测,无效。
  2. 点重载,无效。
  3. AI找答案,无效。conf/nginx.conf 文件中没有 module.so
  4. 如果没办法,只能删掉并重新安装LNMP了
阅读 1k
1 个回答

检测只是查看具体错误原因,要具体修复错误才行。
上面报错是nginx有模块无法载入,这个不是面板正常加载的模块,是否有在ssh做过什么改动,还是ssh安装过什么软件被改动的。
有过改动就恢复回原先的,如果改不回,或可以重新安装nginx恢复:

mv /usr/local/nginx-1.24 /usr/local/nginx-1.24-bak
amh download nginx-1.24 y
amh nginx-1.24 install

重新加载面板与环境:
amh start
amh lnmp admin lnmp_list

原nginx.conf确认没有问题的话,或恢复原nginx.conf
\cp /usr/local/nginx-1.24-bak/conf/nginx.conf /usr/local/nginx-1.24/conf/

恢复后,是否已正常检测:
amh nginx check

撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进
推荐问题