You are not logged in.
Ok, I think I've solved it (partly based on http://www.mythpvr.com/mythtv/tips/migr … dings.html ).
What I did was use mysqldump to backup all recordings/rules to a file, then drop the db, create a new one (btw: new mythtv seems to lack the mc.sql file
), and import the backup (had to use the -f flag because of duplicate entries).
It all seems to work now (but the system needs reconfiguring).
One problem though: does anyone else experience mythfrontend crashing when exiting? Or might I have damaged something?
One more problems:: lirc input in mythfrontend doesn't seem to work (stays in mythwelcome).
--- old post ---
After the recent upgrade of mythtv (0.22), it was necessary to upgrade the databse. But when running mythtv-setup, I got the following errors:
2009-11-22 14:39:50.112 Using runtime prefix = /usr
2009-11-22 14:39:50.498 Using configuration directory = /home/mythtv/.mythtv
2009-11-22 14:39:50.498 Empty LocalHostName.
2009-11-22 14:39:50.498 Using localhost value of HTPC
2009-11-22 14:39:50.501 New DB connection, total: 1
2009-11-22 14:39:50.503 Connected to database 'mythconverg' at host: localhost
2009-11-22 14:39:50.503 Closing DB connection named 'DBManager0'
2009-11-22 14:39:50.511 DPMS is disabled.
2009-11-22 14:39:50.512 Primary screen: 0.
2009-11-22 14:39:50.512 Connected to database 'mythconverg' at host: localhost
2009-11-22 14:39:50.513 Using screen 0, 1920x1080 at 0,0
2009-11-22 14:39:50.532 MythUI Image Cache size set to 20971520 bytes
2009-11-22 14:39:50.533 Primary screen: 0.
2009-11-22 14:39:50.533 Using screen 0, 1920x1080 at 0,0
2009-11-22 14:39:50.534 Using theme base resolution of 1280x720
2009-11-22 14:39:50.538 LIRC: Successfully initialized '/dev/lircd' using '/home/mythtv/.mythtv/lircrc' config
2009-11-22 14:39:50.538 JoystickMenuThread Error: Joystick disabled - Failed to read /home/mythtv/.mythtv/joystickmenurc
2009-11-22 14:39:50.550 Using the OpenGL painter
2009-11-22 14:39:50.702 Loaded base theme from /usr/share/mythtv/themes/Terra/base.xml
2009-11-22 14:39:50.724 Loaded base theme from /usr/share/mythtv/themes/default-wide/base.xml
2009-11-22 14:39:50.728 Loaded base theme from /usr/share/mythtv/themes/default/base.xml
2009-11-22 14:39:50.731 Current MythTV Schema Version (DBSchemaVer): 1216
2009-11-22 14:39:50.731 MythTV database schema is old. Waiting to see if DB is being upgraded.
2009-11-22 14:39:51.731 New DB connection, total: 2
2009-11-22 14:39:51.731 Connected to database 'mythconverg' at host: localhost
2009-11-22 14:39:51.732 Current MythTV Schema Version (DBSchemaVer): 1216
2009-11-22 14:39:52.734 Current MythTV Schema Version (DBSchemaVer): 1216
2009-11-22 14:39:53.735 Current MythTV Schema Version (DBSchemaVer): 1216
2009-11-22 14:39:54.736 Current MythTV Schema Version (DBSchemaVer): 1216
2009-11-22 14:39:55.738 Current MythTV Schema Version (DBSchemaVer): 1216
2009-11-22 14:39:55.738 Timed out waiting.
2009-11-22 14:39:55.741 Backing up database with script: '/usr/share/mythtv/mythconverg_backup.pl'
2009-11-22 14:39:58.415 Database Backup complete.
2009-11-22 14:39:58.415 Backed up database to file: '/mythmedia/database/mythconverg-1216-20091122143955.sql.gz'
2009-11-22 14:40:01.288 Newest MythTV Schema Version : 1244
2009-11-22 14:40:01.290 Upgrading to MythTV schema version 1217
2009-11-22 14:40:02.461 DB Error (Performing database upgrade):
Query was: ALTER TABLE keybindings DEFAULT CHARACTER SET default, MODIFY context varchar(32) CHARACTER SET utf8 NOT NULL default '', MODIFY action varchar(32) CHARACTER SET utf8 NOT NULL default '', MODIFY description varchar(255) CHARACTER SET utf8 default NULL, MODIFY keylist varchar(128) CHARACTER SET utf8 default NULL, MODIFY hostname varchar(64) CHARACTER SET utf8 NOT NULL default '';
Error was: Driver error was [2/1062]:
QMYSQL3: Unable to execute statement
Database error was:
Duplicate entry 'Global-UP-HTPC' for key 'PRIMARY'
new version: 1217
2009-11-22 14:40:02.461 DB charset conversions update failed! Your database seems to be partially corrupted. Please move the backup to a safe place. Your database must be fixed before you can upgrade beyond 0.21-fixes. Please see http://www.mythtv.org/wiki/Fixing_Corrupt_Database_Encoding for information.
2009-11-22 14:40:02.461 Database Schema upgrade FAILED, unlocking.
2009-11-22 14:40:02.461 Couldn't upgrade database to new schema.The interesting things are the last lines.
So it seems I'm having a partially corrupted database?
I've been trying to read the page about "fixing corrupt database", but I'm not sure what to do...
Since Mythtv points out that the database is partially corrupt, it all gets more complicated? And since I first tried querying the "status" from mysql ("Determining if your database is misconfigured ") after the upgrade, will not usable for detecting if th database is properly configured? But the wiki does point out that "db charset" should be utf8 if correct, but the status output from mysql doesn't even write anything about "db charset"... ![]()
This ends up with several questions: Did anyone else have this problem when upgrading? Is the database corrupted? equally or partially?
Would it be possible to simply backup all recordings data from the old database, drop the database, create a new one, configure everything (tv cards, etc...) and then restore the db backup of recordings? Since that seems like an easy way around all this..?
Thanks.
Update: Ok, this just keeps on getting worse. I tried downgrading mythtv to the earlier version, and it complained about the detabase/schedule being to new. So I restored one of the automatic backups (which got created when I tried upgrading), but it still complains. In other words, it seems I can go back to the old version either. O_o
Last edited by 1311219 (2009-11-23 17:25:07)
Offline