[mythtv-users] Upgrading from old versions and preserving the database

Michael T. Dean mtdean at thirdcontact.com
Fri Jul 29 19:25:14 UTC 2011


On 07/29/2011 03:16 PM, DFishburn wrote:
> On 7/25/2011 2:57 PM, mythtv-users wrot
>> Because you'll be getting a different MySQL version, you'll want to do
>> a full backup ( http://www.mythtv.org/wiki/Database_Backup_and_Restore
>> ) on your 0.21-fixes system. Note that the backup script will work
>> with any version of MythTV, so even though it's not shipped with
>> 0.21-fixes, you can download it (as described in the wiki page), then
>> use it to make a backup. Then, after re-installed the operating
>> system, you'll restore the database, while replacing the existing
>> database (
>> http://www.mythtv.org/wiki/Database_Backup_and_Restore#Replacing_an_existing_database
>> ).
> On my Myth 21 box I downloaded a new backup script and ran it, copied
> over the file to my "test" machine.
>
> I just tried this out on Mythbuntu 11-04 (which should be MythTV 24 at
> least).
>
> I essentially used this command line:
>
> mythconverg_restore.pl --drop_database --create_database --filename mythconverg-1214-20080626150513.sql.gz
>
> Ran myth-setup, it asked if I wanted to upgrade my database.
> The upgrade succeeded, restarted myth backend and the frontend.
>
> Now, I get a message box on the FE startup:
> "The server uses network protocol version 40,
> but this client only understands version 63.
> Make sure you are running compatible versions
> of the backend and frontend."
>
> Now that I am typing this up, am I just realized I am "switching hosts",
> since I am trying it on a test machine.
>
> Mike also mentioned this:
>> I highly recommend using the same host name and IP address for your
>> machine, so that you don't have to change the host names in the
>> database, but if you must use a different host name, see
>> http://www.mythtv.org/wiki/Database_Backup_and_Restore#Change_the_hostname_of_a_MythTV_frontend_or_backend
>> .  If you change the IP address, you'll need to re-run mythtv-setup and
>> update the IP address setting for "this backend" and possibly for the
>> master backend.
> So I am assuming I can simply run this:
>
> mythconverg_restore.pl --change_hostname --old_hostname="192.168.0.40" --new_hostname="192.168.0.55"
>
>
> And then restart the frontend.
>
> I will try this later tonight, but if there are other things to try or
> check first, I am double checking.

If you've already run any MythTV apps on the system with the new host 
name, that will almost definitely fail (as described in the wiki entry 
you quoted).

If so, you need to re-restore the database, as above, then change host 
name, then start your MythTV programs.

Also, are you really using IP addresses as host names?  (Normally, 
MythTV uses the same value as would be output by the command 'hostname', 
but you can override the name using a LocalHostName override in 
mysql.txt or config.xml.)

If all that changed is your IP address--and your host name is the 
same--just run mythtv-setup and correct the IP address for the master 
backend and "this" backend.

Mike


More information about the mythtv-users mailing list