Bug 1524199

Summary: ejabberd does not start
Product: [Fedora] Fedora Reporter: Randy Barlow <randy>
Component: ejabberdAssignee: Randy Barlow <randy>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: unspecified    
Version: rawhideCC: fabrice, jeremy, lemenkov, randy, xavier
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: ejabberd-17.09-2.fc28 ejabberd-17.09-2.fc27 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-12-28 02:47:41 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Randy Barlow 2017-12-10 17:42:34 UTC
I believe the problem is that ejabberdctl has changed in two ways: The first is that it uses $1 in the case statement at the end to determine which command you are running. The old invocation worked with arguments first and then the command, but now the command (such as start or stop) must be the first positional argument. This needs to be fixed in the systemd unit file.

After fixing that locally, I found another problem. When invoked with sudo, ejabberdctl uses su to switch to the ejabberd user. This would be fine, except that the ejabberd user's shell is set to nologin so this fails. The unit file runs the script as ejabberd so that not necessarily a problem there, but it would affect using ejabberdctl on the command line to manage the server. This is fixed by inserting a -s /bin/sh in the su line in exec_cmd().

I also found a third issue, which is that the new mod_avatar module seems to be enabled by default, but ejabberd is not built with graphics support. I must have failed to notice that it was enabled in the default config, so I will alter the config to switch that off. IIRC, we need to package a new dependency in order to make mod_avatar work. We can do that, but i haven't had the time so far.

Comment 1 Fedora Update System 2017-12-11 16:38:46 UTC
ejabberd-17.09-2.fc27 erlang-cache_tab-1.0.11-1.fc27 erlang-esip-1.0.16-1.fc27 erlang-fast_tls-1.0.16-1.fc27 erlang-fast_xml-1.1.24-1.fc27 erlang-fast_yaml-1.0.11-1.fc27 erlang-iconv-1.0.6-1.fc27 erlang-p1_oauth2-0.6.2-1.fc27 erlang-p1_utils-1.0.10-1.fc27 erlang-stringprep-1.0.10-1.fc27 erlang-stun-1.0.15-1.fc27 erlang-xmpp-1.1.15-1.fc27 has been submitted as an update to Fedora 27. https://bodhi.fedoraproject.org/updates/FEDORA-2017-bb746cfd77

Comment 2 Fedora Update System 2017-12-11 16:40:19 UTC
ejabberd-17.09-2.fc27 erlang-cache_tab-1.0.11-1.fc27 erlang-esip-1.0.16-1.fc27 erlang-fast_tls-1.0.16-1.fc27 erlang-fast_xml-1.1.24-1.fc27 erlang-fast_yaml-1.0.11-1.fc27 erlang-iconv-1.0.6-1.fc27 erlang-p1_oauth2-0.6.2-1.fc27 erlang-p1_utils-1.0.10-1.fc27 erlang-stringprep-1.0.10-1.fc27 erlang-stun-1.0.15-1.fc27 erlang-xmpp-1.1.15-1.fc27 has been submitted as an update to Fedora 27. https://bodhi.fedoraproject.org/updates/FEDORA-2017-bb746cfd77

Comment 3 Fabrice Bellet 2017-12-11 21:45:26 UTC
This new update works for me, thanks for fixing it!

Comment 4 Fedora Update System 2017-12-12 15:59:14 UTC
ejabberd-17.09-2.fc27, erlang-cache_tab-1.0.11-1.fc27, erlang-esip-1.0.16-1.fc27, erlang-fast_tls-1.0.16-1.fc27, erlang-fast_xml-1.1.24-1.fc27, erlang-fast_yaml-1.0.11-1.fc27, erlang-iconv-1.0.6-1.fc27, erlang-p1_oauth2-0.6.2-1.fc27, erlang-p1_utils-1.0.10-1.fc27, erlang-stringprep-1.0.10-1.fc27, erlang-stun-1.0.15-1.fc27, erlang-xmpp-1.1.15-1.fc27 has been pushed to the Fedora 27 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-bb746cfd77

Comment 5 Fedora Update System 2017-12-28 02:47:41 UTC
ejabberd-17.09-2.fc27, erlang-cache_tab-1.0.11-1.fc27, erlang-esip-1.0.16-1.fc27, erlang-fast_tls-1.0.16-1.fc27, erlang-fast_xml-1.1.24-1.fc27, erlang-fast_yaml-1.0.11-1.fc27, erlang-iconv-1.0.6-1.fc27, erlang-p1_oauth2-0.6.2-1.fc27, erlang-p1_utils-1.0.10-1.fc27, erlang-stringprep-1.0.10-1.fc27, erlang-stun-1.0.15-1.fc27, erlang-xmpp-1.1.15-1.fc27 has been pushed to the Fedora 27 stable repository. If problems still persist, please make note of it in this bug report.