Opened 8 years ago

Closed 8 years ago

#10681 closed Bug Report - General (Invalid)

scheduler doesn't use available encoders for overlapping recordings

Reported by: chemobejk@… Owned by: gigem
Priority: minor Milestone:
Component: MythTV - Scheduling Version: 0.25-fixes
Severity: medium Keywords: scheduler multiple recordings encoders
Cc: Ticket locked: no

Description

This used to work for 0.24. I've read through http://www.mythtv.org/docs/mythtv-HOWTO-12.html, to make sure that I didn't configure anything wrong. Just to be sure that nothing went wrong during the update I have now deleted all capture cards and recreated them with mythtv-setup.

My setup:

  • 1x DVB-C card with 4 virtual recorders
  • 4x IPTV recorders (FREEBOX) pointing to the same .m3u URL
  • all my recording schedules use "any" as preferred input
  • all recordings start 60 seconds before schedule
  • all recordings end 240 seconds after schedule

Mythtv shows 8 encoders, but the scheduler uses only encoders 1 (the first DVB virtual recorder) and 5 (the first IPTV recorder).

2 example schedules shown on the page "MythTV Backend Status", that exemplify the problem:

Overlapping recordings on different channels:

  • Tue 8 May 19:30 - Encoder 5 - JIM (IPTV) - South Park (complete recording should be 19:29-19:35)
  • Tue 8 May 20:00 - Encoder 5 - SubTV (IPTV) - Rillit huurussa (complete recording should be 19:59-20:35)

Back-to-Back recordings on the same channel:

  • Tue 8 May 21:00 - Encoder 1 - MTV3 - Puumanainen (complete recording should be 20:59-21:35)
  • Tue 8 May 21:30 - Encoder 1 - MTV3 - Moderni perhe (complete recording should be 21:29-22:05)

I know that the other recorders are working, because

  • I can watch LiveTV on e.g. 6, 7 or 8 while 5 is recording
  • if I hard-code a recording schedule to use a specific input, then the scheduler will use that encoder.

I include some dumps from my database to show my configuration. Capture card configuration after re-creating it from scratch in mythtv-setup:

mysql> select cardid,videodevice,cardtype from capturecard;
+--------+-------------------------------+----------+
| cardid | videodevice                   | cardtype |
+--------+-------------------------------+----------+
|      1 | /dev/dvb/adapter0/frontend0   | DVB      |
|      2 | /dev/dvb/adapter0/frontend0   | DVB      |
|      3 | /dev/dvb/adapter0/frontend0   | DVB      |
|      4 | /dev/dvb/adapter0/frontend0   | DVB      |
|      5 | http://localhost/SSP-IPTV.m3u | FREEBOX  |
|      6 | http://localhost/SSP-IPTV.m3u | FREEBOX  |
|      7 | http://localhost/SSP-IPTV.m3u | FREEBOX  |
|      8 | http://localhost/SSP-IPTV.m3u | FREEBOX  |
+--------+-------------------------------+----------+

mysql> select * from inputgroup;
+-------------+--------------+---------------------------------+
| cardinputid | inputgroupid | inputgroupname                  |
+-------------+--------------+---------------------------------+
|           1 |            1 | DVB_/dev/dvb/adapter0/frontend0 |
|           2 |            1 | DVB_/dev/dvb/adapter0/frontend0 |
|           3 |            1 | DVB_/dev/dvb/adapter0/frontend0 |
|           4 |            1 | DVB_/dev/dvb/adapter0/frontend0 |
+-------------+--------------+---------------------------------+

mysql> select cardinputid,cardid,sourceid,inputname,recpriority,schedorder,livetvorder from cardinput;
+-------------+--------+----------+-----------+-------------+------------+-------------+
| cardinputid | cardid | sourceid | inputname | recpriority | schedorder | livetvorder |
+-------------+--------+----------+-----------+-------------+------------+-------------+
|           1 |      1 |        1 | DVBInput  |           0 |          1 |           1 |
|           2 |      2 |        1 | DVBInput  |           0 |          1 |           1 |
|           3 |      3 |        1 | DVBInput  |           0 |          1 |           1 |
|           4 |      4 |        1 | DVBInput  |           0 |          1 |           1 |
|           5 |      5 |        5 | MPEG2TS   |           0 |          5 |           5 |
|           6 |      6 |        5 | MPEG2TS   |           0 |          6 |           6 |
|           7 |      7 |        5 | MPEG2TS   |           0 |          7 |           7 |
|           8 |      8 |        5 | MPEG2TS   |           0 |          8 |           8 |
+-------------+--------+----------+-----------+-------------+------------+-------------+

Current recording schedules:

mysql> select recordid,type,chanid,prefinput from record;
+----------+------+--------+-----------+
| recordid | type | chanid | prefinput |
+----------+------+--------+-----------+
|       11 |    4 |      0 |         0 |
|       15 |    4 |   1004 |         0 |
|       41 |    4 |   1003 |         0 |
|      207 |    4 |   1003 |         0 |
|      280 |    4 |   1004 |         0 |
|      563 |    4 |   1003 |         0 |
|     1230 |    4 |   1002 |         0 |
|     1364 |    4 |   1002 |         0 |
|     1474 |    4 |      0 |         0 |
|     1477 |    4 |   1003 |         0 |
|     1557 |    4 |      0 |         0 |
|     1632 |    4 |   1001 |         0 |
|     1642 |    4 |   5103 |         0 |
|     1742 |    6 |   1003 |         0 |
|     1743 |    6 |   1006 |         0 |
|     1749 |    6 |   1001 |         0 |
|     1750 |    6 |   1009 |         0 |
+----------+------+--------+-----------+

Change History (3)

comment:1 Changed 8 years ago by gigem

Status: newinfoneeded_new

You say you have your recordings set to "start 60 seconds early" and "end 240 seconds late". I take that to mean you are using the global settings that are specified in seconds rather than the per recording rule settings that are specified in minutes. Is that correct? If so, those values are ignored when the scheduler chooses to record back-to-back programs.

There is a setting in the "Set Recording Priorities" wizard that controls whether or not the scheduler tries to avoid back-to-back programs. Did you change that setting when you upgraded to version 0.25? I just tested and the behavior in 0.25 is as intended and, as far as I can tell, is the same as it was in version 0.24.

comment:2 in reply to:  1 Changed 8 years ago by chemobejk@…

Replying to gigem:

You say you have your recordings set to "start 60 seconds early" and "end 240 seconds late". I take that to mean you are using the global settings that are specified in seconds rather than the per recording rule settings that are specified in minutes. Is that correct? If so, those values are ignored when the scheduler chooses to record back-to-back programs.

Yes, I refer to the settings on "Setup" -> "TV Settings" -> "General" -> "General (Advanced)":

  • Time to record before start of show (secs): 60
  • Time to record past end of show (secs): 240

There is a setting in the "Set Recording Priorities" wizard that controls whether or not the scheduler tries to avoid back-to-back programs. Did you change that setting when you upgraded to version 0.25? I just tested and the behavior in 0.25 is as intended and, as far as I can tell, is the same as it was in version 0.24.

"Setup" -> "TV Settings" -> "Recording Priorities" -> "Set Recording Priorities" -> "Scheduler Options"

  • Avoid back to back recordings: Never

AFAIR I never changed this option. From searching the Internet I'm gathering that this was a checkbox in 0.24, which must obviously have been set to "checked" on my setup. I've now changed it to "Always" and the scheduling looks correct, i.e. the scheduler now uses multiple encoders. I'll monitor what happens when the recordings are done.

IMHO this is extremely counter-intuitive, especially given the fact that this option is nowhere documented and not mentioned in http://www.mythtv.org/docs/mythtv-HOWTO-12.html.

Shouldn't the default be "Always"?

comment:3 Changed 8 years ago by gigem

Resolution: Invalid
Status: infoneeded_newclosed
Note: See TracTickets for help on using tickets.