[mythtv-users] mythbackend not responding on port 6543

Karl Newman newmank1 at asme.org
Thu Nov 17 14:24:11 UTC 2016


On Wed, Nov 16, 2016 at 10:11 PM, Stephen Worthington <
stephen_agent at jsw.gen.nz> wrote:

> On Wed, 16 Nov 2016 20:55:35 -0800, you wrote:
>
> >On Wed, Nov 16, 2016 at 6:59 PM, Stephen Worthington <
> >stephen_agent at jsw.gen.nz> wrote:
> >
> >> On Tue, 15 Nov 2016 07:04:34 -0800, you wrote:
> >>
> >> >On Tue, Nov 15, 2016 at 5:41 AM, Stephen Worthington <
> >> >stephen_agent at jsw.gen.nz> wrote:
> >> >
> >> >> On Tue, 15 Nov 2016 01:33:53 +1300, you wrote:
> >> >>
> >> >> The conclusion I reached from this is that the problem is related to
> >> >> my database somehow, rather than the versions of any software I am
> >> >> running.  Something about my current database triggers the problem.
> >> >>
> >> >>
> >> >It might be enlightening to do a dump and diff of the settings table
> from
> >> >your working vs. non-working backups.
> >> >
> >> >Karl
> >>
> >> Thanks for the idea.  Doing it with database tables is a just a *bit*
> >> more difficult than using the diff command, but I worked it out.  So
> >> can anyone see any problems in the diff?  I can not.
> >>
> >> If you can not read it properly in your email program, I have also put
> >> it in a file on my web server:
> >>
> >>   http://www.jsw.gen.nz/mythtv/6543/settings_diff.txt
> >>
> >> MariaDB [mythconverg]> select hostname,value,data from (select
> >> s.hostname,s.value,s.data from settings s union all select
> >> o.hostname,o.value,o.data from settings_old o) t where hostname is
> >> null or hostname='mypvr' group by hostname,value having count(*)=1
> >> order by hostname,value;
> [snip]
> >I was thinking of something conceptually simpler, like doing a select on
> >each settings table, dumping the results to a text file and then diff'ing
> >the two files (an ORDER BY clause could help there). Since your statement
> >is doing a union, it doesn't show the differences (if any).
> >
> >Karl
>
> Yes, it does show the differences.  It is using a sneaky sql trick
> from this page:
>
>
> http://www.mysqltutorial.org/compare-two-tables-to-find-
> unmatched-records-mysql.aspx
>
> Trying to do a text diff of tables is quite difficult, due to the
> variable length of fields and the way the output table is formatted to
> accommodate only the longest actual length of a field.  You have to do
> fixed length formatting on all fields to have a chance for a text diff
> to work.
>

Ah, I forgot about variable column widths. The "union all" confused me. Is
there any way to identify which row goes with which table? I wonder if you
could add a constant to the select string such as:
select hostname,value,data from (select "s1",s.hostname,s.value,s.data from
settings s union all select "s2, o.hostname,o.value,o.data from
settings_old o) t where hostname is null or hostname='mypvr' group by
hostname,value having count(*)=1 order by hostname,value;

Karl
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mythtv.org/pipermail/mythtv-users/attachments/20161117/167fdc43/attachment.html>


More information about the mythtv-users mailing list