[mythtv-users] I broke my mythTV, help!

Bill Meek keemllib at gmail.com
Fri Nov 9 04:38:32 UTC 2018


On 11/7/18 10:18 PM, Douglas Peale wrote:
> On 11/7/18 6:51 PM, Bill Meek wrote:
>> On 11/7/18 4:26 PM, Bill Meek wrote:

...

>> I just tested:
>>
>> sudo systemctl edit mythtv-backend.service
>>
>> and added the following two lines there:
>>
>> [Service]
>> Environment="MYTHCONFDIR=/etc/mythtv"
>>
>> That causes the backend to start with /etc/mythtv as the configuration
>> directory where it will find your config.xml (if it's still there.)
>>
>> You should see entries in the backend log showing
>> that /etc/mythtv is being used:
>>
>> ... mythdirs.cpp:37 (InitializeMythDirs) - Read conf dir = /etc/mythtv (tells you MYTHCONFDIR is set)
>> ... mythdirs.cpp:205 (InitializeMythDirs) - Using configuration directory = /etc/mythtv (shows it in use)
>>
> Now I am really confused.
> 
> $ cat /etc/systemd/system/mythtv-backend.service.d/override.conf
> [Service]
> Environment="MYTHCONFDIR=/etc/mythtv"

FYI, *systemctl cat mythtv-backend* (or other systemd files, e.g. anacron.timer)
will print the service AND all overrides including their paths. It eliminates
the need to figure out where files live and which are active.

...

> $ ls -l /home/mythtv/.mythtv/config.xml
> lrwxrwxrwx 1 mythtv mythtv 22 Jun  7  2014 /home/mythtv/.mythtv/config.xml -> /etc/mythtv/config.xml
> 
> 
> I don't understand it, but mythbackend is running again.

Note that this wasn't so much a solution as a proof of concept. There's
something getting in the way of systemd and/or mythbackend. My guess
remains the link mentioned earlier to $HOME on the other disk. Setting
User=mythtv in the .service normally works just fine and would cause
~mythtv/.mythtv/config.xml to be used (even if that file is a link
somewhere else.)

...

-- 
Bill


More information about the mythtv-users mailing list