Tvheadend 4.1 closes iptv request while scanning
Added by Jelle De Loecker about 9 years ago
I'm using Jalle19's script to convert external videos to a stream tvheadend understands.
The code can be found here, btw: https://github.com/Jalle19/node-ffmpeg-mpegts-proxy
I then add a mux to my IPTV network, like this:
URL: http://localhost:3048/vtm
MUX Name: VTM
Service Name: VTM
Then I see it makes a request to that URL:
2015-09-03 16:06:41.591 [ DEBUG]:mpegts: Selectsat - adding mux VTM in Selectsat to scan queue weight 6 flags 4000 2015-09-03 16:06:41.591 [ DEBUG]:settings: saving to /home/barabas/tvh4/input/iptv/networks/954bfbb438b81253b255af5668eaa3d9/muxes/0389598825493ce8c684b468af1b7c22/config 2015-09-03 16:06:41.592 [ DEBUG]:mpegts: VTM in Selectsat - add raw service 2015-09-03 16:06:41.592 [ DEBUG]:service: 1: VTM in Selectsat si 0xbc2210 <unknown> weight 0 prio 1 error 0 2015-09-03 16:06:41.592 [ INFO]:mpegts: VTM in Selectsat - tuning on IPTV 2015-09-03 16:06:41.592 [ DEBUG]:mpegts: VTM in Selectsat - started 2015-09-03 16:06:41.592 [ DEBUG]:mpegts: VTM in Selectsat - open PID 0039 (57) [16/0xdda090] 2015-09-03 16:06:41.592 [ DEBUG]:mpegts: VTM in Selectsat - open PID 0BBA (3002) [16/0xe2c060] 2015-09-03 16:06:41.592 [ DEBUG]:mpegts: VTM in Selectsat - open PID 0BBB (3003) [16/0xe2d4d0] 2015-09-03 16:06:41.593 [ DEBUG]:mpegts: VTM in Selectsat - open PID 0012 (18) [20/0xe2e940] 2015-09-03 16:06:41.593 [ DEBUG]:mpegts: VTM in Selectsat - open PID tables subscription [0042/0xcd44a0] 2015-09-03 16:06:41.593 [ INFO]:subscription: 000E: "scan" subscribing to mux "VTM", weight: 6, adapter: "IPTV", network: "Selectsat", service: "Raw PID Subscription"
But immediately after that it closes the request.
The node-proxy process never has any time to actually respond with the data,
which it starts to return right after the disconnect.
Even more strange: sometimes it does not close the connection and it works.
A succesful scan looks like this:
2015-09-03 16:10:38.615 [ DEBUG]:mpegts: Selectsat - adding mux Vijf in Selectsat to scan queue weight 6 flags 4000 2015-09-03 16:10:38.615 [ DEBUG]:settings: saving to /home/barabas/tvh4/input/iptv/networks/954bfbb438b81253b255af5668eaa3d9/muxes/d5dd3bd1b1ae0fcf9bb400b998df895a/config 2015-09-03 16:10:38.616 [ DEBUG]:mpegts: Vijf in Selectsat - add raw service 2015-09-03 16:10:38.616 [ DEBUG]:service: 1: Vijf in Selectsat si 0x23eb700 <unknown> weight 0 prio 1 error 0 2015-09-03 16:10:38.616 [ INFO]:mpegts: Vijf in Selectsat - tuning on IPTV 2015-09-03 16:10:38.617 [ DEBUG]:mpegts: Vijf in Selectsat - started 2015-09-03 16:10:38.617 [ DEBUG]:mpegts: Vijf in Selectsat - open PID 0039 (57) [16/0x25f8c80] 2015-09-03 16:10:38.617 [ DEBUG]:mpegts: Vijf in Selectsat - open PID 0BBA (3002) [16/0x25fa0f0] 2015-09-03 16:10:38.617 [ DEBUG]:mpegts: Vijf in Selectsat - open PID 0BBB (3003) [16/0x25fb560] 2015-09-03 16:10:38.617 [ DEBUG]:mpegts: Vijf in Selectsat - open PID 0012 (18) [20/0x25fc9d0] 2015-09-03 16:10:38.617 [ DEBUG]:mpegts: Vijf in Selectsat - open PID tables subscription [0042/0x260d3d0] 2015-09-03 16:10:38.617 [ INFO]:subscription: 0002: "scan" subscribing to mux "Vijf", weight: 6, adapter: "IPTV", network: "Selectsat", service: "Raw PID Subscription" 2015-09-03 16:10:39.849 [ DEBUG]:mpegts: Vijf in Selectsat - open PID 0000 (0) [20/0x7f1568011b70] 2015-09-03 16:10:39.849 [ DEBUG]:mpegts: Vijf in Selectsat - open PID 0001 (1) [16/0x7f1568013140] 2015-09-03 16:10:39.849 [ DEBUG]:mpegts: Vijf in Selectsat - open PID 0010 (16) [16/0x7f1568014710] 2015-09-03 16:10:39.849 [ DEBUG]:mpegts: Vijf in Selectsat - open PID 0011 (17) [20/0x7f1568015ce0] 2015-09-03 16:10:39.849 [ DEBUG]:mpegts: Vijf in Selectsat - open PID 0011 (17) [16/0x7f15680172b0] 2015-09-03 16:10:39.849 [ DEBUG]:service: Vijf in Selectsat: Status changed to [Demuxed packets] 2015-09-03 16:10:39.849 [ DEBUG]:service: Vijf in Selectsat: Status changed to [Demuxed packets] [Reassembled packets] 2015-09-03 16:10:39.849 [ DEBUG]:sdt: onid 0001 (1) tsid 0001 (1) 2015-09-03 16:10:39.849 [ DEBUG]:sdt: mux Vijf in Selectsat 2015-09-03 16:10:39.849 [ DEBUG]:sdt: sid 0001 (1) running 4 free_ca 0 2015-09-03 16:10:39.849 [ DEBUG]:pat: tsid 0001 (1) 2015-09-03 16:10:39.849 [ DEBUG]:pat: sid 0001 (1) on pid 1000 (4096) 2015-09-03 16:10:39.849 [ DEBUG]:mpegts: Vijf in Selectsat - open PID 1000 (4096) [16/0x7f1560000b50] 2015-09-03 16:10:39.849 [ DEBUG]:pat: sid 2AB1 (10929) on pid 04B2 (1202) 2015-09-03 16:10:39.849 [ DEBUG]:mpegts: Vijf in Selectsat - open PID 04B2 (1202) [16/0x7f1560002120] 2015-09-03 16:10:39.849 [ DEBUG]:pat: completed pid 0 table 00000000 / 00000000 2015-09-03 16:10:40.041 [ DEBUG]:pmt: sid 0001 (1) 2015-09-03 16:10:40.041 [ DEBUG]:pmt: pcr_pid 0100 2015-09-03 16:10:40.041 [ DEBUG]:pmt: pid 0100 estype 27 2015-09-03 16:10:40.041 [ DEBUG]:pmt: type H264 position 0 2015-09-03 16:10:40.041 [ DEBUG]:pmt: pid 0101 estype 15 2015-09-03 16:10:40.041 [ DEBUG]:pmt: type AAC-LATM position 0 2015-09-03 16:10:40.041 [ DEBUG]:pmt: completed pid 4096 table 00000002 / 000000ff 2015-09-03 16:10:40.041 [ DEBUG]:mpegts: Vijf in Selectsat - close PID 1000 (4096) [16/0x7f1560000b50] 2015-09-03 16:10:40.315 [ DEBUG]:sdt: completed pid 17 table 00000040 / 000000f8
And no, it's not always the same channels that work.
So, does anyone know what's going on here?
Replies (1)
RE: Tvheadend 4.1 closes iptv request while scanning - Added by Jelle De Loecker about 9 years ago
Turns out, if the first chunk tvheadend received is too big, it fails.
I've configured the proxy so it'll first send a chunk that is at most 9400 bytes long. Haven't seen the problem since.