Hi folks,

The more eyes the better I've been told. Sorry that it's lengthy.

x86 VC9 *Release* Build
httpd version  : 2.4.5-r1489105
mod_lua from trunk at r1487956

Odd results:
    ServerRoot "C:/Apache24A"

1. Running scripts fortune.lua or example.lua via URL works.

2. With
    LuaMapHandler /testlua htdocs/lua/example.lua
    LuaMapHandler /fortune htdocs/lua/fortune.lua

Running fortune.lua via URL 500s
example.lua runs fine via URL

3.
    LuaMapHandler /testlua htdocs/lua/example.lua
    LuaMapHandler /tellme htdocs/lua/fortune.lua

both scripts run fine from URL, so there's some kind of leak where
http://localhost/lua/fortune.lua becomes
http://localhost/fortune to the server

4.
    LuaMapHandler /testlua htdocs/lua/example.lua
    LuaMapHandler /tellme htdocs/lua/fortune.lua

http://localhost/tellme
http://localhost/testlua
error 500

[Tue Jun 04 22:53:30.410000 2013] [lua:error] [pid 3984:tid 948] AH01482: Error loading C:/Apache24A/bin/htdocs/lua/example.lua: cannot open C:/Apache24A/bin/htdocs/lua/example.lua: No such file or directory [Tue Jun 04 22:53:30.410000 2013] [lua:crit] [pid 3984:tid 948] [client ::1:53940] AH02330: lua: Failed to obtain lua interpreter for handle htdocs/lua/example.lua, referer: http://localhost/lua/

Notice mod_lua is adding /bin to the file location!
cannot open C:/Apache24A/bin/htdocs/lua/example.lua

This as you can see is not the location I have it set to look for the script per documented configuration rules about relative paths.

Interestingly, mod_lua seems to get it right at first it looks then blows up.

[Tue Jun 04 22:53:15.543200 2013] [lua:trace1] [pid 3984:tid 948] mod_lua.c(261): [client ::1:53939] AH01472: handling [C:/Apache24A/htdocs/lua/example.lua] in mod_lua, referer: http://localhost/lua/ [Tue Jun 04 22:53:15.543200 2013] [lua:trace2] [pid 3984:tid 948] mod_lua.c(177): [client ::1:53939] AH02313: request handler details: scope: once, file: C:/Apache24A/htdocs/lua/example.lua, func: handle, referer: http://localhost/lua/ [Tue Jun 04 22:53:15.543200 2013] [lua:trace3] [pid 3984:tid 948] mod_lua.c(281): [client ::1:53939] AH01474: got a vm!, referer: http://localhost/lua/ [Tue Jun 04 22:53:15.543200 2013] [lua:debug] [pid 3984:tid 948] lua_request.c(1702): [client ::1:53939] AH01487: request_rec->dispatching puts -> lua_CFunction, referer: http://localhost/lua/ [Tue Jun 04 22:53:15.543200 2013] [lua:debug] [pid 3984:tid 948] lua_request.c(1711): [client ::1:53939] AH01488: request_rec->dispatching method -> string, referer: http://localhost/lua/ [Tue Jun 04 22:53:15.543200 2013] [lua:debug] [pid 3984:tid 948] lua_request.c(1702): [client ::1:53939] AH01487: request_rec->dispatching parseargs -> lua_CFunction, referer: http://localhost/lua/ [Tue Jun 04 22:53:15.543200 2013] [lua:debug] [pid 3984:tid 948] lua_request.c(1702): [client ::1:53939] AH01487: request_rec->dispatching puts -> lua_CFunction, referer: http://localhost/lua/ [Tue Jun 04 22:53:19.646000 2013] [lua:trace1] [pid 3984:tid 948] mod_lua.c(261): [client ::1:53939] AH01472: handling [C:/Apache24A/htdocs/lua/fortune.lua] in mod_lua, referer: http://localhost/lua/ [Tue Jun 04 22:53:19.646000 2013] [lua:trace2] [pid 3984:tid 948] mod_lua.c(177): [client ::1:53939] AH02313: request handler details: scope: once, file: C:/Apache24A/htdocs/lua/fortune.lua, func: handle, referer: http://localhost/lua/ [Tue Jun 04 22:53:19.646000 2013] [lua:trace3] [pid 3984:tid 948] mod_lua.c(281): [client ::1:53939] AH01474: got a vm!, referer: http://localhost/lua/ [Tue Jun 04 22:53:19.646000 2013] [lua:debug] [pid 3984:tid 948] lua_request.c(1692): [client ::1:53939] AH01486: request_rec->dispatching headers_out -> apr table, referer: http://localhost/lua/ [Tue Jun 04 22:53:19.646000 2013] [lua:debug] [pid 3984:tid 948] lua_request.c(1692): [client ::1:53939] AH01486: request_rec->dispatching headers_out -> apr table, referer: http://localhost/lua/ [Tue Jun 04 22:53:19.646000 2013] [lua:debug] [pid 3984:tid 948] lua_request.c(1692): [client ::1:53939] AH01486: request_rec->dispatching headers_out -> apr table, referer: http://localhost/lua/ [Tue Jun 04 22:53:19.646000 2013] [lua:debug] [pid 3984:tid 948] lua_request.c(1702): [client ::1:53939] AH01487: request_rec->dispatching puts -> lua_CFunction, referer: http://localhost/lua/


5. With:
    LuaMapHandler /testlua C:/Apache24A/htdocs/lua/example.lua
    LuaMapHandler /tellme C:/Apache24A/htdocs/lua/fortune.lua

Set with full path these 404.
http://localhost/tellme
http://localhost/testlua

6.  Adding LuaRoot
    LuaRoot htdocs/lua
    LuaMapHandler /testlua htdocs/lua/example.lua
    LuaMapHandler /tellme htdocs/lua/fortune.lua

http://localhost/tellme
http://localhost/testlua

Both crash!

Guenter has confirmed some of this behavior in Netware, I'll let him chime in on which.

Cheers,

Gregg


Reply via email to