[mythtvnz] Corrupt database?

Paulgir paulgir at gmail.com
Wed Jan 23 08:59:21 GMT 2013


On Wed, 23 Jan 2013 20:48:29 +1300, Nick Rout <nick.rout at gmail.com> wrote:

>
>
> On Wed, Jan 23, 2013 at 8:35 PM, Paulgir <paulgir at gmail.com> wrote:
>>
>> When I checked Mythtv (Mythbuntu)today I found it showing a language  
>> set up window that I had not seen before.I closed >>this window and was  
>> on the xfce desktop,I tried to start Myth frontend or mythbackend setup  
>> it reverts to the language >>set-up window.
>> I tried to do a database restore but I get this message:
>>
>
> What makes you think there is a database problem. Check systematically  
> that:
>
> 1. mysql is running on the backend
> 2. mythbackend ditto
> 3. you have network connectivity to the backend.
> 4. whether there are any crashed database tables that need repair. HINT  
> if you are on mythbuntu run /etc/cron.weekly/mythtv->database
> 5. whether your ~/.mythtv/mysql.txt and ~/.mythtv/config.xml files have  
> the right info.
> 6. Look, yes look, at the logging file - particularly  
> /var/log/mythtv/mythfrontend.log, or start mythfrontend from the  
> >command line and read the output.
>
>
>> Database Information:
>>         DBHostName: localhost
>>             DBPort: 3306
>>         DBUserName: mythtv
>>         DBPassword: XXX
>>             DBName: mythconverg
>>        DBSchemaVer:
>>  DBBackupDirectory: /var/lib/mythtv/db_backups
>>   DBBackupFilename: mythconverg-1299-20130122184502.sql.gz
>>      drop_database: no
>>    create_database: no
>>
>> Executables:
>>       mysql_client: mysql
>>         uncompress: gzip -d
>>
>> Miscellaneous:
>>    partial_restore: no
>>   restore_xmltvids: no
>>    change_hostname: no
>>
>> Checking database.
>>
>> Found 105 tables in the database.
>> WARNING: Database not empty.
>>
>> ERROR: Unable to do a full restore. The database contains data
>>
>>
>>
>>
>>
>> So what am I doing wrong - any suggestions?
>>
>> The reason I tried to do a db restore was because I got some error  
>> messages when I tried myth_fill_database:
>>
>>
>>
>>
>>
>>
>>
>> This version of MythTV requires an updated database. (schema is 1299  
>> versions behind)
>>
>> Please run mythtv-setup or mythbackend to update your database.
>>
>> Database Host: localhost
>> Database Name: mythconverg
>>
>> 2013-01-23 19:49:17.500860 C  ERROR: Unable to acquire database upgrade  
>> lock
>> 2013-01-23 19:49:17.500869 C  Waiting for Database Upgrade to complete.
>> 2013-01-23 19:49:17.500880 C  Timed out waiting.
>> 2013-01-23 19:49:17.500919 E  Not allowed to upgrade the database.
>> 2013-01-23 19:49:17.502557 E  Incorrect database schema
>> 2013-01-23 19:49:17.503042 E  Error preparing query: INSERT INTO  
>> logging     (host, application, pid, tid, thread, >>filename,       
>> line, function, msgtime, level, message) VALUES (:HOST, :APP, :PID,  
>> :TID, :THREAD, :FILENAME,       >>  :LINE, :FUNCTION, :MSGTIME, :LEVEL,  
>> :MESSAGE)
>> mythfilldatabase
>>
>>
>>
>>
>> Or is this a good time to install Mythbuntu 12.04?
>>
>> _______________________________________________
>> mythtvnz mailing list
>> mythtvnz at lists.linuxnut.co.nz
>> http://lists.ourshack.com/mailman/listinfo/mythtvnz
>> Archives http://www.gossamer-threads.com/lists/mythtv/mythtvnz/
>

Thanks for the help.

I have performed a couple of the suggested procedures:

running /etc/cron.weekly/mythtv-database gives "database corrupt" and  
"file format" errors.

Starting mythfrontend from the command line give the error listed below  
among other similar messages:


2013-01-23 19:49:17.503042 E Error preparing query: INSERT INTO logging  
(host, application, pid, tid, thread, filename, line, function, msgtime,  
level, message) VALUES (:HOST, :APP, :PID, :TID, :THREAD, :FILENAME,  
:LINE, :FUNCTION, :MSGTIME, :LEVEL, :MESSAGE)
mythfilldatabase

I will have to look up how to repair crashed db tables - I assumed  
restoring a backed-up db would address that.

I might leave the rest till tomorrow.,

I was planning to upgrade the OS and mythtv,this may be the motivation to  
do that.

-Paul


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ourshack.com/pipermail/mythtvnz/attachments/20130123/d2bd3392/attachment.html>


More information about the mythtvnz mailing list