[mythtv-users] 0.20 schema upgrade failed

Michael T. Dean mtdean at thirdcontact.com
Sun Oct 8 17:36:57 UTC 2006


On 10/08/06 01:57, Peter Bienstman wrote:

>On Saturday 07 October 2006 22:59, Michael T. Dean wrote:
>  
>
>>On 10/07/06 16:23, Peter Bienstman wrote:
>>    
>>
>>>I upgraded from 0.19 to 0.20 (Actually the Gentoo 0.20_p11444 version),
>>>but when I start mythfrontend, I get this:
>>>      
>>>
>>...
>>
>>>Database error was:
>>>Table 'mythconverg.recordedprogram' doesn't exist
>>>      
>>>
>>Let me guess.  You did a partial restore of the database (
>>http://mythtv.org/docs/mythtv-HOWTO-23.html#ss23.7 ) after the upgrade
>>rather than a full restore (
>>http://mythtv.org/docs/mythtv-HOWTO-23.html#ss23.5 )?
>>
>>If that's not the case, you may have exported a corrupt database whose
>>recordedprogram table couldn't be opened (and, therefore, wasn't
>>exported).  Fortunately, recordedprogram isn't critical data (it's
>>automatically regenerated).
>>
>>After a bit more information on what constitutes "the upgrade," I can
>>give you more info on possible approaches for getting a working database.
>>    
>>
>I didn't play around with mysqldump and friends (although in hindsight I 
>should have exported my database before the upgrade).
>  
>
Yes.  That would have been good.  :)

>The upgrade was done automaticcaly by starting mythfrontend, I didn't touch 
>the database manually.
>

OK.  First step is to verify your database is not corrupt.  Please run 
optimize_mythdb.pl from the contrib directory.  If it catches some 
errors, then try to restart Myth.  If Myth starts OK and the database 
upgrade succeeds, you can try to operate with that database, but I 
wouldn't trust it and would export the data (as in ss23.5 above), then 
drop the database, run mc.sql (to create another), run mythtv-setup (to 
fill in the database) and exit, then do a partial restore (as in ss23.7 
above), then go through mythtv-setup and frontend settings to make 
everything work the way you want.

If optimize_mythdb.pl doesn't help, then you may want to do an export 
and use the instructions in ss23.7 above to extract the necessary data.  
Then, you'd need to drop your database, run mc.sql, start mythtv-setup 
and exit, then use the mysql client to describe the tables whose data 
you extracted from the backup and use find/replace to "manually upgrade" 
the tables to the new 0.20 structure.

Mike


More information about the mythtv-users mailing list