Closed jfabernathy closed 7 months ago
Additional Information: Per default, Debian installs and runs the mythtv-backend systemd service with
[Service]
User=mythtv
Environment=HOME=/var/lib/mythtv
Maybe, it is enough to check for $HOME ?
I fixed this by changing the Environment= to:
Environment=HOME=/home/mythtv
Since I used sudo systemctl edit --full mythtv-backend.service
to perform the edit, I hope this will not get overwritten by system updates.
It would be nice if deb-multimedia's version of mythtv package could test for an existing user 'mythtv' and change it's mythtv-backend.service file. Not sure where to bring this up.
Not sure where to bring this up.
I recommend dmo-discussion: https://www.deb-multimedia.org/mailinglist
I'll take the discussion there.
http://www.deb-multimedia.org/lurker/message/20240301.140328.78427221.en.html
If you type: systemctl --run cat mythtv-backend.service, you'll see (on the 1st line) where the active service lives. Should be under /etc/...
If you have any drop-ins, they will be displayed later in the output.
systemctl --global cat mythtv-backend.service should show the service file that the distribution created. The one you created will be used in place of that and shouldn't be touched by the distro.
-- Bill
Thanks, Bill. That is helpful. Not sure what the output of the --global version means in my case. Output below:
im@den-pc:~$ systemctl --run cat mythtv-backend.service
# /lib/systemd/system/mythtv-backend.service
[Unit]
Description=MythTV Backend
Documentation=https://www.mythtv.org/wiki/Mythbackend
After=mysql.service network.target
[Service]
User=mythtv
Environment=HOME=/var/lib/mythtv
EnvironmentFile=-/etc/default/mythtv-backend
ExecStart=/usr/bin/mythbackend $EXTRA_ARGS
StartLimitBurst=10
StartLimitInterval=10m
Restart=on-failure
RestartSec=1
[Install]
WantedBy=multi-user.target
# /etc/systemd/system/mythtv-backend.service.d/override.conf
[Service]
ExecStartPre=-/usr/local/bin/hdhomerun_check.py 169.254.235.152
jim@den-pc:~$ systemctl --global cat mythtv-backend.service
No files found for mythtv-backend.service.
jim@den-pc:~$
--global didn't work the way I thought. Try a simple:
ls -l /lib/systemd/system/mythtv-backend.service
To see if the distro put the service there.
the deb-multimedia.org maintainer for mythtv will remove the Environment=HOME=/var/lib/mythtv statement in the next upload. That fixes the issue.
Platform: Debian 12 Bookworm Linux den-pc 6.1.0-18-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.76-1 (2024-02-01) x86_64 GNU/Linux
MythTV version: v34 installed from deb-multimedia.org
Package version: v34.0-d941a6d21ac
Component: Web App
What steps will reproduce the bug?
If I install mythtv from deb-multimedia.org stable-backports without creating a mythtv user first, the web app launches and show immediately that the mythconverg database is up and working and it shows a random password which matches what is in /etc/mythtv/config.xml
However, If you create the mythtv user first and assign a GID, UID, --shell, and --home, before installing mythtv from DMO, on first use of the web app the database connection shows as failed and the password for mythconverg is 'mythtv'.
The password in /etc/mythtv/config.xml shows as a random password and if you copy it to the web app field for mythconverg password and then save and restart, everything shows connected and you can proceed. I haven't tested this on Ubuntu in a while but I have never had this problem and I've know I've sometimes created the mythtv user ahead of time. I don't recall any issues.
How often does it reproduce? Is there a required condition?
What is the expected behaviour?
What do you see instead?
Additional information