Skip to content

Latest commit

 

History

History
37 lines (27 loc) · 1.21 KB

宝塔面板nginx升级1.25版本启动报错`module_'resty.core'_not_found`解决方案.md

File metadata and controls

37 lines (27 loc) · 1.21 KB
title category tags updatedAt date
宝塔面板nginx升级1.25版本启动报错`module 'resty.core' not found`解决方案
宝塔面板相关
宝塔面板,nginx,linux
2024-02-21 12:59:28 UTC
2024-02-18 08:50:41 UTC

宝塔面板nginx升级到1.25可能启动失败,报错module 'resty.core' not found

类似这样:

警告消息:

nginx: [alert] failed to load the 'resty.core' module (https://github.com/openresty/lua-resty-core); ensure you are using an OpenResty release from https://openresty.org/en/download.html (reason: module 'resty.core' not found:
no field package.preload['resty.core']
no file './resty/core.lua'
no file '/usr/local/share/luajit-2.1.0-beta3/resty/core.lua'
no file '/usr/local/share/lua/5.1/resty/core.lua'
no file '/usr/local/share/lua/5.1/resty/core/init.lua'
no file './resty/core.so'
no file '/usr/local/lib/lua/5.1/resty/core.so'
no file '/usr/local/lib/lua/5.1/loadall.so'
no file './resty.so'
no file '/usr/local/lib/lua/5.1/resty.so'
no file '/usr/local/lib/lua/5.1/loadall.so') in /www/server/nginx/conf/nginx.conf:109

解决方案

可以尝试在nginx配置文件中http{}这一段加入lua_package_path "/www/server/nginx/lib/lua/?.lua;";