Hallo Experten,
ich habe bis auf eine Kleinigkeit nun einen meiner CM4-Pis auf Bookworm mit Python3.11, aktueller SmarhomeNG und aktueller SmarVisu umgestellt. Alles läuft extrem gut und dabei sogar performanter und resourcenschonender (Temperatur und Taktfrequenz) als zuvor. Ich bin vollends zufrieden und würde auch den 2ten Pi, die heutige Produktivversion, umstellen, aber leider klappt das i-Tüpfelchen noch nicht: der systemctl-Start (ohne systemctl per Hand geht es).
Die Smarthome-Applikation kommt mit systemctl nicht hoch, sie verharrt in einer Schleife und will etwas (nach-)installieren, was aber gar nicht nötig ist, siehe:
/etc/systemd/system/smarthome.service enthält ganz normal das "Notwendige":
Hat jemand ähnliche Erfahrungen? Ich denke der "intern eingebaute" aufruf von
ist das Problem unter Python 3.11, wenn ich das manuell mache, gibt es Fehler:
Hat jemand eine Lösung? Vielen Dank im Voraus!
Grüße,
Ralf
ich habe bis auf eine Kleinigkeit nun einen meiner CM4-Pis auf Bookworm mit Python3.11, aktueller SmarhomeNG und aktueller SmarVisu umgestellt. Alles läuft extrem gut und dabei sogar performanter und resourcenschonender (Temperatur und Taktfrequenz) als zuvor. Ich bin vollends zufrieden und würde auch den 2ten Pi, die heutige Produktivversion, umstellen, aber leider klappt das i-Tüpfelchen noch nicht: der systemctl-Start (ohne systemctl per Hand geht es).
Die Smarthome-Applikation kommt mit systemctl nicht hoch, sie verharrt in einer Schleife und will etwas (nach-)installieren, was aber gar nicht nötig ist, siehe:
Code:
pi@cm4-io-base-box-1:~ $ sudo systemctl start smarthome.service pi@cm4-io-base-box-1:~ $ ps -eaf | grep smarthome smartho+ 2794 1 48 10:59 ? 00:00:00 /usr/bin/python3 /usr/local/smarthome/bin/smarthome.py smartho+ 2796 2794 0 10:59 ? 00:00:00 /bin/sh -c /usr/bin/pip3 install -r /usr/local/smarthome/requirements/base.txt --user --no-warn-script-location smartho+ 2797 2796 99 10:59 ? 00:00:00 /usr/bin/python3 /usr/bin/pip3 install -r /usr/local/smarthome/requirements/base.txt --user --no-warn-script-location pi 2799 1253 0 10:59 pts/0 00:00:00 grep --color=auto smarthome pi@cm4-io-base-box-1:~ $ ps -eaf | grep smarthome smartho+ 2800 1 96 10:59 ? 00:00:00 /usr/bin/python3 /usr/local/smarthome/bin/smarthome.py pi 2806 1253 0 10:59 pts/0 00:00:00 grep --color=auto smarthome pi@cm4-io-base-box-1:~ $ ps -eaf | grep smarthome smartho+ 2827 1 93 10:59 ? 00:00:00 /usr/bin/python3 /usr/local/smarthome/bin/smarthome.py pi 2833 1253 0 10:59 pts/0 00:00:00 grep --color=auto smarthome pi@cm4-io-base-box-1:~ $ ps -eaf | grep smarthome smartho+ 2849 1 37 10:59 ? 00:00:00 /usr/bin/python3 /usr/local/smarthome/bin/smarthome.py smartho+ 2851 2849 0 10:59 ? 00:00:00 /bin/sh -c /usr/bin/pip3 install -r /usr/local/smarthome/requirements/base.txt --user --no-warn-script-location smartho+ 2852 2851 99 10:59 ? 00:00:00 /usr/bin/python3 /usr/bin/pip3 install -r /usr/local/smarthome/requirements/base.txt --user --no-warn-script-location pi 2854 1253 0 10:59 pts/0 00:00:00 grep --color=auto smarthome pi@cm4-io-base-box-1:~ $
Code:
[Unit] Description=SmartHomeNG daemon After=network.target After=knxd.service After=knxd.socket [Service] Type=forking ExecStart=/usr/bin/python3 /usr/local/smarthome/bin/smarthome.py WorkingDirectory=/usr/local/smarthome User=smarthome PIDFile=/usr/local/smarthome/var/run/smarthome.pid Restart=on-failure TimeoutStartSec=900 RestartForceExitStatus=5 [Install] WantedBy=default.target
/usr/bin/python3 /usr/bin/pip3 install -r /usr/local/smarthome/requirements/base.txt --user --no-warn-script-location
Code:
(py_shng) smarthome@cm4-io-base-box-1:/usr/local/smarthome $ /usr/bin/python3 /usr/bin/pip3 install -r /usr/local/smarthome/requirements/base.txt --user --no-warn-script-location error: externally-managed-environment This environment is externally managed To install Python packages system-wide, try apt install python3-xyz, where xyz is the package you are trying to install. If you wish to install a non-Debian-packaged Python package, create a virtual environment using python3 -m venv path/to/venv. Then use path/to/venv/bin/python and path/to/venv/bin/pip. Make sure you have python3-full installed. For more information visit http://rptl.io/venv note: If you believe this is a mistake, please contact your Python installation or OS distribution provider. You can override this, at the risk of breaking your Python installation or OS, by passing --break-system-packages. hint: See PEP 668 for the detailed specification. (py_shng) smarthome@cm4-io-base-box-1:/usr/local/smarthome $
Grüße,
Ralf
Kommentar