Difference between revisions of "Mythfilldatabase"
(Removed offset from example) |
Steveadeff (talk | contribs) |
||
(27 intermediate revisions by 11 users not shown) | |||
Line 1: | Line 1: | ||
− | |||
{{Wrongtitle|mythfilldatabase}} | {{Wrongtitle|mythfilldatabase}} | ||
+ | |||
'''mythfilldatabase''' fills the Myth database [[program table]] with upcoming shows. | '''mythfilldatabase''' fills the Myth database [[program table]] with upcoming shows. | ||
= Automatic use of mythfilldatabase = | = Automatic use of mythfilldatabase = | ||
− | Normally mythfilldatabase is run automatically by [[mythbackend]] every 24 hours | + | Normally mythfilldatabase is run automatically by [[mythbackend]] every 24 hours and needs no additional configuration. For most people allowing mythfilldatabase to run automatically will be sufficient, however in areas with no XMLTV grabber or an unusual channel setup it may be run manually. |
= Manual use of mythfilldatabase = | = Manual use of mythfilldatabase = | ||
+ | To run an extra time out of sequence (for example, because your subscription had run out, and you just renewed it), use no command line options: | ||
+ | mythfilldatabase | ||
== Command line options == | == Command line options == | ||
− | - | + | <pre> |
− | : | + | ~$ mythfilldatabase -h |
− | + | mythfilldatabase version: fixes/0.27 [v0.27-159-g9bf1070] www.mythtv.org | |
− | -- | + | Misc. Options: |
− | + | --dd-file Bypass grabber, and read SD data from file | |
− | + | --lineupid DataDirect lineup of input xml file | |
− | + | --offset Day offset of input xml file | |
− | + | --xmlfile XML file to import manually | |
− | + | --dd-grab-all refresh full data using DataDirect | |
− | -- | + | --file Bypass grabbers and define sourceid and file |
− | + | --xmlfile XML file to import manually | |
− | + | --manual Run interactive configuration | |
− | + | --no-mark-repeats do not mark repeats | |
− | + | --preset Use channel preset values instead of numbers | |
− | + | -h OR --help OR --usage Display this help printout, or give detailed | |
− | --file | + | information of selected option. |
− | + | --version Display version information. | |
− | + | --sourceid Operate on single source | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | -- | ||
− | |||
− | |||
− | --do- | ||
− | |||
− | |||
− | -- | ||
− | |||
− | |||
− | -- | ||
− | |||
− | -- | + | Channel List Handling Options: |
− | + | --do-channel-updates update channels using datadirect | |
+ | --do-not-filter-new-channels don't filter ATSC channels for addition | ||
+ | --only-update-channels only update channel lineup | ||
+ | --remove-new-channels disable new channels on datadirect web interface | ||
− | --max-days | + | Filtering Options: |
− | + | --dont-refresh-tba don't refresh "To be announced" programs | |
+ | --max-days force number of days to update | ||
+ | --refresh Provide a day or range of days to refresh. Can | ||
+ | be used repeatedly. | ||
− | -- | + | Logging Options: |
− | : | + | --enable-dblog Enable logging to database. |
+ | --loglevel Set the logging level. All log messages at | ||
+ | lower levels will be discarded. | ||
+ | In descending order: emerg, alert, crit, err, | ||
+ | warning, notice, info, debug | ||
+ | defaults to info | ||
+ | --logpath Writes logging messages to a file in the | ||
+ | directory logpath with filenames in the format: | ||
+ | applicationName.date.pid.log. | ||
+ | This is typically used in combination with | ||
+ | --daemon, and if used in combination with | ||
+ | --pidfile, this can be used with log rotators, | ||
+ | using the HUP call to inform MythTV to reload | ||
+ | the file | ||
+ | --nologserver Disable all logging but console. | ||
+ | -q OR --quiet Don't log to the console (-q). Don't log | ||
+ | anywhere (-q -q) | ||
+ | --syslog Set the syslog logging facility. | ||
+ | Set to "none" to disable, defaults to none. | ||
+ | -v OR --verbose Specify log filtering. Use '-v help' for level | ||
+ | info. | ||
− | + | Guide Data Handling Options: | |
− | + | --only-update-guide Only update guide data | |
− | -- | + | </pre> |
− | |||
− | - | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
== External XMLTV == | == External XMLTV == | ||
− | If you are | + | {{note_box|The following steps are '''only required''' if you are using a grabber which does not comply to the baseline specification- i.e. It is '''not xmltv compliant'''. If possible inform the grabber author that their script does not comply with the standard so that they may fix it.}} |
+ | If you are using a non-compliant XMLTV grabber where mythfilldatabase will not automatically work in the normal way you will need to use the --file flag. | ||
− | === | + | === Obtain xml file of tv guide === |
Here in Belgium, I use [http://pytvgrab.sourceforge.net pytvgrab] to get my tv guide and output to an xml file: | Here in Belgium, I use [http://pytvgrab.sourceforge.net pytvgrab] to get my tv guide and output to an xml file: | ||
Line 103: | Line 82: | ||
</nowiki></pre> | </nowiki></pre> | ||
− | === | + | === Find out the source id of your card === |
This is normally '1' if you have only one input card, but it is best to check it out because I have found if I have run mythtv setup more than once it can end up being something other than 1. To check, you need to look at the database: | This is normally '1' if you have only one input card, but it is best to check it out because I have found if I have run mythtv setup more than once it can end up being something other than 1. To check, you need to look at the database: | ||
Line 118: | Line 97: | ||
Remember the source id | Remember the source id | ||
− | + | You can find another set of instruction on [[XMLTV_CH#Find_input_sourceid|how to find the sourceid here]]. | |
− | + | You may need to do multiple runs, e.g. one run with --sourceid 1, and then second run with --sourceid 2. | |
− | + | === Run mythfilldatabase with the --file flag === | |
− | The | + | The --file argument allows to directly import XMLTV files. This is useful if you are using programs like [http://nxtvepg.sourceforge.net/ nxtvepg] to grab your EPG data. |
− | < | + | |
− | + | Note that Schedules Direct members should not use the <code>--file</code> argument with mythfilldatabase. They should instead use --dd-file with data obtained by running <code>tv_grab_na_dd</code> using the <code>--dd-data</code> argument. | |
− | </ | ||
'''From 0.21 on:''' | '''From 0.21 on:''' | ||
Line 136: | Line 114: | ||
</nowiki></pre> | </nowiki></pre> | ||
− | + | '''From 0.25 on:''' | |
− | + | From version 0.25, the arguments of this command changed: | |
− | + | <pre><nowiki> | |
− | + | $ mythfilldatabase --file --sourceid <sourceid> --xmlfile belgium.xml | |
− | + | </nowiki></pre> | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | + | The first time you will need to use the --manual flag, but this is better explained on the [[XMLTV]] page. | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | + | = Troubleshooting = | |
− | |||
− | === | + | === mythfilldatabase causes the system to hang=== |
This is probably an I/O saturation issue. mythfilldatabase and [[MySQL]] can cause hard disk or ATA bus saturation, causing [[Mythbackend]] to starve. Read more about [[Troubleshooting:Mythfilldatabase_IO_bottleneck]]. | This is probably an I/O saturation issue. mythfilldatabase and [[MySQL]] can cause hard disk or ATA bus saturation, causing [[Mythbackend]] to starve. Read more about [[Troubleshooting:Mythfilldatabase_IO_bottleneck]]. | ||
− | |||
− | + | [[Category:MythTV_Software]] | |
− |
Revision as of 14:13, 16 April 2014
Note: The correct title of this article is mythfilldatabase. It appears incorrectly here due to technical restrictions.
mythfilldatabase fills the Myth database program table with upcoming shows.
Automatic use of mythfilldatabase
Normally mythfilldatabase is run automatically by mythbackend every 24 hours and needs no additional configuration. For most people allowing mythfilldatabase to run automatically will be sufficient, however in areas with no XMLTV grabber or an unusual channel setup it may be run manually.
Manual use of mythfilldatabase
To run an extra time out of sequence (for example, because your subscription had run out, and you just renewed it), use no command line options:
mythfilldatabase
Command line options
~$ mythfilldatabase -h mythfilldatabase version: fixes/0.27 [v0.27-159-g9bf1070] www.mythtv.org Misc. Options: --dd-file Bypass grabber, and read SD data from file --lineupid DataDirect lineup of input xml file --offset Day offset of input xml file --xmlfile XML file to import manually --dd-grab-all refresh full data using DataDirect --file Bypass grabbers and define sourceid and file --xmlfile XML file to import manually --manual Run interactive configuration --no-mark-repeats do not mark repeats --preset Use channel preset values instead of numbers -h OR --help OR --usage Display this help printout, or give detailed information of selected option. --version Display version information. --sourceid Operate on single source Channel List Handling Options: --do-channel-updates update channels using datadirect --do-not-filter-new-channels don't filter ATSC channels for addition --only-update-channels only update channel lineup --remove-new-channels disable new channels on datadirect web interface Filtering Options: --dont-refresh-tba don't refresh "To be announced" programs --max-days force number of days to update --refresh Provide a day or range of days to refresh. Can be used repeatedly. Logging Options: --enable-dblog Enable logging to database. --loglevel Set the logging level. All log messages at lower levels will be discarded. In descending order: emerg, alert, crit, err, warning, notice, info, debug defaults to info --logpath Writes logging messages to a file in the directory logpath with filenames in the format: applicationName.date.pid.log. This is typically used in combination with --daemon, and if used in combination with --pidfile, this can be used with log rotators, using the HUP call to inform MythTV to reload the file --nologserver Disable all logging but console. -q OR --quiet Don't log to the console (-q). Don't log anywhere (-q -q) --syslog Set the syslog logging facility. Set to "none" to disable, defaults to none. -v OR --verbose Specify log filtering. Use '-v help' for level info. Guide Data Handling Options: --only-update-guide Only update guide data
External XMLTV
Note: The following steps are only required if you are using a grabber which does not comply to the baseline specification- i.e. It is not xmltv compliant. If possible inform the grabber author that their script does not comply with the standard so that they may fix it.
If you are using a non-compliant XMLTV grabber where mythfilldatabase will not automatically work in the normal way you will need to use the --file flag.
Obtain xml file of tv guide
Here in Belgium, I use pytvgrab to get my tv guide and output to an xml file:
$ tv_grab_be_tvb --configure (you only need this the first time) $ tv_grab_be_tvb -o belgium.xml
Find out the source id of your card
This is normally '1' if you have only one input card, but it is best to check it out because I have found if I have run mythtv setup more than once it can end up being something other than 1. To check, you need to look at the database:
$ mysql -u root mythconverg mysql> select * from cardinput\G cardinputid cardid sourceid=4 etc.
Remember the source id
You can find another set of instruction on how to find the sourceid here.
You may need to do multiple runs, e.g. one run with --sourceid 1, and then second run with --sourceid 2.
Run mythfilldatabase with the --file flag
The --file argument allows to directly import XMLTV files. This is useful if you are using programs like nxtvepg to grab your EPG data.
Note that Schedules Direct members should not use the --file
argument with mythfilldatabase. They should instead use --dd-file with data obtained by running tv_grab_na_dd
using the --dd-data
argument.
From 0.21 on:
From version 0.21 on the arguments of this command changed. The offset argument has been removed and the command changed to:
$ mythfilldatabase --file <sourceid> belgium.xml
From 0.25 on:
From version 0.25, the arguments of this command changed:
$ mythfilldatabase --file --sourceid <sourceid> --xmlfile belgium.xml
The first time you will need to use the --manual flag, but this is better explained on the XMLTV page.
Troubleshooting
mythfilldatabase causes the system to hang
This is probably an I/O saturation issue. mythfilldatabase and MySQL can cause hard disk or ATA bus saturation, causing Mythbackend to starve. Read more about Troubleshooting:Mythfilldatabase_IO_bottleneck.