[mythtv-users] Using database backup as starting point for new backend

David Hampton mythtv at love2code.net
Sat Oct 26 19:58:43 UTC 2019

On Sat, 2019-10-26 at 15:41 -0400, James Abernathy wrote:
> So I have a production mythtv backend called “mythbuntu”.  I have a
> new backend built on a Raspberry Pi 4 on the same network. It’s name
> is “raspberrypi”.  I’m wanting to parallel test these systems for a
> few months with the same recording rules to see how the RP4 performs.
> “mythbuntu” has Hauppauge WinTV Quad tuners and “raspberrypi” has
> HDHR Quatro tuners. So in theory they both should record the same
> programs since all tuners are on the same antenna.
> I started by taking a database backup of mythbuntu and restoring it
> on raspberrypi. I also copied all the recordings over to raspberrypi.
> I had some problems cleaning up the changes needed on raspberrypi to
> General, Tuners, and input connections. 
> There was some problem with the master backend settings because it
> wanted to setup raspberrypi as a slave off of mythbuntu. I got that
> fixed and both backends showed the same recordings and schedules for
> future recordings.  
> SO my current issue is, I tried to look for problems on raspberrypi
> with find_orphans.py. It seemed to show duplicate entries and files
> on both mythbuntu and raspberrypi. I don’t know if this was an issue
> on just the database on raspberrypi or was find_orphans looking on
> the network at both backends?
> I ended up deleting a lot of recordings on the raspberrypi I didn’t
> want deleted so I’m going to have to repeat the process.  Any advice
> on what I should have done???

One of the columns in the recorded table is the hostname where the
recording lives.  Did you update this field?

The best way to change hostnames is with the mythconverg_restore.pl
script.  Restore the database on the new system, and then run the
script again with different arguments:

    mythconverg_restore.pl \
      --change_hostname \
      --old_hostname="XXXX" \

I did this a while back.  I can't remember whether or not I had your
problem of the new backend trying to find the old backend.


More information about the mythtv-users mailing list