[mythtv-users] Lesson Learned from my Upgrade from Jaunty To Karmic...
Michael T. Dean
mtdean at thirdcontact.com
Sun Nov 22 02:45:40 UTC 2009
On 11/21/2009 09:30 PM, David Herman wrote:
> I was running Jaunty with trunk for ever (really, forever -- at least
> as long as Jaunty was out).
> When I upgraded, I did the old, back up the database, reformat the
> hard drive and install path.
>
> An interesting thing happened... For some obscene reason, my
> mythconverg database chose to be case sensitve.
That means your database schema is broken. MythTV /never/ had any
case-sensitive columns in the database schema until 0.22. Now, in 0.22,
there are a few columns that are case sensitive, and they're very
unimportant columns. (And, definitely not any of the columns in the
settings table.)
> One may wonder what the big deal is, but all over the myth code,
> people were not consistant in DBSchemaVer (as well as other settiings)..
Uh, where? I can almost guarantee that for DBSchemaVer there's /never/
any place that capitalizes it incorrectly. I'm 99% positive that's true
of all other settings, too.
> So everytime I would bring up a frontend, it went and tried to
> upgrade, but since it could not find the version, it flipped out and
> started hacking away at my data. I ultimately did a PARTIAL recover
> and that seemed to fix things (of course, I had to drop the database
> first, rerun mythtv-setup, re-add my tuners, channels, etc...). I
> still do not understand what happened to change the behavior of Mysql
> during this process
The partial restore (done properly, as documented at
http://www.mythtv.org/wiki/Database_Backup_and_Restore#Partial_restore_of_a_backup
), would have fixed a broken schema. If your database is still case
sensitive, you have bigger issues (i.e. broken MySQL--such as a MySQL
without the utf8_general_ci collation installed--meaning MythTV will
/not/ work properly). You need to fix that now or you will be
corrupting data.
> I am not trying to throw stones, so please don't take offense. I
> realize people are spending time away from loved ones when they donate
> their time to this project. I think this project is by far one of the
> best collaborative efforts I have been a user of.
>
> I propose two things. 1) Don't mix case in any setting in the settings
> table.
We don't. If there are some cases where settings names aren't properly
capitalized, they're typos that should be fixed, but it won't have any
negative effects since they're all using utf8_general_ci collation.
If you'd like to point out some typos, I'll fix them. Otherwise, I'll
find them in my settings review that I'll be doing in a month or so.
> 2) An effort be made to change every reference in code to lowercase
> values for items in the settings table.
No real need since they're not case-sensitive... And, IMHO, DBSchemaVer
is /much/ easier to read (and fits with the MythTV coding policies, so
shouldn't be hard for a Myth coder to remember) than dbschemaver or
nopromptonexit or whatever.
But you do need to fix whatever's wrong with your database. Broken
schema or broken server/installation.
Mike
More information about the mythtv-users
mailing list