<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Aug 2, 2017 at 2:25 AM, Stephen Worthington <span dir="ltr"><<a href="mailto:stephen_agent@jsw.gen.nz" target="_blank">stephen_agent@jsw.gen.nz</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On Wed, 2 Aug 2017 01:03:17 -0500, you wrote:<br>
<br>
>On Tue, Aug 1, 2017 at 11:10 PM, Mark Perkins <<a href="mailto:perkins1724@hotmail.com">perkins1724@hotmail.com</a>><br>
>wrote:<br>
><br>
>> On 2 August 2017 1:17:13 pm Ashu Desai <<a href="mailto:ashu.desai@gmail.com">ashu.desai@gmail.com</a>> wrote:<br>
>><br>
>> > On Tue, Aug 1, 2017 at 8:45 PM, Hika van den Hoven <<a href="mailto:hikavdh@gmail.com">hikavdh@gmail.com</a>><br>
>> > wrote:<br>
>> ><br>
>> >> Did you check on mysql/mariadb responding to the external ip (check<br>
>> >> the wiki on how to do this.<br>
>> >><br>
>> >> The frontend/backend are on the same box - and there isn't any external<br>
>> > IP. i am testing everything all from home network.<br>
>> > Here's what I did find though:<br>
>> ><br>
>> > ---------------<br>
>> > Aug 1 22:27:32 mythmaster systemd: Started MythTV backend service.<br>
>> > Aug 1 22:27:32 mythmaster systemd: Starting MythTV backend service...<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.824647 C<br>
>> > mythbackend version: fixes/0.28 [v28.0-35-g812ec08] <a href="http://www.mythtv.org" rel="noreferrer" target="_blank">www.mythtv.org</a><br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.824669 C Qt<br>
>> > version: compile: 5.6.1, runtime: 5.6.1<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.824671 N<br>
>> > Enabled verbose msgs: general<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.824938 N<br>
>> > Setting Log Level to LOG_INFO<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.837289 I<br>
>> Added<br>
>> > logging to the console<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838125 I<br>
>> Setup<br>
>> > Interrupt handler<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838131 I<br>
>> Setup<br>
>> > Terminated handler<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838136 I<br>
>> Setup<br>
>> > Segmentation fault handler<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838138 I<br>
>> Setup<br>
>> > Aborted handler<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838142 I<br>
>> Setup<br>
>> > Bus error handler<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838150 I<br>
>> Setup<br>
>> > Floating point exception handler<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838152 I<br>
>> Setup<br>
>> > Illegal instruction handler<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838160 I<br>
>> Setup<br>
>> > Real-time signal 0 handler<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838165 I<br>
>> Setup<br>
>> > Hangup handler<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838198 N<br>
>> Read<br>
>> > conf dir = /etc/mythtv<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838229 N<br>
>> Using<br>
>> > runtime prefix = /usr<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838231 N<br>
>> Using<br>
>> > configuration directory = /etc/mythtv<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838288 I<br>
>> > Assumed character encoding: en_US.UTF-8<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838604 E<br>
>> Error<br>
>> > parsing: /etc/mythtv/config.xml at line: 1 column: 1<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838607 E<br>
>> Error<br>
>> > Msg: unexpected end of file<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838666 E<br>
>> > DBHostName is not set in config.xml<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838674 E<br>
>> > DBHostName is not set in config.xml<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838687 N<br>
>> Empty<br>
>> > LocalHostName.<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.838693 I<br>
>> Using<br>
>> > localhost value of mythmaster.localdomain<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.848276 N<br>
>> > Setting QT default locale to en_US<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.848287 I<br>
>> > Current locale en_US<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.848497 N<br>
>> > Reading locale defaults from /usr/share/mythtv//locales/en_<wbr>us.xml<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.852404 I<br>
>> > Loading en_us translation for module mythfrontend<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.858057 I<br>
>> > Current MythTV Schema Version (DBSchemaVer): 1344<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.858296 I<br>
>> > Loading en_us translation for module mythfrontend<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.860040 N<br>
>> > MythBackend: Starting up as the master server.<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.860795 W<br>
>> > MythBackend: No valid capture cards are defined in the database.<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.861100 E<br>
>> > Scheduler: No capture cards are defined in the database.<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: Perhaps you should re-read the<br>
>> > installation instructions?<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.861186 E<br>
>> Error<br>
>> > parsing: /etc/mythtv/config.xml at line: 1 column: 1<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.861188 E<br>
>> Error<br>
>> > Msg: unexpected end of file<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.940295 I<br>
>> Added<br>
>> > logging to /var/log/mythtv/mythbackend.<wbr>20170802032732.23638.log<br>
>> > Aug 1 22:27:32 mythmaster mythbackend: 2017-08-01 22:27:32.945104 I<br>
>> > Removed logging to /var/log/mythtv/mythbackend.<wbr>20170802032732.23638.log<br>
>> > Aug 1 22:27:32 mythmaster systemd: mythbackend.service: main process<br>
>> > exited, code=exited, status=1/FAILURE<br>
>> > Aug 1 22:27:32 mythmaster systemd: Unit mythbackend.service entered<br>
>> failed<br>
>> > state.<br>
>> > Aug 1 22:27:32 mythmaster systemd: mythbackend.service failed.<br>
>> ><br>
>> > --------------<br>
>> ><br>
>> > I am running this as root - so i thought the dir should show<br>
>> /root/.mythtv/<br>
>> > Looking at the dir, there is no "config.xml" under /etc/mythtv<br>
>> ><br>
>> > Maybe because I never ran this as anything but root?<br>
>> ><br>
>> ><br>
>> > [root@mythmaster ~]# ls -ahl /etc/mythtv/<br>
>> > total 32K<br>
>> > drwxr-xr-x. 6 mythtv mythtv 4.0K Aug 1 22:27 .<br>
>> > drwxr-xr-x. 140 root root 12K Aug 1 22:23 ..<br>
>> > drwxr-xr-x. 2 mythtv mythtv 4.0K Aug 1 20:00 3rdParty<br>
>> > drwxr-xr-x. 2 mythtv mythtv 4.0K Aug 1 20:00 channels<br>
>> > -rw-r--r--. 1 mythtv mythtv 0 Aug 1 22:27 config.xml<br>
>> > drwxr-xr-x. 2 mythtv mythtv 4.0K Aug 1 20:00 themes<br>
>> > drwxr-xr-x. 3 mythtv mythtv 4.0K Aug 1 20:00 tmp<br>
>> ><br>
>> > I looked into the config file - it was empty. So i created a link (ln -s)<br>
>> > from /root/.mythtv/config.xml to /etc/mythtv<br>
>> ><br>
>> > That didn't work either.<br>
>> ><br>
>> ><br>
>> >> Also, try to bottom post, this to keep the thread readable for future<br>
>> >> readers. Check the etiquettes.<br>
>> >><br>
>> >><br>
>> > Apologies.<br>
>> ><br>
>> >> ______________________________<wbr>_________________<br>
>> >> mythtv-users mailing list<br>
>> >> <a href="mailto:mythtv-users@mythtv.org">mythtv-users@mythtv.org</a><br>
>> >> <a href="http://lists.mythtv.org/mailman/listinfo/mythtv-users" rel="noreferrer" target="_blank">http://lists.mythtv.org/<wbr>mailman/listinfo/mythtv-users</a><br>
>> >> <a href="http://wiki.mythtv.org/Mailing_List_etiquette" rel="noreferrer" target="_blank">http://wiki.mythtv.org/<wbr>Mailing_List_etiquette</a><br>
>> >> MythTV Forums: <a href="https://forum.mythtv.org" rel="noreferrer" target="_blank">https://forum.mythtv.org</a><br>
>> >><br>
>> ><br>
>> ><br>
>> ><br>
>> > ----------<br>
>> > ______________________________<wbr>_________________<br>
>> > mythtv-users mailing list<br>
>> > <a href="mailto:mythtv-users@mythtv.org">mythtv-users@mythtv.org</a><br>
>> > <a href="http://lists.mythtv.org/mailman/listinfo/mythtv-users" rel="noreferrer" target="_blank">http://lists.mythtv.org/<wbr>mailman/listinfo/mythtv-users</a><br>
>> > <a href="http://wiki.mythtv.org/Mailing_List_etiquette" rel="noreferrer" target="_blank">http://wiki.mythtv.org/<wbr>Mailing_List_etiquette</a><br>
>> > MythTV Forums: <a href="https://forum.mythtv.org" rel="noreferrer" target="_blank">https://forum.mythtv.org</a><br>
>> ><br>
>><br>
>> Are you sure the BE is running as root? Are you using systemd? What is in<br>
>> your service file?<br>
>><br>
><br>
>Sorry - sent email to Mark by accident:<br>
><br>
>Systemd? Yes<br>
><br>
>[root@mythmaster ~]# pstree -p | grep system<br>
>systemd(1)-+-ModemManager(<wbr>578)-+-{ModemManager}(604)<br>
> |-systemd-journal(366)<br>
> |-systemd-logind(584)<br>
> |-systemd-udevd(397)<br>
><br>
><br>
>Not sure how to find out if BE is running as root. If you mean under the<br>
>mythbackend.service file - ( vi /usr/lib/systemd/system/<wbr>mythbackend.service)<br>
>-- then I tried both here:<br>
># systemd changes execution from the calling user (possibly root) to this<br>
>user<br>
># if you have permissions problems or obscure errors try logging in as<br>
>mythtv<br>
>User=mythtv<br>
>#User=root<br>
><br>
>I had commented out "user=mythtv" and put root instead - but that didn't<br>
>change anything.<br>
><br>
>What's in it - what was default i believe:<br>
><br>
>[Unit]<br>
>Description=MythTV backend service<br>
>After=network-online.target mariadb.service mysqld.service time-sync.target<br>
># Uncomment the following line if you will be using the mythweb plugin on<br>
>the<br>
># same system as mythbackend.<br>
>#Wants=httpd.service<br>
><br>
>[Service]<br>
># Type=simple is recommended. If using Type=forking you will need to<br>
>specify a<br>
># pidfile so systemd knows how to find the forked process PID, otherwise it<br>
># presumes that the process being started will be the remaining process.<br>
>#Type=forking<br>
>Type=simple<br>
>Environment=MYTHCONFDIR=/etc/<wbr>mythtv<br>
><br>
># systemd changes execution from the calling user (possibly root) to this<br>
>user<br>
># if you have permissions problems or obscure errors try logging in as<br>
>mythtv<br>
>User=mythtv<br>
>#User=root<br>
># Uncomment one of the following...<br>
># Use sysloging rather than separate logging:<br>
>#ExecStart=/usr/bin/<wbr>mythbackend --syslog local7<br>
># If Type=forking is set you must specify the --daemon and --pidfile<br>
>options:<br>
>#ExecStart=/usr/bin/<wbr>mythbackend --daemon --logpath /var/log/mythtv<br>
>--loglevel crit --pidfile /run/mythbackend.pid<br>
># Default setting for Type=simple.<br>
>ExecStart=/usr/bin/<wbr>mythbackend --logpath /var/log/mythtv<br>
><br>
>[Install]<br>
>WantedBy=multi-user.target<br>
><br>
>-----------------------------<wbr>---<br>
><br>
>Also noticed that since the path is /etc/mythtv (not /root/.mythtv)<br>
>the permissions are:<br>
>[root@mythmaster ~]# ls -ahl /etc/mythtv<br>
>total 36K<br>
>drwxr-xr-x. 6 mythtv mythtv 4.0K Aug 1 22:44 .<br>
>drwxr-xr-x. 140 root root 12K Aug 1 22:23 ..<br>
>drwxr-xr-x. 2 mythtv mythtv 4.0K Aug 1 20:00 3rdParty<br>
>drwxr-xr-x. 2 mythtv mythtv 4.0K Aug 1 20:00 channels<br>
>-rw-r--r--. 1 mythtv mythtv 513 Aug 1 22:44 config.xml<br>
>-rw-r--r--. 1 root root 0 Aug 1 22:43 config.xml.old<br>
>drwxr-xr-x. 2 mythtv mythtv 4.0K Aug 1 20:00 themes<br>
>drwxr-xr-x. 3 mythtv mythtv 4.0K Aug 1 20:00 tmp<br>
><br>
><br>
>Wondering if there is a need to change either the path or permissions?<br>
<br>
</div></div>The normal way to run mythbackend is to have it run as the mythtv<br>
user. I have never run it as root, but it may not be intended to run<br>
that way and it could cause complications. You do have to have a<br>
mythtv user on the system for that to work, but it does not have to be<br>
a login enabled user. The default is to also have a mythtv group (to<br>
which the mythtv user and any user that runs mythfrontend must<br>
belong). Then you put all the things that mythbackend needs in the<br>
/home/mythtv/.mythtv directory, such as config.xml and the channels<br>
directory with all the channel icon files. If you want to have just<br>
one config.xml file, then you can put that in /etc/mythtv and ln -s to<br>
it from all the /home/<username>/.mythtv directories.<br></blockquote><div><br></div><div>Created another VM - same issue even when doing mythtv as the user and running as mythtv.</div><div><br></div><div>Works if backend IP is 127.0.0.1 but not otherwise.</div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
This is what a good config.xml file looks like (copied from my test PC<br>
which was installed as a 0.28 system a few months ago):<br>
<br>
<Configuration><br>
<Database><br>
<PingHost>1</PingHost><br>
<Host>10.0.2.12</Host><br>
<UserName>mythtv</UserName><br>
<Password>********</Password><br>
<DatabaseName>mythconverg</<wbr>DatabaseName><br>
<Port>3306</Port><br>
</Database><br>
<WakeOnLAN><br>
<Enabled>0</Enabled><br>
<SQLReconnectWaitTime>0</<wbr>SQLReconnectWaitTime><br>
<SQLConnectRetry>5</<wbr>SQLConnectRetry><br>
<Command>echo 'WOLsqlServerCommand not set'</Command><br>
</WakeOnLAN><br>
</Configuration><br>
<br></blockquote><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
There are some other things that can be added to the config.xml file<br>
by mythfrontend, but those settings are what is wanted by mythbackend.<br>
Fill in the correct names, addresses and password for your system. You<br>
may or may not need the pinghost option set on - I have it on because<br>
I am connecting via the external IP address for the PC, not localhost,<br>
so I do not want mythbackend to try to connect until that address is<br>
pingable.<br>
<br>
There are different older formats for config.xml that also seem to<br>
still work, but I believe the above is the current format.<br>
<div class="HOEnZb"><div class="h5">______________________________<wbr>_________________<br>
mythtv-users mailing list<br>
<a href="mailto:mythtv-users@mythtv.org">mythtv-users@mythtv.org</a><br>
<a href="http://lists.mythtv.org/mailman/listinfo/mythtv-users" rel="noreferrer" target="_blank">http://lists.mythtv.org/<wbr>mailman/listinfo/mythtv-users</a><br>
<a href="http://wiki.mythtv.org/Mailing_List_etiquette" rel="noreferrer" target="_blank">http://wiki.mythtv.org/<wbr>Mailing_List_etiquette</a><br>
MythTV Forums: <a href="https://forum.mythtv.org" rel="noreferrer" target="_blank">https://forum.mythtv.org</a><br>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><a href="http://about.me/adesai" target="_blank">http://about.me/adesai</a></div>
</div></div>