Opened 3 years ago

Last modified 2 years ago

#65165 assigned defect

nginx @1.21.6+lua: lua_load_resty_core failed to load the resty.core module

Reported by: ryandesign (Ryan Carsten Schmidt) Owned by: Schamschula (Marius Schamschula)
Priority: Normal Milestone:
Component: ports Version: 2.7.2
Keywords: Cc:
Port: nginx

Description

This appears in my error.log when I start nginx if it has been built with the +lua variant:

2022/05/12 02:19:49 [alert] 18057#0: detected a LuaJIT version which is not OpenResty's; many optimizations will be disabled and performance will be compromised (see https://github.com/openresty/luajit2 for OpenResty's LuaJIT or, even better, consider using the OpenResty releases from https://openresty.org/en/download.html)
2022/05/12 02:19:49 [error] 18057#0: lua_load_resty_core failed to load the resty.core module from https://github.com/openresty/lua-resty-core; ensure you are using an OpenResty release from https://openresty.org/en/download.html (rc: 2, reason: module 'resty.core' not found:
	no field package.preload['resty.core']
	no file '../lua-resty-core/lib/resty/core.lua'
	no file '../lua-resty-lrucache/lib/resty/core.lua'
	no file './resty/core.lua'
	no file '/opt/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 '/opt/local/share/lua/5.1/resty/core.lua'
	no file '/opt/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 '/opt/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 '/opt/local/lib/lua/5.1/resty.so'
	no file '/usr/local/lib/lua/5.1/loadall.so')

I haven't yet tried to use any lua directives so I don't know whether they still work despite this message.

Change History (3)

comment:1 Changed 3 years ago by ryandesign (Ryan Carsten Schmidt)

I tried content_by_lua_block and it did work. So I'm not sure what significance the error messages have. Maybe some other part of the lua module needs resty.core and would fail. But if not, maybe the message can be silenced somehow.

Last edited 3 years ago by ryandesign (Ryan Carsten Schmidt) (previous) (diff)

comment:2 Changed 3 years ago by Schamschula (Marius Schamschula)

Last edited 3 years ago by ryandesign (Ryan Carsten Schmidt) (previous) (diff)

comment:3 Changed 2 years ago by Schamschula (Marius Schamschula)

Unfortunately, nginx now refuses to load if built with +lua.

Note: See TracTickets for help on using tickets.