Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CMDSRV requires more than python-systemd -> python3-systemd to run on Ubuntu 19.10 #2003

Closed
holta opened this issue Oct 14, 2019 · 5 comments

Comments

@holta
Copy link
Member

holta commented Oct 14, 2019

Now that Python 2 support is gone from Ubuntu 19.10 etc (https://launchpad.net/ubuntu/ source/python-systemd/234-3) what else is needed to make CMDSRV run below?

CONTEXT: building off PR #2002, we have 1 core remaining issue to get IIAB running on Ubuntu 19.10 that is being released this week on 2019-10-17.

4:09 PM
@tim-moody any recommendations?

TASK [cmdsrv : Install packages for cmdsrv] ************************************
changed: [127.0.0.1] => (item=libzmq3-dev)
changed: [127.0.0.1] => (item=python-cracklib)
ok: [127.0.0.1] => (item=pkg-config)
changed: [127.0.0.1] => (item=sqlite3)
changed: [127.0.0.1] => (item=libapache2-mod-wsgi)
[WARNING]: Could not find aptitude. Using apt-get instead

failed: [127.0.0.1] (item=python-systemd) => {"ansible_loop_var": "item", "changed": false, "item": "python-systemd", "msg": "No package matching 'python-systemd' is available"}

4:59 PM
Does this mean yet another case of python-xyz to python3-xyz (i.e. python-systemd -> python3-systemd) on Line 13 of https://github.com/iiab/iiab-admin-console/blob/master/roles/cmdsrv/tasks/main.yml#L13 ?

root@box:~# apt -a list python-systemd python3-systemd
Listing... Done
python3-systemd/eoan,now 234-3 amd64 [installed]

python3-systemd/eoan 234-3 i386

5:05 PM
Close but no cigar? I tried the above python3-systemd, and got much further, but then it failed here:

TASK [cmdsrv : Enable iiab-cmdsrv service] *************************************
fatal: [127.0.0.1]: FAILED! => {"changed": false, "msg": "Unable to start service iiab-cmdsrv: Job for iiab-cmdsrv.service failed because the control process exited with error code.\nSee "systemctl status iiab-cmdsrv.service" and "journalctl -xe" for details.\n"}
root@box:~# systemctl status iiab-cmdsrv

● iiab-cmdsrv.service - Provides the IIAB Command Server
Loaded: loaded (/etc/systemd/system/iiab-cmdsrv.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Mon 2019-10-14 17:03:20 EDT; 4min 27s ago
Process: 7048 ExecStart=/opt/admin/cmdsrv/iiab-cmdsrv --daemon (code=exited, status=1/FAILURE)

Oct 14 17:03:20 box.lan systemd[1]: Starting Provides the IIAB Command Server...
Oct 14 17:03:20 box.lan iiab-cmdsrv[7048]: Traceback (most recent call last):
Oct 14 17:03:20 box.lan iiab-cmdsrv[7048]: File "/opt/admin/cmdsrv/iiab-cmdsrv", line 19, in
Oct 14 17:03:20 box.lan iiab-cmdsrv[7048]: from systemd import journal
Oct 14 17:03:20 box.lan iiab-cmdsrv[7048]: ImportError: No module named systemd
Oct 14 17:03:20 box.lan systemd[1]: iiab-cmdsrv.service: Control process exited, code=exited, status=1/FAILURE
Oct 14 17:03:20 box.lan systemd[1]: iiab-cmdsrv.service: Failed with result 'exit-code'.
Oct 14 17:03:20 box.lan systemd[1]: Failed to start Provides the IIAB Command Server.

@holta
Copy link
Member Author

holta commented Oct 30, 2019

Python 3 umbrella tkt #1810 (comment) mentions:

mod_wsgi for apache can only be python 2 OR 3, not both. it is used by
captive portal
cmdsrv
pathagar

@jvonau
Copy link
Contributor

jvonau commented Nov 10, 2019

This issue won't go away while 'from systemd import journal' is in roles/cmdsrv/files/iiab-cmdsrv and a python2 shabang present. Apt has no way to supply this python2 library for cmdsrv to use.

@holta
Copy link
Member Author

holta commented Dec 12, 2019

@tim-moody @jvonau is this issue now resolved?

@tim-moody
Copy link
Contributor

yes

@holta holta closed this as completed Dec 21, 2019
@holta
Copy link
Member Author

holta commented Dec 21, 2019

Confirmed with a fresh install of http://download.iiab.io on Ubuntu Server 19.10

i.e. http://10.8.0.42/admin

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants