[mythtv-users] 'service mythbackend start' fails on slave backend

Mike Perkins mikep at randomtraveller.org.uk
Thu Sep 27 09:25:15 UTC 2007

Nick Morrott wrote:
> On 27/09/2007, Andrew Robinson <awrobinson-ml at nc.rr.com> wrote:
>> I am trying to setup a slave backend and I have narrowed my problem down
>> to this. When I start mythbackend from a command line like
>> '/etc/init.d/mythbackend start', mythbackend starts up and connects to
>> the database just fine. However, when I use the 'service' command, ie,
>> 'service mythbackend start', mythbackend fails to connect to the
>> database on the master backend. Apparently when I use the 'service'
>> command, I do not get the environment required. I will keep on trying to
>> track this down. While I do, has anyone else encountered this and
>> figured out a solution? I am running Fedora 7 on the slave backend.
> This is very much likely due to a bad $HOME variable. Which version of
> MythTV are you running, and how many copies of the mysql.txt do you
> have on your system? (You may have MythTV directories in /, /root and
> /home/mythtv. You need to ensure all mysql.txt contain the correct
> information for accessing the database.
> Current trunk builds should handle this issue properly, as you define
> your backend user in the config file, and the startup script handles
> it appropriately.
Also, of course, and related to the presence/absence/correct value of the $HOME 
variable, is which user you were when you started it from the command line. If 
you ran it as root, all bets are off.

To properly compare the results, you should be running the command as the same 
user that would be used when the service command is issued (or when the system 
starts up, which amounts to the same thing). My guess would be 'mythtv', but 
someone more familiar with Fedora would be able to confirm or deny this.

Mike Perkins

More information about the mythtv-users mailing list