View unanswered posts    View active topics

All times are UTC - 6 hours





Post new topic Reply to topic  [ 4 posts ] 
Print view Previous topic   Next topic  
Author Message
Search for:
PostPosted: Sat Apr 19, 2008 6:55 pm 
Offline
Joined: Fri Apr 02, 2004 10:08 am
Posts: 1637
Location: Virginia, USA
I'm having a couple of problems that I think are database related. Here's the more straightforward of the two.

I can run mythfilldatabase just fine; I don't see any obvious errors when it runs. However, my MythWeb status page says:

Code:
Last mythfilldatabase run started on and ended on .
Suggested next mythfilldatabase run: 1970-01-01 00:00.
There's guide data until 2008-05-03 06:00 (14 days).


Note lack of started on and ended on times and the next run year of 1970.

MythTV wiki says there should be fields in the Settings table called mythfilldatabaseLastRunStart, mythfilldatabaseLastRunEnd, and mythfilldatabaseLastRunStatus. I don't see any of those fields (using Webmin), let alone values there, which would certainly explain my status page.

Should those fields be there? Do you have those fields? And if they should be there, since I don't have them, what can I do to repair the database structure? Is it easier to just do a reinstall than try to repair manually?

Thank you in advance for any help for a very nagging problem.


Top
 Profile  
 
 Post subject:
PostPosted: Sat Apr 19, 2008 8:12 pm 
Offline
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location: Arlington, MA
Yes.
Code:
root@black2:~# ~/scripts/misc/fix_settings.sh -d | grep mythfilldatabase
mythfilldatabase.urlmap.dni_zap2it      http://images.zap2it.com/station_logo   NULL
mythfilldatabaseLastRunEnd      2008-04-19 06:20        NULL
mythfilldatabaseLastRunStart    2008-04-19 06:20        NULL
mythfilldatabaseLastRunStatus   Successful.     NULL

The fix_settings.sh script is a new utility which allows you to easily query and update the mythconverg settings table from the command line. You can get it here: http://www.knoppmythwiki.org/index.php?binary=internal%3A%2F%2Faf43c6b75dbf876a763069c369e1da22.bin

Use "fix_settings.sh -h" to see the available options.


Top
 Profile  
 
 Post subject:
PostPosted: Sun Apr 20, 2008 5:29 am 
Offline
Joined: Fri Apr 02, 2004 10:08 am
Posts: 1637
Location: Virginia, USA
The script confirms that I don't have the appropriate fields.

1. As far as I can tell, the script won't let me ADD IN the appropriate fields, correct? I only see an option for removing an entry.

2. I suspect I'm missing other fields I don't know about. Is there any way to confirm if the appropriate fields are there and repair the database manually?

3. If there's no easy way to fix things manually, I'm guessing an KnoppMyth auto-upgrade might do so. Do I have to worry about backing up and restoring my current incomplete database?


Top
 Profile  
 
 Post subject:
PostPosted: Sun Apr 20, 2008 7:18 am 
Offline
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location: Arlington, MA
1) Letting you update or add things easily was the very first thing it did. Dumping the values was a convenience that only came later. The usage message and examples show you how:
Quote:
root@black2:/usr/local/share/knoppmyth# ~/scripts/misc/fix_settings.sh -h

Usage: /root/scripts/misc/fix_settings.sh [-h|-l|-d] [-m HOSTNAME]

Or: /root/scripts/misc/fix_settings.sh [-m HOSTNAME] setting_name setting_data

Or: /root/scripts/misc/fix_settings.sh [-m HOSTNAME] -r setting_name

-h - Print this help/usage message and quit
-l - List the settings names
-d - Dump the current contents of the settings table
-m - Set the hostname to modify settings for
-r - Remove an entry from the settings table

Some examples:

/root/scripts/misc/fix_settings.sh -d -m black2

/root/scripts/misc/fix_settings.sh ThemePainter qt

/root/scripts/misc/fix_settings.sh UseChromaKeyOSD on

You can use the -m option if the settings need to be machine specific, but these aren't. Using my earlier values:
Code:
fix_settings.sh mythfilldatabaseLastRunEnd '2008-04-19 06:20'
fix_settings.sh mythfilldatabaseLastRunStart '2008-04-19 06:20'
fix_settings.sh mythfilldatabaseLastRunStatus 'Successful.'


2) Possibly. Use the -l option and compare it against the settings in "/usr/local/share/knoppmyth/KnoppMyth.sql". You can use the insert statements from that to add back anything that is missing.

3) Auto Upgrade involves restoring from a backup of your database which means you would get back the same incomplete state. There are tricks for doing partial restores but that's more complicated than extracting the appropriate insert statements from KnoppMyth.sql and piping them into mysql. If you search for "mysql" "mythconverg" and "KnoppMyth.sql" you should find example commands.


Top
 Profile  
 

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 


All times are UTC - 6 hours




Who is online

Users browsing this forum: No registered users and 102 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group

Theme Created By ceyhansuyu