Project

General

Profile

TVHeadEnd Raspberry/Synology & m3u

Added by TDA TDA about 6 years ago

Hello Everyone,
First of all great job with the program itself!
I apologize from the beginning for being such a n00b with tvheadend.
I'm trying to configure a m3u list (which contains about ~4000channels) over a RASPBERRY PI 2 with TVHEADEND and over a SYNOLOGY&TVHEADEND.
My problem is that when I add the .m3u list, tvheadend can fetch all the muxes, but about 50 services.
I've tried to add it in two different ways.
- .m3u as it is: Result muxes 4000 services 50
- .m3u modified to use ffmpeg (pipe:///usr/bin/ffmpeg -loglevel quiet -I http://xxxx -c copy -flags +global_header -strict -2 -f mpegts pipe:1
Result: muxes 4000 - services 0

I have also tried with another m3u list found on the internet.
With this one, my result are a little bit different (all streams are .ts):
- .m3u as it is: Result Muxes 466 services 280
- .m3u modified to use ffmpeg: Result muxes 466 - services 0

What am I missing?
I would have liked to configure TVHeadEnd primary on my Synology NAS as a DockerImage (if possible).
But since I can't get it work with the .pkg installed directly on Synology I don't know what to do.

What I'm doing wrong?

Thanks in advice :)


Replies (5)

RE: TVHeadEnd Raspberry/Synology & m3u - Added by TDA TDA about 6 years ago

I will try.
But something must also be wrong with the ffmpeg, since with the same list I have different result (with ffmpeg 0 services)
Also I've tried with a single address:
pipe:///usr/bin/ffmpeg -loglevel quiet -i http://xxxxxxxx/11075.ts -c copy -flags +global_header -strict -2 -f mpegts pipe:1
but I receive FAILED as scan result.
It's something wrong with my string? (I've also tried on a Debian vm with ffmpeg installed, but same behavoir)

RE: TVHeadEnd Raspberry/Synology & m3u - Added by Hiro Protagonist about 6 years ago

Some services don't work if you don't have a valid user-agent set. You could try adding this to your ffmpeg parameters:

-headers User-Agent:\ <useragent string>\r\n

Replace <useragent string> with the user agent info of your choice [google for options]. Remember to escape spaces and stuff like ( or ) with \.
Try out your ffmpeg parameters on the commandline before putting them in the .m3u

RE: TVHeadEnd Raspberry/Synology & m3u - Added by TDA TDA about 6 years ago

Hello Hiro,
An User agent???
Also it's my command for the pipe correct? (because it's a little odd, that I see 0 services when I use the m3u with the pipe; and about 50 when I use the normal m3u)

RE: TVHeadEnd Raspberry/Synology & m3u - Added by Hiro Protagonist about 6 years ago

It's a bit hard for me to tell if your pipe is correct - it depends on what's required. Here's one of mine as an example:

pipe:///usr/bin/ffmpeg -loglevel fatal -headers User-Agent:\ okhttp/3.4.1 -i http://url-details.ts -map 0 -c copy -f mpegts pipe:1

You can test the input side of your ffmpeg parameters on the commandline, so for the above I'd enter:

ffmpeg -headers User-Agent:' okhttp/3.4.1' -i http://url-details.ts

Note that I've removed the -loglevel fatal [otherwise ffmpeg will give no output] and I've put the user agent string in single quotes and removed the escaping.

On the commandline this gives a bunch of blurb which can be ignored followed by:

Input #0, mpegts, from 'http://url-details.ts':
Duration: N/A, start: 5940.002578, bitrate: N/A
Program 1
Metadata:
service_name : Service01
service_provider: FFmpeg
Stream #0:0[0x100]: Audio: aac (LC) ([15][0][0][0] / 0x000F), 44100 Hz, stereo, fltp, 192 kb/s
Stream #0:1[0x101]: Video: mpeg2video (Main) ([2][0][0][0] / 0x0002), yuv420p(tv, top first), 720x576 [SAR 64:45 DAR 16:9], 25 fps, 25 tbr, 90k tbn, 50 tbc
At least one output file must be specified

This tells me that I'm pointing at a valid URL & it's happy with the headers I've provided. If I leave out the user-agent, it tells me:

http://url-details.ts: Server returned 403 Forbidden (access denied)

    (1-5/5)