Bug 1933063 - prosody crash /usr/lib64/prosody/util/async.lua:164: bad argument #1 to 'close'
Summary: prosody crash /usr/lib64/prosody/util/async.lua:164: bad argument #1 to 'close'
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: prosody
Version: 33
Hardware: Unspecified
OS: Unspecified
unspecified
urgent
Target Milestone: ---
Assignee: Robert Scheck
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-02-25 15:37 UTC by Robert Story
Modified: 2021-03-19 19:56 UTC (History)
3 users (show)

Fixed In Version: prosody-0.11.8-2.fc33 prosody-0.11.8-2.fc34
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-03-04 20:09:55 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Robert Story 2021-02-25 15:37:57 UTC
Description of problem:
working prosody configure failed to restart after package updated.

Version-Release number of selected component (if applicable):
prosody-0.11.8-1.fc33.x86_64

How reproducible:
once, on critical machine.

Steps to Reproduce:
1. run prosody-0.11.7-1.fc33.x86_64
2. update to prosody-0.11.8-1.fc33.x86_64

Actual results:
prosody failed to start after update

Expected results:
prosody starts after update


Additional info:
Journal log after dnf update:

Feb 25 01:57:22 ant systemd[1]: Stopping Prosody XMPP (Jabber) server...
Feb 25 01:57:22 ant systemd[1]: prosody.service: Succeeded.
Feb 25 01:57:22 ant systemd[1]: Stopped Prosody XMPP (Jabber) server.
Feb 25 01:57:22 ant systemd[1]: prosody.service: Consumed 1h 1min 2.315s CPU time.
Feb 25 01:57:22 ant systemd[1]: Started Prosody XMPP (Jabber) server.
Feb 25 01:57:22 ant prosody[3733381]: /usr/bin/lua: /usr/lib64/prosody/util/async.lua:164: bad argument #1 to 'close' (thread expected, got boolean)
Feb 25 01:57:22 ant prosody[3733381]: stack traceback:
Feb 25 01:57:22 ant prosody[3733381]:         [C]: in function 'coroutine.close'
Feb 25 01:57:22 ant prosody[3733381]:         /usr/lib64/prosody/util/async.lua:164: in method 'run'
Feb 25 01:57:22 ant prosody[3733381]:         /usr/bin/prosody:55: in main chunk
Feb 25 01:57:22 ant prosody[3733381]:         [C]: in ?

Comment 1 Robert Scheck 2021-02-25 15:57:51 UTC
Upstream let me know that at least https://hg.prosody.im/trunk/rev/558f0555ba02 is needed additionally.

Comment 2 Nicolas Berrehouc 2021-02-25 16:46:18 UTC
Same here after update.

# systemctl status prosody.service 
● prosody.service - Prosody XMPP (Jabber) server
     Loaded: loaded (/usr/lib/systemd/system/prosody.service; enabled; vendor preset: disabled)
     Active: failed (Result: exit-code) since Thu 2021-02-25 17:32:48 CET; 11s ago
   Main PID: 12903 (code=exited, status=1/FAILURE)
        CPU: 10ms

févr. 25 17:32:48 Icaricio systemd[1]: prosody.service: Scheduled restart job, restart counter is at 8.
févr. 25 17:32:48 Icaricio systemd[1]: Stopped Prosody XMPP (Jabber) server.
févr. 25 17:32:48 Icaricio systemd[1]: prosody.service: Start request repeated too quickly.
févr. 25 17:32:48 Icaricio systemd[1]: prosody.service: Failed with result 'exit-code'.
févr. 25 17:32:48 Icaricio systemd[1]: Failed to start Prosody XMPP (Jabber) server.


# prosodyctl 
general             warn	Support for Lua 5.4 is experimental, please report any issues
/usr/bin/lua: /usr/lib64/prosody/util/async.lua:164: bad argument #1 to 'close' (thread expected, got boolean)
stack traceback:
	[C]: in function 'coroutine.close'
	/usr/lib64/prosody/util/async.lua:164: in method 'run'
	/usr/bin/prosodyctl:1411: in main chunk
	[C]: in ?


# cat /var/log/prosody/prosody.err
Feb 25 13:11:06 modulemanager	error	Error initializing module 'websocket' on '<name.tld>': /usr/lib64/prosody/net/websocket/frames.lua:12: No bit module found. See https://prosody.im/doc/depends#bitop
stack traceback:
	[C]: in function 'assert'
	/usr/lib64/prosody/net/websocket/frames.lua:12: in main chunk
	[C]: in upvalue '_real_require'
	/usr/lib64/prosody/util/startup.lua:201: in function 'require'
	/usr/lib64/prosody/modules/mod_websocket.lua:23: in main chunk
	[C]: in function 'xpcall'
	/usr/lib64/prosody/core/modulemanager.lua:183: in upvalue 'do_load_module'
	/usr/lib64/prosody/core/modulemanager.lua:261: in function 'core.modulemanager.load'
	/usr/lib64/prosody/core/moduleapi.lua:158: in function 'core.moduleapi.depends'
	/usr/lib64/prosody/prosody-modules-enabled/mod_conversejs/mod_conversejs.lua:15: in function </usr/lib64/prosody/prosody-modules-enabled/mod_conversejs/mod_conversejs.lua:14>
	...	(skipping 2 levels)
	/usr/lib64/prosody/core/modulemanager.lua:183: in upvalue 'do_load_module'
	/usr/lib64/prosody/core/modulemanager.lua:261: in function 'core.modulemanager.load'
	/usr/lib64/prosody/core/modulemanager.lua:83: in function 'core.modulemanager.load_modules_for_host'
	/usr/lib64/prosody/util/events.lua:79: in function </usr/lib64/prosody/util/events.lua:75>
	(...tail calls...)
	/usr/lib64/prosody/core/hostmanager.lua:108: in function 'core.hostmanager.activate'
	/usr/lib64/prosody/core/hostmanager.lua:58: in field '?'
	/usr/lib64/prosody/util/events.lua:79: in function </usr/lib64/prosody/util/events.lua:75>
	(...tail calls...)
	/usr/lib64/prosody/util/startup.lua:393: in function 'util.startup.prepare_to_start'
	/usr/lib64/prosody/util/startup.lua:629: in function 'util.startup.prosody'
	/usr/lib64/prosody/util/async.lua:139: in upvalue 'func'
	/usr/lib64/prosody/util/async.lua:127: in function </usr/lib64/prosody/util/async.lua:125>


After downgrading to prosody-0.11.7-1.fc33.x86_64, I found an other alert about websocket support with lua-bitop but Prosody works fine:
# systemctl status prosody.service 
● prosody.service - Prosody XMPP (Jabber) server
     Loaded: loaded (/usr/lib/systemd/system/prosody.service; enabled; vendor preset: disabled)
     Active: active (running) since Thu 2021-02-25 17:35:00 CET; 1s ago
   Main PID: 13776 (prosody)
      Tasks: 1 (limit: 18845)
     Memory: 12.7M
        CPU: 620ms
     CGroup: /system.slice/prosody.service
             └─13776 /usr/bin/lua /usr/bin/prosody -F

févr. 25 17:35:00 Icaricio systemd[1]: Started Prosody XMPP (Jabber) server.
févr. 25 17:35:00 Icaricio prosody[13776]: **************************
févr. 25 17:35:00 Icaricio prosody[13776]: Prosody was unable to find lua-bitops
févr. 25 17:35:00 Icaricio prosody[13776]: This package can be obtained in the following ways:
févr. 25 17:35:00 Icaricio prosody[13776]:         Source:           http://bitop.luajit.org/
févr. 25 17:35:00 Icaricio prosody[13776]:         luarocks:         luarocks install luabitop
févr. 25 17:35:00 Icaricio prosody[13776]:         Debian/Ubuntu:    sudo apt-get install lua-bitop
févr. 25 17:35:00 Icaricio prosody[13776]: WebSocket support will not be available
févr. 25 17:35:00 Icaricio prosody[13776]: More help can be found on our website, at https://prosody.im/doc/depends
févr. 25 17:35:00 Icaricio prosody[13776]: **************************

Comment 3 Fedora Update System 2021-02-26 02:09:29 UTC
FEDORA-2021-160a578c2e has been submitted as an update to Fedora 33. https://bodhi.fedoraproject.org/updates/FEDORA-2021-160a578c2e

Comment 4 Fedora Update System 2021-02-26 02:09:45 UTC
FEDORA-2021-72d5a62023 has been submitted as an update to Fedora 34. https://bodhi.fedoraproject.org/updates/FEDORA-2021-72d5a62023

Comment 5 Fedora Update System 2021-02-26 16:33:51 UTC
FEDORA-2021-72d5a62023 has been pushed to the Fedora 34 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2021-72d5a62023`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2021-72d5a62023

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 6 Fedora Update System 2021-02-27 00:00:21 UTC
FEDORA-2021-160a578c2e has been pushed to the Fedora 33 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2021-160a578c2e`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2021-160a578c2e

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 7 Nicolas Berrehouc 2021-03-04 08:13:36 UTC
Works fine. Fix the bug.

Comment 8 Fedora Update System 2021-03-04 20:09:55 UTC
FEDORA-2021-160a578c2e has been pushed to the Fedora 33 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 9 Fedora Update System 2021-03-19 17:38:59 UTC
FEDORA-2021-72d5a62023 has been pushed to the Fedora 34 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 10 Fedora Update System 2021-03-19 19:56:10 UTC
FEDORA-2021-72d5a62023 has been pushed to the Fedora 34 stable repository.
If problem still persists, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.