openresty/lua-cjson

/usr/share/lua/5.2/luarocks/loader.lua:147: error loading module 'lua_cjson_2_1_0_1-cjson' from file '/usr/local/lib/lua/5.2/lua_cjson_2_1_0_1-cjson.so'

raphael10-collab opened this issue · 0 comments

In /etc/prosody/prosody.cfg.lua I've set this VirtualHost:

VirtualHost "uxpug2bqoujpbjgtwogesqvixybtknziv7ieu3jfhuyxs5b4afjq.b32.i2p";
    ssl = {
        key = "/etc/prosody/certs/uxpug2bqoujpbjgtwogesqvixybtknziv7ieu3jfhuyxs5b4afjq.b32.i2p.key";
        certificate = "/etc/prosody/certs/uxpug2bqoujpbjgtwogesqvixybtknziv7ieu3jfhuyxs5b4afjq.b32.i2p.crt";
    }

    https_certificate = "/etc/prosody/certs/uxpug2bqoujpbjgtwogesqvixybtknziv7ieu3jfhuyxs5b4afjq.b32.i2p.crt";

    modules_enabled = { "presence_identity" }

    asap_accepted_issuers = { "jitsi", "GD" }
    asap_accepted_audiences = { "jitsi", "GD" }

    authentication = "token"

I get the following errors:

  lines 1-65/65 (END)...skipping...
● prosody.service - Prosody XMPP Server
     Loaded: loaded (/lib/systemd/system/prosody.service; enabled; vendor preset: enabled)
     Active: active (running) since Wed 2021-07-14 15:29:05 CEST; 5s ago
       Docs: https://prosody.im/doc
   Main PID: 4334 (lua5.2)
      Tasks: 1 (limit: 38400)
     Memory: 10.1M
     CGroup: /system.slice/prosody.service
             └─4334 lua5.2 /usr/bin/prosody

lug 14 15:29:05 pc systemd[1]: Started Prosody XMPP Server.
lug 14 15:29:05 pc prosody[4334]: modulemanager: Error initializing module 'token_verification' on 'conference.uxpug2bqoujpbjgtwogesqvixybtknziv7ieu3jfhuyxs5b4afjq.b32.i2p': /usr/share/lua/5.2/luarocks/loader.lua:147: error loading module 'lua_cjson_2_1_0_1-cjson' from file '/usr/local/lib/lua/5.2/lua_cjson_2_1_0_1-cjson.so':
                                          /usr/local/lib/lua/5.2/lua_cjson_2_1_0_1-cjson.so: undefined symbol: lua_newuserdatauv
                                  stack traceback:
                                          [C]: in function 'a_loader'
                                          /usr/share/lua/5.2/luarocks/loader.lua:147: in function </usr/share/lua/5.2/luarocks/loader.lua:144>
                                          (...tail calls...)
                                          [C]: in function '_real_require'
                                          /usr/lib/prosody/util/startup.lua:145: in function 'require'
                                          /usr/local/share/lua/5.2/luajwtjitsi.lua:1: in main chunk
                                          [C]: in function '_real_require'
                                          /usr/lib/prosody/util/startup.lua:145: in function 'require'
                                          /usr/share/jitsi-meet/prosody-plugins/token/util.lib.lua:7: in main chunk
                                          (...tail calls...)
                                          ...re/jitsi-meet/prosody-plugins/mod_token_verification.lua:28: in main chunk
                                          [C]: in function 'xpcall'
                                          /usr/lib/prosody/core/modulemanager.lua:183: in function 'do_load_module'
                                          /usr/lib/prosody/core/modulemanager.lua:261: in function 'load'
                                          /usr/lib/prosody/core/modulemanager.lua:83: in function '?'
                                          /usr/lib/prosody/util/events.lua:79: in function </usr/lib/prosody/util/events.lua:75>
                                          (...tail calls...)
                                          /usr/lib/prosody/core/hostmanager.lua:108: in function 'activate'
                                          /usr/lib/prosody/core/hostmanager.lua:58: in function '?'
                                          /usr/lib/prosody/util/events.lua:79: in function </usr/lib/prosody/util/events.lua:75>
                                          (...tail calls...)
                                          /usr/lib/prosody/util/startup.lua:337: in function 'prepare_to_start'
                                          /usr/lib/prosody/util/startup.lua:558: in function 'f'
                                          /usr/lib/prosody/util/async.lua:139: in function 'func'
                                          /usr/lib/prosody/util/async.lua:127: in function </usr/lib/prosody/util/async.lua:125>
lug 14 15:29:05 pc prosody[4334]: modulemanager: Error initializing module 'auth_token' on 'uxpug2bqoujpbjgtwogesqvixybtknziv7ieu3jfhuyxs5b4afjq.b32.i2p': error loading module '_openssl.hmac' from file '/usr/local/lib/lua/5.2/_openssl.so':
                                      /usr/local/lib/lua/5.2/_openssl.so: undefined symbol: lua_rotate
                              stack traceback:
                                      [C]: in ?
                                      [C]: in function '_real_require'
                                      /usr/lib/prosody/util/startup.lua:145: in function 'require'
                                      /usr/local/share/lua/5.2/openssl/hmac.lua:1: in main chunk
                                      [C]: in function '_real_require'
                                      /usr/lib/prosody/util/startup.lua:145: in function 'require'
                                      .../prosody-modules/mod_auth_token/token_auth_utils.lib.lua:2: in main chunk
                                      (...tail calls...)
                                      ...al/lib/prosody-modules/mod_auth_token/mod_auth_token.lua:10: in main chunk
                                      [C]: in function 'xpcall'
                                      /usr/lib/prosody/core/modulemanager.lua:183: in function 'do_load_module'
                                      /usr/lib/prosody/core/modulemanager.lua:261: in function 'load'
                                      /usr/lib/prosody/core/usermanager.lua:67: in function '?'
                                      /usr/lib/prosody/util/events.lua:79: in function </usr/lib/prosody/util/events.lua:75>
                                      (...tail calls...)
                                      /usr/lib/prosody/core/hostmanager.lua:108: in function 'activate'
                                      /usr/lib/prosody/core/hostmanager.lua:58: in function '?'
                                      /usr/lib/prosody/util/events.lua:79: in function </usr/lib/prosody/util/events.lua:75>
                                      (...tail calls...)
                                      /usr/lib/prosody/util/startup.lua:337: in function 'prepare_to_start'
                                      /usr/lib/prosody/util/startup.lua:558: in function 'f'
                                      /usr/lib/prosody/util/async.lua:139: in function 'func'
                                      /usr/lib/prosody/util/async.lua:127: in function </usr/lib/prosody/util/async.lua:125>

I installed lua-cjson via luarocks:

(base) raphy@pc:/usr/local/lib/luarocks/rocks$ ls -lah
total 60K
drwxr-xr-x 8 root root 4,0K lug 14 13:54 .
drwxr-xr-x 3 root root 4,0K lug 14 13:33 ..
drwxr-xr-x 3 root root 4,0K lug 14 13:33 basexx
-rw-r--r-- 1 root root 1,3K lug 14 13:33 index.html
drwxr-xr-x 3 root root 4,0K lug 14 13:42 lbase64
drwxr-xr-x 4 root root 4,0K lug 14 13:44 lua-cjson
drwxr-xr-x 3 root root 4,0K lug 14 13:42 luajwtjitsi
drwxr-xr-x 3 root root 4,0K lug 14 13:42 luaossl
-rw-r--r-- 1 root root 8,9K lug 14 13:51 manifest
-rw-r--r-- 1 root root   43 lug 14 13:33 manifest-5.1
-rw-r--r-- 1 root root   43 lug 14 13:33 manifest-5.2
-rw-r--r-- 1 root root   43 lug 14 13:33 manifest-5.3
drwxr-xr-x 3 root root 4,0K lug 14 13:51 openssl
(base) raphy@pc:/usr/local/lib/luarocks/rocks$ 



(base) raphy@pc:~$ sudo prosodyctl about
Prosody 0.11.4

# Prosody directories
Data directory:     /var/lib/prosody
Config directory:   /etc/prosody
Source directory:   /usr/lib/prosody
Plugin directories:
  /usr/lib/prosody/modules
  /usr/local/lib/prosody-modules - prosody-modules rev: f6f28ceff53a
  /usr/share/jitsi-meet/prosody-plugins/
  /usr/local/lib/luarocks/rocks
  /usr/lib/prosody/modules/
  

# Lua environment
Lua version:             	Lua 5.2

Lua module search paths:
  /usr/lib/prosody/?.lua
  /usr/local/share/lua/5.2/?.lua
  /usr/local/share/lua/5.2/?/init.lua
  /usr/local/lib/lua/5.2/?.lua
  /usr/local/lib/lua/5.2/?/init.lua
  /usr/share/lua/5.2/?.lua
  /usr/share/lua/5.2/?/init.lua
  /root/.luarocks/share/lua/5.2/?.lua
  /root/.luarocks/share/lua/5.2/?/init.lua

Lua C module search paths:
  /usr/lib/prosody/?.so
  /usr/local/lib/lua/5.2/?.so
  /usr/lib/x86_64-linux-gnu/lua/5.2/?.so
  /usr/lib/lua/5.2/?.so
  /usr/local/lib/lua/5.2/loadall.so
  /root/.luarocks/lib/lua/5.2/?.so

LuaRocks:        	Installed (2.4.2)

# Network

Backend: select

# Lua module versions
lfs:     	LuaFileSystem 1.7.0
libevent:	2.1.11-stable
luaevent:	0.4.6
lxp:     	LuaExpat 1.3.0
socket:  	LuaSocket 3.0-rc1
ssl:     	0.9

OS: Ubuntu 20.04 Desktop

How to solve the problem?