[mythtv-users] How to re-enable disconnected encoders on slave backend

Marc MERLIN marc_mtv at merlins.org
Tue Sep 23 07:39:51 UTC 2008


So, restarting the master backend didn't help, and deleting and re-adding
all the encoders didn't help either :(

Mmmh, after that things even got worse on the master:
2008-09-23 00:09:57.503 Empty LocalHostName.
2008-09-23 00:09:57.504 Using localhost value of myth
2008-09-23 00:09:57.510 New DB connection, total: 1
2008-09-23 00:09:57.513 Connected to database 'mythconverg' at host: myth
2008-09-23 00:09:57.514 Closing DB connection named 'DBManager0'
2008-09-23 00:09:57.515 Connected to database 'mythconverg' at host: myth
2008-09-23 00:09:57.516 New DB connection, total: 2
2008-09-23 00:09:57.517 Connected to database 'mythconverg' at host: myth
2008-09-23 00:09:57.518 Current Schema Version: 1214
Running as a slave backend.
2008-09-23 00:09:57.523 mythbackend: MythBackend started as a slave backend
^^^^^^^^^^^^^^^^^^^^^^^^^

This was due to your telling me that 
> > i) The Master Backend should have value='MasterServerIP',                                               
> > data=''your.ip.address' and hostname='NULL'

I set the hostname back:
MasterServerIP  	192.168.205.61  	myth
and that part got fixed:
Starting up as the master server.
2008-09-23 00:12:20.788 mythbackend: MythBackend started as master server

and I'm back at square one:
Encoders:
myth (1) - Idle
myth (2) - Idle
myth (3) - Idle
myth (4) - Idle
gargamel.svh.merlins.org (5) - -1 (Disconnected)
gargamel.svh.merlins.org (6) - -1 (Disconnected)
and
2008-09-23 00:15:00.827 PlaybackBox::play(): Error, myth://192.168.205.3:6543/1068_20080919220000.mpg file not found
and my frontend still clearly decides that nothing is on 192.168.205.3,
because strace on that server does not show a single connection or anything
happening on that mythbackend process.

Clearly, communication between myth (192.168.205.61) and gargamel
(192.168.205.3) is failing in some way, but gargamel does connect
to the right DB:
gargamel:~# /etc/init.d/mythtv-backend start
Starting MythTV server: mythbackend .
gargamel:~# 2008-09-23 00:24:24.669 Using runtime prefix = /usr, libdir = /usr/lib
2008-09-23 00:24:24.706 Empty LocalHostName.
2008-09-23 00:24:24.738 Using localhost value of gargamel.svh.merlins.org
2008-09-23 00:24:24.752 Testing network connectivity to myth
2008-09-23 00:24:24.794 New DB connection, total: 1
2008-09-23 00:24:24.833 Connected to database 'mythconverg' at host: myth
2008-09-23 00:24:24.842 Closing DB connection named 'DBManager0'
2008-09-23 00:24:24.857 Connected to database 'mythconverg' at host: myth
2008-09-23 00:24:24.872 New DB connection, total: 2
2008-09-23 00:24:24.892 Connected to database 'mythconverg' at host: myth
2008-09-23 00:24:24.909 Current Schema Version: 1214
Running as a slave backend.
2008-09-23 00:24:24.951 New DB connection, total: 3
2008-09-23 00:24:24.968 Connected to database 'mythconverg' at host: myth
2008-09-23 00:24:25.664 Main::Registering HttpStatus Extension
2008-09-23 00:24:25.680 mythbackend version: 0.21.20080304-1 www.mythtv.org
2008-09-23 00:24:25.691 Enabled verbose msgs:  important general
2008-09-23 00:24:26.713 Connecting to master server: :6543
2008-09-23 00:24:26.745 Connected successfully

although I'm not sure what this means afterwards:
2008-09-23 00:24:56.760 MythSocket(827e650:11): readStringList: Error, timeout.
2008-09-23 00:24:56.905 adding: gargamel.svh.merlins.org as a slave backend server
2008-09-23 00:24:56.925 MythSocket(8298d58:-1): writeStringList: Error, socket went unconnected.

At this point, I should see my slave backend registered on my master backend
in /var/log/mythtv/mythbackend.log, right? but I do not.

That's probably where my problem lies.
Just to be extra sure, strace of mysql on myth does show gargamel connecting to it
when I start the slave backend, so it's talking to the right DB.

gargamel is running  mythtv-backend 0.21-0.13 (debian)
myth is running mythtv-backend 0.21.0+fixes16838-0ubuntu3 (ubuntu)

ls -l /var/lib/dpkg/info/mythtv-backend.list
on both servers shows that the packages date back to 2008-05-14, so they
didn't just get upgraded and they were able to talk to one another just fine
back then. I doubt the protocol just changed without the packages changing.
Either way, myth says:
2008-09-23 00:10:00.853 mythbackend version: 0.21.20080304-1 www.mythtv.org
and gargamel says:
2008-09-23 00:27:19.298 mythbackend version: 0.21.20080304-1 www.mythtv.org

so they are compatible.

I'm really at a loss, what now?

Thanks,
Marc

On Mon, Sep 22, 2008 at 10:17:48PM -0700, Marc MERLIN wrote:
> On Tue, Sep 23, 2008 at 04:24:59AM +0100, Nick Morrott wrote:
> > >  However I still can't play old recordings on my slave backend:
> > >
> > >  2008-09-22 09:29:07.525 PlaybackBox::showActions(): Error, myth://192.168.205.3:6543/1003_20080920232900.mpg file not found
> > 
> > If you want to check in the database (take a backup first just in case):
> > 
> > mysql> SELECT DISTINCT `hostname` FROM `recorded` ORDER BY `hostname`;
> 
> Looks good:
> mysql> SELECT DISTINCT `hostname` FROM `recorded` ORDER BY `hostname`;
> +--------------------------+
> | hostname                 |
> +--------------------------+
> | gargamel.svh.merlins.org | 
> | myth                     | 
> +--------------------------+
> 
> > This will list the different hosts that MythTV think recordings are
> > stored on. If there are any disparities here between 'what was' and
> > 'what is', you will get problems. Does the backend where you believe
> > the missing file to reside agree have an IP address of '192.168.205.3'
> > ?
>  
> Yes, and the file is there :)
> gargamel:/var/spool/mythtv/recording.gargamel# l 1003_20080920232900.mpg
> -rw-r--r-- 1 mythtv mythtv 2927334268 2008-09-21 01:02 1003_20080920232900.mpg
> gargamel:~# host gargamel; host 192.168.205.3
> gargamel.svh.merlins.org has address 192.168.205.3
> 3.205.168.192.in-addr.arpa domain name pointer gargamel.svh.merlins.org.
> 
> > If you reference this message with my reply to another of your
> > messages, you may begin to see how your machines' identities are
> > stored in the MythTV database.
> 
> Yes, looking at that now.
> 
> On Tue, Sep 23, 2008 at 04:13:35AM +0100, Nick Morrott wrote:
> > >  Just to make sure, the slave can only get its settings from the mysql server
> > >  on my master backend, so if the old IP of my backend has been fixed in all
> > >  mythconverg tables in mysql, this shouldn't happen, right?
> > >
> > >  Is there some other place that I should have looked at/fixed?
> > 
> > In the settings table:
> > 
> > i) The Master Backend should have value='MasterServerIP',
> > data=''your.ip.address' and hostname='NULL'.
> > ii) Each backend (the master backend and any slaves) should have
> > value='BackendServerIP', data='backend.ip.address' and
> > hostname='your.hostname'.
> > 
> > mysql> SELECT * FROM `settings` WHERE `value` LIKE '%ServerIP%';
>  
> MasterServerIP  	192.168.205.61  myth
> ZoneMinderServerIP 	192.168.205.61 	myth	(was 127.0.0.1)
> BackendServerIP 	192.168.205.61 	myth
> BackendServerIP 	192.168.205.3 	gargamel.svh.merlins.org
> BackendServerIP 	192.168.205.62 	myth-lvr
> 
> Ah, so maybe the MasterServerIP is bad since it has 'myth' and not 'NULL'.
> This doesn't seem to have helped though (although I haven't restarted the
> master backend yet, due to an ongoing recording).
>  
> > You can also run:
> > 
> > mysql> SELECT DISTINCT `hostname` FROM `settings` ORDER BY `hostname`;
> > 
> > to see whether you have old/conflicting hostname entries in the settings table.
> 
> More stuff in there, including other occasional frontends.
> mysql> SELECT DISTINCT `hostname` FROM `settings` ORDER BY `hostname`;
> +-----------------------------+
> | hostname                    |
> +-----------------------------+
> | NULL                        | 
> | (none)                      | 
> | gandalf.merlins.org         | 
> | gandalfthewhite.merlins.org | 
> | gargamel.svh.merlins.org    | 
> | myth                        | 
> | myth-lvr                    | 
> | yourhost                    | 
> +-----------------------------+
> 
> but I'm not too sure what to do with this since I didn't change hostnames.
>  
> > Your slave machine will have either a mysql.txt or config.xml
> > configuration file for MythTV in ~/.mythtv/ for the frontend and
> > backend users (and possibly elsewhere too). To be on the safe side,
> > check that these contain the correct settings for your current
> > database configuration.
>  
> Yes, that's good advise, I got bitten by this before, but my deb packages
> are good now and have a symlink from ~mythtv/.mythtv/mysql.txt to
> /etc/mythtv/mysql.txt
> 
> gargamel:~# cat /etc/mythtv/mysql.txt
> DBHostName=myth
> #DBHostPing=no
> DBUserName=mythtv
> DBPassword=XXXXXX
> DBName=mythconverg
> DBType=QMYSQL3
> 
> > I'd also recommend the full 'Delete All Capture Cards' on the master
> > backend machine, adding back your cards in order of preference,
> > highest first. This doesn't touch your channels configuration - you'd
> > just need to reconfigure the Input Connections on the master and slave
> > backends with the existing video sources.
> 
> Ok. Then as soon as the 2nd hour of the new season of Heroes is done
> recording, I'll give that a shot :)
> (just after I restart the master backend first)
> 
> Thanks for the replies,
> Marc
> -- 
> "A mouse is a device used to point at the xterm you want to type in" - A.S.R.
> Microsoft is to operating systems & security ....
>                                       .... what McDonalds is to gourmet cooking
> Home page: http://marc.merlins.org/  
> _______________________________________________
> mythtv-users mailing list
> mythtv-users at mythtv.org
> http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users
> 

-- 
"A mouse is a device used to point at the xterm you want to type in" - A.S.R.
Microsoft is to operating systems & security ....
                                      .... what McDonalds is to gourmet cooking
Home page: http://marc.merlins.org/  



More information about the mythtv-users mailing list