<br><div class="gmail_quote"><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><br>
Message: 16<br>
Date: Mon, 23 Feb 2009 21:18:39 -0500<br>
From: "Michael T. Dean" <<a href="mailto:mtdean@thirdcontact.com">mtdean@thirdcontact.com</a>><br>
Subject: Re: [mythtv-users] Channel Line-up Export<br>
To: Discussion about mythtv <<a href="mailto:mythtv-users@mythtv.org">mythtv-users@mythtv.org</a>><br>
Message-ID: <<a href="mailto:49A358FF.6040505@thirdcontact.com">49A358FF.6040505@thirdcontact.com</a>><br>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed<br>
<br>
On 02/23/2009 09:11 PM, MrVining wrote:<br>
> On Feb 23, 2009, at 7:49 PM, Nick Rout wrote:<br>
>> On Tue, Feb 24, 2009 at 10:15 AM, MrVining wrote:<br>
>>> I'm building a new MythTV master backend as we speak. I've done some<br>
>>> googling and searched the wiki a bit, but I not really finding<br>
>>> much. Is<br>
>>> there a somewhat simple way to export/backup my channel line-up?<br>
>> just the channel line up or the whole database?<br>
>><br>
>> <a href="http://www.mythtv.org/wiki/Database_Backup_and_Restore" target="_blank">http://www.mythtv.org/wiki/Database_Backup_and_Restore</a><br>
> Just the Line-up. Partly because I want to do a sort of perm. backup<br>
> of some of my setup.<br>
<br>
There's a section on that wiki page that talks about backing up<br>
xmltvid's. I'm planning to rewrite the backup/restore support to make<br>
it easier (will be a normal full backup instead of a special backup).<br>
The restore will then take a look at the old channels and try to match<br>
them up with the new channels and try to modify the settings of the new<br>
channels to match what you had previously (i.e. things like xmltvid,<br>
useeit, visible, ...).<br>
<br>
However, I doubt there will /ever/ be a (safe/reliable) way to just<br>
backup up and then restore the channels (and all associated channel<br>
info) themselves. Instead, you'd have to do a backup, fetch channels<br>
from listings provider or scan for channels, then "restore" channel<br>
settings on top of the new channels.<br>
<br>
The best backup--for now or after I finish the channel restore<br>
rewrite--is a full backup.<br>
</blockquote><div><br><br>Is there something special about the xmltvids ? I'm only using them for my analog source, as everything else has EIT (DVB-S/S2 and DVBC). I have actually setup test backends by dumping my channel information and then importing it into the new backend, as I've had lots of problems with the scanner in the past (crashing, inserting bogus multiplexes, associating services with wrong multiplex ids), so it was quicker for me to create a fresh database, and then just reload my channel information, and then from within setup add the cards/inputs and associate the already defined sources/channels with them.<br>
<br>Here's my simple script which I run from cron on a weekly basis (I also dump the recordings information, but you may not want that, so I've left that out), that I've used to move the channel information to the new backend.<br>
<br>---------------------<br>#!/bin/sh<br>#<br><br>BACKUPDIR=/recordings/backup<br>DBHOST=d925<br>DBUSER=mythtv<br>DBPASS=mythtv<br>DBNAME=mythconverg_s2<br><br><br>mysqldump --no-create-db --add-drop-table -h $DBHOST -u $DBUSER -p$DBPASS $DBNAME dtv_multiplex channel | gzip -9 -c > $BACKUPDIR/channelmultiplex-`date +%Y%m%d%H%M`.gz<br>
</div></div>----------------------<br><br>I also run a script which deletes all of the backups older than 1 month, since I'm not likely to be interested in anything bu the latest backups.<br><br>Unfortunately, in the DVB world, transponders are constantly changing with new serviceids, so theres not really a way around rescanning every once in awhile.<br>
<br><br><br><br><br>