LinHES Forums http://forums.linhes.org/ |
|
Upgrade to R5.5 from R5F27 Database schema issue http://forums.linhes.org/viewtopic.php?f=1&t=19649 |
Page 1 of 1 |
Author: | cullenp [ Wed Mar 04, 2009 2:37 pm ] |
Post subject: | Upgrade to R5.5 from R5F27 Database schema issue |
Had a frightful weekend trying to install R6 preview from R5F27. Backed off to R5.5 but ran into trouble with the database schema upgrade from R5F27 to R5.5 Here is the error and how I fixed it: error after upgrade: Code: Query was: ALTER TABLE recordedmarkup MODIFY mark MEDIUMINT UNSIGNED NOT NULL DEFAULT 0, MODIFY type TINYINT NO T NULL DEFAULT 0; Error was: Driver error was [2/1062]: QMYSQL3: Unable to execute query Database error was: Duplicate entry '1121-2008-07-02 20:00:00-5-16777215' for key 1 I found some help in the Mythtv user guide documents installed on the local system, but they were some changes that needed to be made for my situation and for the commands to have the correct syntax. Importing SQL from old DB mythtv-doc/mythtv-HOWTO.html#toc23.7 Solution: Do the following as root when there are no scheduled recordings. commercial flaging, transcodes, or playback going on. Find the mythconverg.sql.gz backup file before the upgrade. Where <#> is the version of backup file. Make a copy. Code: $ cp mythconverg.sql.gz.<#> mythconverg.sql.gz.<#>.copy uncompress the mythconverg.sql.gz.<#> Code: $ gunzip mythconverg.sql.gz.# From the mythconverg.sql, import the following records into a transition file restore.sql. Code: $ grep "INSERT INTO \`record\` " mythtvconverg.sql > restore.sql $ grep "INSERT INTO \`recorded\` " mythtvconverg.sql >> restore.sql $ grep "INSERT INTO \`oldrecorded\` " mythtvconverg.sql >> restore.sql $ grep "INSERT INTO \`recordedprogram\` " mythtvconverg.sql >> restore.sql $ grep "INSERT INTO \`recordedrating\` " mythtvconverg.sql >> restore.sql $ grep "INSERT INTO \`recordedseek\` " mythtvconverg.sql >> restore.sql Run Backup Knoppmyth from the Frontend to save the DB state. Stop the Front and Backend Import restore.sql into current mythconverg database(run as root) Code: $ mysql -u mythtv -p mythconverg < restore.sql
Password: mythtv Restart the Backend Check for errors in: /var/log/mythtv/mythbackend.log Restart the Frontend Check to see recordings are available in the Frontend interface When you are satisfied that the restore went well, do another KnoppMyth backup from the Frontend |
Page 1 of 1 | All times are UTC - 6 hours |
Powered by phpBB® Forum Software © phpBB Group http://www.phpbb.com/ |