chrisbenincasa / tunarr

Create a classic TV experience using your own media - IPTV backed by Plex/Jellyfin
https://tunarr.com/
zlib License
137 stars 13 forks source link

Playback Error #833

Open Liquidbings opened 6 days ago

Liquidbings commented 6 days ago

For Some reason I cannot get ffmpeg to work correctly. Keep getting this error no matter what I change or try. Also the webviewer doesnt give this error but also just does nothing

2024-10-05T13:08:35.738Z [error]: Received error from session. Shutting down {"sessionType":"hls","channelId":"8be2d5f0-42fa-458d-86dd-6fba2c7cc321"} error: {} 2024-10-05T13:08:35.739Z [error]: Received error from session. Shutting down {"sessionType":"hls","channelId":"8be2d5f0-42fa-458d-86dd-6fba2c7cc321"} error: {} 2024-10-05T13:08:35.740Z [error]: Error playing video {"code":254,"cmd":"/usr/bin/ffmpeg -hide_banner -threads 4 -fflags +genpts+discardcorrupt+igndts -loglevel warning -readrate 1.0 -readrate_initial_burst 45 -ss 136.19 -i /TV Shows/Metalocalypse/Season 1/Metalocalypse - S01E01 - The Curse of Dethklok - [WEBRIP-1080P]-[AC3]-[2.0-Channel]-[X265]-[10Bit] -[X265].mkv -filter_complex [0:1]anull[audio];[audio]aresample=48000,aresample=async=1:first_pts=0,apad=whole_dur=555682ms[padded] -map 0:0 -c:v libx264 -b:v 10000k -maxrate:v 10000k -bufsize:v 1000k -sc_threshold 0 -video_track_timescale 90000 -map [padded] -flags cgop+ilme -b:a 192k -maxrate:a 192k -bufsize:a 50k -ac 2 -ar 48k -map_metadata -1 -movflags +faststart -muxdelay 0 -muxpreload 0 -fps_mode cfr -metadata service_provider=\"tunarr\" -metadata service_name=\"Adult Swim\" -t 555682ms -g 120 -keyint_min 120 -force_key_frames expr:gte(t,n_forced*2) -f hls -hls_time 4 -hls_list_size 0 -segment_list_flags +live -hls_flags program_date_time+omit_endlist+discont_start+append_list -hls_segment_type mpegts -hls_base_url /stream/channels/8be2d5f0-42fa-458d-86dd-6fba2c7cc321/hls/ -hls_segment_filename streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/data%05d.ts -master_pl_name master.m3u8 streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/stream.m3u8"} 2024-10-05T13:08:35.753Z [info]: Concat Wrapper FFMPEG exited. (signal=null, code=0, expected?=true) {"args":"-nostdin -threads 1 -hide_banner -loglevel warning -user_agent Ffmpeg Tunarr/0.12.3 -nostats -fflags +genpts+discardcorrupt+igndts -reconnect 1 -reconnect_at_eof 1 -readrate 1 -i http://localhost:8000/stream/channels/8be2d5f0-42fa-458d-86dd-6fba2c7cc321.m3u8?mode=hls -map 0 -c copy -f mpegts pipe:1"} 2024-10-05T13:08:37.091Z [error]: Bailing on stream start, had error! {"sessionId":"7be425b1-2455-48c4-8df9-96c15d5864d2","channel":"8be2d5f0-42fa-458d-86dd-6fba2c7cc321","sessionType":"hls"} err: { "type": "Error", "message": "Error in underlying FFMPEG process: (code=254)", "stack": Error: Error in underlying FFMPEG process: (code=254) at _FfmpegTranscodeSession. (file:///tunarr/server/build/bundle.js:271941:24) at _FfmpegTranscodeSession.emit (node:events:531:35) at _FfmpegProcess. (file:///tunarr/server/build/bundle.js:269015:12) at _FfmpegProcess.emit (node:events:531:35) at ChildProcess. (file:///tunarr/server/build/bundle.js:268953:14) at ChildProcess.emit (node:events:519:28) at ChildProcess._handle.onexit (node:internal/child_process:294:12) at Process.callbackTrampoline (node:internal/async_hooks:130:17)

chrisbenincasa commented 6 days ago

Sorry you're having trouble! Best thing to do for this type of issue is to turn on ffmpeg logging (under settings > ffmpeg). Change the log level to warning or info, try running the stream, and then paste the output here.

Liquidbings commented 6 days ago

Thank you for the quick reply. This is what I get after updating the ff log

2024-10-05T13:21:20.929Z [info]: Searching for legacy dizquetv directory at /.dizquetv 2024-10-05T13:21:21.435Z [info]: XMLTV Updated at 10/5/2024, 1:21:21 PM 2024-10-05T13:21:21.461Z [info]: HTTP server listening on host:port: http://0.0.0.0:8000 2024-10-05T13:22:27.513Z [warn]: No underlying session of type hls found for existing concat session (channel id = 8be2d5f0-42fa-458d-86dd-6fba2c7cc321). Removing dangling session and recreating 2024-10-05T13:22:27.548Z [warn]: No last segment found {"sessionId":"4778291d-37c2-461a-a2bd-12d6a02f652c","channel":"8be2d5f0-42fa-458d-86dd-6fba2c7cc321","sessionType":"hls"} [in#0 @ 0x556de8177880] Error opening input: Immediate exit requested Error opening input file http://localhost:8000/stream/channels/8be2d5f0-42fa-458d-86dd-6fba2c7cc321.m3u8?mode=hls. 2024-10-05T13:22:57.460Z [info]: Concat Wrapper FFMPEG exited. (signal=null, code=0, expected?=true) {"args":"-nostdin -threads 1 -hide_banner -loglevel warning -user_agent Ffmpeg Tunarr/0.12.3 -nostats -fflags +genpts+discardcorrupt+igndts -reconnect 1 -reconnect_at_eof 1 -readrate 1 -i http://localhost:8000/stream/channels/8be2d5f0-42fa-458d-86dd-6fba2c7cc321.m3u8?mode=hls -map 0 -c copy -f mpegts pipe:1"}

Liquidbings commented 6 days ago

I also made another channel and tried that and seems like a slightly different error but same result.

2024-10-05T13:31:39.324Z [error]: Received error from session. Shutting down {"sessionType":"hls","channelId":"c79f4dc6-fa35-4cef-afa1-237620e2b85a"} error: {} 2024-10-05T13:31:39.325Z [error]: Received error from session. Shutting down {"sessionType":"hls","channelId":"c79f4dc6-fa35-4cef-afa1-237620e2b85a"} error: {} 2024-10-05T13:31:39.326Z [error]: Error playing video {"code":8,"cmd":"/usr/bin/ffmpeg -hide_banner -threads 4 -fflags +genpts+discardcorrupt+igndts -loglevel info -reconnect 1 -reconnect_on_network_error 1 -reconnect_streamed 1 -multiple_requests 1 -readrate 1.0 -readrate_initial_burst 45 -ss 159.002 -i https://192-168-1-13.f85e63350a2d4839be9686b04402aa13.plex.direct:32400/library/parts/84129/1630852156/file.mkv?X-Plex-Token=REDACTED -filter_complex [0:1]anull[audio];[audio]aresample=48000,aresample=async=1:first_pts=0,apad=whole_dur=1160326ms[padded] -map 0:0 -c:v libx264 -b:v 10000k -maxrate:v 10000k -bufsize:v 1000k -sc_threshold 0 -video_track_timescale 90000 -map [padded] -flags cgop+ilme -b:a 192k -maxrate:a 192k -bufsize:a 50k -ac 2 -ar 48k -map_metadata -1 -movflags +faststart -muxdelay 0 -muxpreload 0 -fps_mode cfr -metadata service_provider=\"tunarr\" -metadata service_name=\"Channel 2\" -t 1160326ms -g 96 -keyint_min 96 -force_key_frames expr:gte(t,n_forced*2) -f hls -hls_time 4 -hls_list_size 0 -segment_list_flags +live -hls_flags program_date_time+omit_endlist+discont_start+append_list -hls_segment_type mpegts -hls_base_url /stream/channels/c79f4dc6-fa35-4cef-afa1-237620e2b85a/hls/ -hls_segment_filename streams/stream_c79f4dc6-fa35-4cef-afa1-237620e2b85a/data%05d.ts -master_pl_name master.m3u8 streams/stream_c79f4dc6-fa35-4cef-afa1-237620e2b85a/stream.m3u8"} [in#0 @ 0x55a427d11880] Error opening input: Immediate exit requested Error opening input file http://localhost:8000/stream/channels/c79f4dc6-fa35-4cef-afa1-237620e2b85a.m3u8?mode=hls. Exiting normally, received signal 15. 2024-10-05T13:31:39.341Z [info]: Concat Wrapper FFMPEG exited. (signal=null, code=0, expected?=true) {"args":"-nostdin -threads 1 -hide_banner -loglevel info -user_agent Ffmpeg Tunarr/0.12.3 -nostats -fflags +genpts+discardcorrupt+igndts -reconnect 1 -reconnect_at_eof 1 -readrate 1 -i http://localhost:8000/stream/channels/c79f4dc6-fa35-4cef-afa1-237620e2b85a.m3u8?mode=hls -map 0 -c copy -f mpegts pipe:1"} Input #0, png_pipe, from 'http://localhost:8000/images/generic-error-screen.png': Duration: N/A, bitrate: N/A Stream #0:0: Video: png, rgba(pc, gbr/bt709/iec61966-2-1), 1920x1080 [SAR 2835:2835 DAR 16:9], 25 fps, 25 tbr, 25 tbn [out#0/nut @ 0x55c83a35efc0] Codec AVOption sc_threshold (Scene change threshold) has not been used for any stream. The most likely reason is either wrong type (e.g. a video option with no video streams) or that it is a private option of some encoder which was not actually used for any stream. Stream mapping: Stream #0:0 (png) -> format:default realtime:default -> Stream #0:0 (rawvideo) arealtime:default -> Stream #0:1 (flac) Press [q] to stop, [?] for help [flac @ 0x55c83a362540] encoding as 24 bits-per-sample, more is considered experimental. Add -strict experimental if you want to encode more than 24 bits-per-sample Output #0, nut, to 'pipe:1': Metadata: service_provider: "tunarr" service_name : "Channel 2" encoder : Lavf61.1.100 Stream #0:0: Video: rawvideo (I420 / 0x30323449), yuv420p(unknown/bt709/iec61966-2-1, progressive), 1920x1080 [SAR 1:1 DAR 16:9], q=2-31, 597196 kb/s, 24 fps, 49152 tbn Metadata: encoder : Lavc61.3.100 rawvideo Stream #0:1: Audio: flac ([172][241][0][0] / 0xF1AC), 48000 Hz, mono, s32 (24 bit), 128 kb/s Metadata: encoder : Lavc61.3.100 flac 2024-10-05T13:31:41.347Z [error]: Bailing on stream start, had error! {"sessionId":"4778291d-37c2-461a-a2bd-12d6a02f652c","channel":"8be2d5f0-42fa-458d-86dd-6fba2c7cc321","sessionType":"hls"} err: { "type": "Error", "message": "Error in underlying FFMPEG process: (code=8)", "stack": Error: Error in underlying FFMPEG process: (code=8) at _FfmpegTranscodeSession. (file:///tunarr/server/build/bundle.js:271941:24) at _FfmpegTranscodeSession.emit (node:events:531:35) at _FfmpegProcess. (file:///tunarr/server/build/bundle.js:269015:12) at _FfmpegProcess.emit (node:events:531:35) at ChildProcess. (file:///tunarr/server/build/bundle.js:268953:14) at ChildProcess.emit (node:events:519:28) at ChildProcess._handle.onexit (node:internal/child_process:294:12) at Process.callbackTrampoline (node:internal/async_hooks:130:17) } 2024-10-05T13:31:41.349Z [error]: Error starting stream after retrying {"sessionId":"4778291d-37c2-461a-a2bd-12d6a02f652c","channel":"8be2d5f0-42fa-458d-86dd-6fba2c7cc321","sessionType":"hls"} err: { "type": "Error", "message": "Error in underlying FFMPEG process: (code=8)", "stack": Error: Error in underlying FFMPEG process: (code=8) at _FfmpegTranscodeSession. (file:///tunarr/server/build/bundle.js:271941:24) at _FfmpegTranscodeSession.emit (node:events:531:35) at _FfmpegProcess. (file:///tunarr/server/build/bundle.js:269015:12) at _FfmpegProcess.emit (node:events:531:35) at ChildProcess. (file:///tunarr/server/build/bundle.js:268953:14) at ChildProcess.emit (node:events:519:28) at ChildProcess._handle.onexit (node:internal/child_process:294:12) at Process.callbackTrampoline (node:internal/async_hooks:130:17) } 2024-10-05T13:31:41.350Z [error]: Received error from session. Shutting down {"sessionType":"hls","channelId":"c79f4dc6-fa35-4cef-afa1-237620e2b85a"} error: {} frame= 3 fps=0.0 q=-0.0 size= 0KiB time=00:00:00.28 bitrate= 12.1kbits/s speed=0.00358x

chrisbenincasa commented 6 days ago

Can you make sure you're posting the complete logs? In the 2nd comment it looks like the logs begin right after another failure.

There does seem like an issue with opening up an error stream that we pop up in the case the main ffmpeg process fails, but I think that is unrelated.

Liquidbings commented 6 days ago

Sorry about that. It was snippets as I was worried the posts would be too long. Here's the full log from starting the container and attempting to play both channels:

2024-10-05T14:08:14.962Z [info]: Searching for legacy dizquetv directory at /.dizquetv 2024-10-05T14:08:15.596Z [info]: XMLTV Updated at 10/5/2024, 2:08:15 PM 2024-10-05T14:08:15.615Z [info]: HTTP server listening on host:port: http://0.0.0.0:8000 2024-10-05T14:08:49.304Z [warn]: No underlying session of type hls found for existing concat session (channel id = 8be2d5f0-42fa-458d-86dd-6fba2c7cc321). Removing dangling session and recreating 2024-10-05T14:08:49.338Z [warn]: No last segment found {"sessionId":"c7372594-19e3-4b5c-8bec-241cbdadf950","channel":"8be2d5f0-42fa-458d-86dd-6fba2c7cc321","sessionType":"hls"} 2024-10-05T14:08:52.364Z [info]: First stretch to 1440 x 1080. Then add padding to make it 1920 x 1080 {"channel":"8be2d5f0-42fa-458d-86dd-6fba2c7cc321"} Input #0, matroska,webm, from 'https://192-168-1-13.f85e63350a2d4839be9686b04402aa13.plex.direct:32400/library/parts/58579/1659085944/file.mkv?X-Plex-Token=Redacted': Metadata: encoder : libebml v1.4.2 + libmatroska v1.6.4 Duration: 00:11:28.96, start: 0.000000, bitrate: 8612 kb/s Stream #0:0(eng): Video: h264, yuv420p(tv, bt709, progressive), 1440x1080 [SAR 1:1 DAR 4:3], 29.97 fps, 29.97 tbr, 1k tbn (default) (original) Metadata: BPS : 8226674 DURATION : 00:11:28.921000000 NUMBER_OF_FRAMES: 20647 NUMBER_OF_BYTES : 708441097 _STATISTICS_WRITING_APP: mkvmerge v66.0.0 ('Josie') 64-bit _STATISTICS_WRITING_DATE_UTC: 2022-07-28 09:21:08 _STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES Stream #0:1(eng): Audio: ac3, 48000 Hz, stereo, fltp, 384 kb/s (default) (original) Metadata: title : English BPS : 384000 DURATION : 00:11:28.960000000 NUMBER_OF_FRAMES: 21530 NUMBER_OF_BYTES : 33070080 _STATISTICS_WRITING_APP: mkvmerge v66.0.0 ('Josie') 64-bit _STATISTICS_WRITING_DATE_UTC: 2022-07-28 09:21:08 _STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES Stream #0:2(eng): Subtitle: subrip (srt) (original) Metadata: title : English BPS : 191 DURATION : 00:11:15.341000000 NUMBER_OF_FRAMES: 305 NUMBER_OF_BYTES : 16187 _STATISTICS_WRITING_APP: mkvmerge v66.0.0 ('Josie') 64-bit _STATISTICS_WRITING_DATE_UTC: 2022-07-28 09:21:08 _STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES Stream mapping: Stream #0:0 (h264) -> null:default Stream #0:1 (ac3) -> anull:default format:default -> Stream #0:0 (libx264) apad:default -> Stream #0:1 (aac) Press [q] to stop, [?] for help [libx264 @ 0x555915e58440] using SAR=1/1 [libx264 @ 0x555915e58440] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 BMI2 AVX2 AVX512 [libx264 @ 0x555915e58440] profile High, level 4.0, 4:2:0, 8-bit Output #0, hls, to 'streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/stream.m3u8': Metadata: service_provider: "tunarr" service_name : "Adult Swim" encoder : Lavf61.1.100 Stream #0:0: Video: h264, yuv420p(tv, bt709, progressive), 1920x1080 [SAR 1:1 DAR 16:9], q=2-31, 10000 kb/s, 29.97 fps, 90k tbn Metadata: encoder : Lavc61.3.100 libx264 Side data: cpb: bitrate max/min/avg: 10000000/0/10000000 buffer size: 1000000 vbv_delay: N/A Stream #0:1: Audio: aac, 48000 Hz, stereo, fltp, 192 kb/s Metadata: encoder : Lavc61.3.100 aac [hls @ 0x555915e6a300] Opening 'streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/data00000.ts' for writing [hls @ 0x555915e6a300] Opening 'streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/stream.m3u8.tmp' for writing [hls @ 0x555915e6a300] Opening 'streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/master.m3u8' for writing [hls @ 0x555915e6a300] Opening 'streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/data00001.ts' for writing [hls @ 0x555915e6a300] Opening 'streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/stream.m3u8.tmp' for writing [hls @ 0x555915e6a300] Opening 'streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/data00002.ts' for writing [hls @ 0x555915e6a300] Opening 'streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/stream.m3u8.tmp' for writing [in#0 @ 0x55e374b48880] Error opening input: Immediate exit requested Error opening input file http://localhost:8000/stream/channels/8be2d5f0-42fa-458d-86dd-6fba2c7cc321.m3u8?mode=hls. Exiting normally, received signal 15. 2024-10-05T14:09:19.245Z [info]: Concat Wrapper FFMPEG exited. (signal=null, code=0, expected?=true) {"args":"-nostdin -threads 1 -hide_banner -loglevel info -user_agent Ffmpeg Tunarr/0.12.3 -nostats -fflags +genpts+discardcorrupt+igndts -reconnect 1 -reconnect_at_eof 1 -readrate 1 -i http://localhost:8000/stream/channels/8be2d5f0-42fa-458d-86dd-6fba2c7cc321.m3u8?mode=hls -map 0 -c copy -f mpegts pipe:1"} [hls @ 0x555915e6a300] Opening 'streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/data00003.ts' for writing [hls @ 0x555915e6a300] Opening 'streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/stream.m3u8.tmp' for writing [hls @ 0x555915e6a300] Opening 'streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/data00004.ts' for writing [hls @ 0x555915e6a300] Opening 'streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/stream.m3u8.tmp' for writing [hls @ 0x555915e6a300] Opening 'streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/data00005.ts' for writing [hls @ 0x555915e6a300] Opening 'streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/stream.m3u8.tmp' for writing [hls @ 0x555915e6a300] Opening 'streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/data00006.ts' for writing [hls @ 0x555915e6a300] Opening 'streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/stream.m3u8.tmp' for writing [out#0/hls @ 0x555915e30f40] video:17315KiB audio:751KiB subtitle:0KiB other streams:0KiB global headers:0KiB muxing overhead: unknown frame= 777 fps= 62 q=-1.0 Lsize=N/A time=00:00:25.85 bitrate=N/A dup=2 drop=0 speed=2.08x
[libx264 @ 0x555915e58440] frame I:13 Avg QP:16.24 size: 99122 [libx264 @ 0x555915e58440] frame P:225 Avg QP:12.70 size: 58734 [libx264 @ 0x555915e58440] frame B:539 Avg QP:16.33 size: 5986 [libx264 @ 0x555915e58440] consecutive B-frames: 5.3% 5.1% 4.6% 84.9% [libx264 @ 0x555915e58440] mb I I16..4: 40.4% 47.2% 12.4% [libx264 @ 0x555915e58440] mb P I16..4: 2.7% 5.3% 1.4% P16..4: 29.4% 8.7% 9.3% 0.0% 0.0% skip:43.3% [libx264 @ 0x555915e58440] mb B I16..4: 0.1% 0.1% 0.1% B16..8: 20.3% 1.5% 0.4% direct: 1.8% skip:75.7% L0:44.8% L1:52.1% BI: 3.1% [libx264 @ 0x555915e58440] 8x8 transform intra:52.3% inter:55.9% [libx264 @ 0x555915e58440] coded y,uvDC,uvAC intra: 55.8% 72.4% 54.0% inter: 9.6% 15.6% 6.1% [libx264 @ 0x555915e58440] i16 v,h,dc,p: 53% 29% 9% 9% [libx264 @ 0x555915e58440] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 20% 33% 26% 3% 3% 3% 3% 3% 5% [libx264 @ 0x555915e58440] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 30% 26% 14% 3% 6% 8% 4% 4% 4% [libx264 @ 0x555915e58440] i8c dc,h,v,p: 48% 30% 17% 5% [libx264 @ 0x555915e58440] Weighted P-Frames: Y:0.0% UV:0.0% [libx264 @ 0x555915e58440] ref P L0: 69.7% 2.2% 18.4% 9.7% [libx264 @ 0x555915e58440] ref B L0: 85.3% 11.8% 2.9% [libx264 @ 0x555915e58440] ref B L1: 93.5% 6.5% [libx264 @ 0x555915e58440] kb/s:5471.10 [aac @ 0x555915f14b40] Qavg: 61730.594 Exiting normally, received signal 15. 2024-10-05T14:09:24.499Z [info]: Raw Stream FFMPEG exited. (signal=null, code=255, expected?=false) {"args":"-hide_banner -threads 4 -fflags +genpts+discardcorrupt+igndts -loglevel info -reconnect 1 -reconnect_on_network_error 1 -reconnect_streamed 1 -multiple_requests 1 -readrate 1.0 -readrate_initial_burst 45 -ss 246.343 -i https://192-168-1-13.f85e63350a2d4839be9686b04402aa13.plex.direct:32400/library/parts/58579/1659085944/file.mkv?X-Plex-Token=REDACTED -filter_complex [0:0]null[video];[video]scale=1440:1080:flags=bicubic,format=yuv420p[scaled];[scaled]pad=1920:1080:(ow-iw)/2:(oh-ih)/2[blackpadded];[blackpadded]setsar=1,format=yuv420p[siz];[0:1]anull[audio];[audio]aresample=48000,aresample=async=1:first_pts=0,apad=whole_dur=442617ms[padded] -map [siz] -c:v libx264 -b:v 10000k -maxrate:v 10000k -bufsize:v 1000k -sc_threshold 0 -video_track_timescale 90000 -map [padded] -flags cgop+ilme -b:a 192k -maxrate:a 192k -bufsize:a 50k -ac 2 -ar 48k -map_metadata -1 -movflags +faststart -muxdelay 0 -muxpreload 0 -fps_mode cfr -metadata service_provider=\"tunarr\" -metadata service_name=\"Adult Swim\" -t 442617ms -g 120 -keyint_min 120 -force_key_frames expr:gte(t,n_forced2) -f hls -hls_time 4 -hls_list_size 0 -segment_list_flags +live -hls_flags program_date_time+omit_endlist+discont_start+append_list -hls_segment_type mpegts -hls_base_url /stream/channels/8be2d5f0-42fa-458d-86dd-6fba2c7cc321/hls/ -hls_segment_filename streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/data%05d.ts -master_pl_name master.m3u8 streams/stream_8be2d5f0-42fa-458d-86dd-6fba2c7cc321/stream.m3u8"} 2024-10-05T14:09:24.500Z [error]: Received error from session. Shutting down {"sessionType":"hls","channelId":"8be2d5f0-42fa-458d-86dd-6fba2c7cc321"} error: {} 2024-10-05T14:10:10.888Z [warn]: No underlying session of type hls found for existing concat session (channel id = c79f4dc6-fa35-4cef-afa1-237620e2b85a). Removing dangling session and recreating 2024-10-05T14:10:10.931Z [warn]: No last segment found {"sessionId":"c7372594-19e3-4b5c-8bec-241cbdadf950","channel":"8be2d5f0-42fa-458d-86dd-6fba2c7cc321","sessionType":"hls"} [https @ 0x55a10174c3c0] HTTP error 400 Bad Request [in#0 @ 0x55a10174bb80] Error opening input: Server returned 400 Bad Request Error opening input file https://192-168-1-13.f85e63350a2d4839be9686b04402aa13.plex.direct:32400/library/parts/84130/1630852155/file.mkv?X-Plex-Token=Redacted. Error opening input files: Server returned 400 Bad Request 2024-10-05T14:10:17.144Z [info]: Raw Stream FFMPEG exited. (signal=null, code=8, expected?=false) {"args":"-hide_banner -threads 4 -fflags +genpts+discardcorrupt+igndts -loglevel info -reconnect 1 -reconnect_on_network_error 1 -reconnect_streamed 1 -multiple_requests 1 -readrate 1.0 -readrate_initial_burst 45 -ss 1154.603 -i https://192-168-1-13.f85e63350a2d4839be9686b04402aa13.plex.direct:32400/library/parts/84130/1630852155/file.mkv?X-Plex-Token=REDACTED -filter_complex [0:1]anull[audio];[audio]aresample=48000,aresample=async=1:first_pts=0,apad=whole_dur=131691ms[padded] -map 0:0 -c:v libx264 -b:v 10000k -maxrate:v 10000k -bufsize:v 1000k -sc_threshold 0 -video_track_timescale 90000 -map [padded] -flags cgop+ilme -b:a 192k -maxrate:a 192k -bufsize:a 50k -ac 2 -ar 48k -map_metadata -1 -movflags +faststart -muxdelay 0 -muxpreload 0 -fps_mode cfr -metadata service_provider=\"tunarr\" -metadata service_name=\"Channel 2\" -t 131691ms -g 96 -keyint_min 96 -force_key_frames expr:gte(t,n_forced2) -f hls -hls_time 4 -hls_list_size 0 -segment_list_flags +live -hls_flags program_date_time+omit_endlist+discont_start+append_list -hls_segment_type mpegts -hls_base_url /stream/channels/c79f4dc6-fa35-4cef-afa1-237620e2b85a/hls/ -hls_segment_filename streams/stream_c79f4dc6-fa35-4cef-afa1-237620e2b85a/data%05d.ts -master_pl_name master.m3u8 streams/stream_c79f4dc6-fa35-4cef-afa1-237620e2b85a/stream.m3u8"} [in#0 @ 0x55f1dd7fb880] Error opening input: Immediate exit requested 2024-10-05T14:10:17.145Z [error]: Received error from session. Shutting down {"sessionType":"hls","channelId":"c79f4dc6-fa35-4cef-afa1-237620e2b85a"}Error opening input file http://localhost:8000/stream/channels/c79f4dc6-fa35-4cef-afa1-237620e2b85a.m3u8?mode=hls.

Exiting normally, received signal 15. error: {} 2024-10-05T14:10:17.146Z [error]: Received error from session. Shutting down {"sessionType":"hls","channelId":"c79f4dc6-fa35-4cef-afa1-237620e2b85a"} error: {} 2024-10-05T14:10:17.147Z [error]: Error playing video {"code":8,"cmd":"/usr/bin/ffmpeg -hide_banner -threads 4 -fflags +genpts+discardcorrupt+igndts -loglevel info -reconnect 1 -reconnect_on_network_error 1 -reconnect_streamed 1 -multiple_requests 1 -readrate 1.0 -readrate_initial_burst 45 -ss 1154.603 -i https://192-168-1-13.f85e63350a2d4839be9686b04402aa13.plex.direct:32400/library/parts/84130/1630852155/file.mkv?X-Plex-Token=REDACTED -filter_complex [0:1]anull[audio];[audio]aresample=48000,aresample=async=1:first_pts=0,apad=whole_dur=131691ms[padded] -map 0:0 -c:v libx264 -b:v 10000k -maxrate:v 10000k -bufsize:v 1000k -sc_threshold 0 -video_track_timescale 90000 -map [padded] -flags cgop+ilme -b:a 192k -maxrate:a 192k -bufsize:a 50k -ac 2 -ar 48k -map_metadata -1 -movflags +faststart -muxdelay 0 -muxpreload 0 -fps_mode cfr -metadata service_provider=\"tunarr\" -metadata service_name=\"Channel 2\" -t 131691ms -g 96 -keyint_min 96 -force_key_frames expr:gte(t,n_forced*2) -f hls -hls_time 4 -hls_list_size 0 -segment_list_flags +live -hls_flags program_date_time+omit_endlist+discont_start+append_list -hls_segment_type mpegts -hls_base_url /stream/channels/c79f4dc6-fa35-4cef-afa1-237620e2b85a/hls/ -hls_segment_filename streams/stream_c79f4dc6-fa35-4cef-afa1-237620e2b85a/data%05d.ts -master_pl_name master.m3u8 streams/stream_c79f4dc6-fa35-4cef-afa1-237620e2b85a/stream.m3u8"} 2024-10-05T14:10:17.160Z [info]: Concat Wrapper FFMPEG exited. (signal=null, code=0, expected?=true) {"args":"-nostdin -threads 1 -hide_banner -loglevel info -user_agent Ffmpeg Tunarr/0.12.3 -nostats -fflags +genpts+discardcorrupt+igndts -reconnect 1 -reconnect_at_eof 1 -readrate 1 -i http://localhost:8000/stream/channels/c79f4dc6-fa35-4cef-afa1-237620e2b85a.m3u8?mode=hls -map 0 -c copy -f mpegts pipe:1"} Input #0, png_pipe, from 'http://localhost:8000/images/generic-error-screen.png': Duration: N/A, bitrate: N/A Stream #0:0: Video: png, rgba(pc, gbr/bt709/iec61966-2-1), 1920x1080 [SAR 2835:2835 DAR 16:9], 25 fps, 25 tbr, 25 tbn [out#0/nut @ 0x5617451d2fc0] Codec AVOption sc_threshold (Scene change threshold) has not been used for any stream. The most likely reason is either wrong type (e.g. a video option with no video streams) or that it is a private option of some encoder which was not actually used for any stream. Stream mapping: Stream #0:0 (png) -> format:default realtime:default -> Stream #0:0 (rawvideo) arealtime:default -> Stream #0:1 (flac) Press [q] to stop, [?] for help [flac @ 0x5617451d6540] encoding as 24 bits-per-sample, more is considered experimental. Add -strict experimental if you want to encode more than 24 bits-per-sample Output #0, nut, to 'pipe:1': Metadata: service_provider: "tunarr" service_name : "Channel 2" encoder : Lavf61.1.100 Stream #0:0: Video: rawvideo (I420 / 0x30323449), yuv420p(unknown/bt709/iec61966-2-1, progressive), 1920x1080 [SAR 1:1 DAR 16:9], q=2-31, 597196 kb/s, 24 fps, 49152 tbn Metadata: encoder : Lavc61.3.100 rawvideo Stream #0:1: Audio: flac ([172][241][0][0] / 0xF1AC), 48000 Hz, mono, s32 (24 bit), 128 kb/s Metadata: encoder : Lavc61.3.100 flac 2024-10-05T14:10:19.756Z [error]: Bailing on stream start, had error! {"sessionId":"c7372594-19e3-4b5c-8bec-241cbdadf950","channel":"8be2d5f0-42fa-458d-86dd-6fba2c7cc321","sessionType":"hls"} err: { "type": "Error", "message": "Error in underlying FFMPEG process: (code=8)", "stack": Error: Error in underlying FFMPEG process: (code=8) at _FfmpegTranscodeSession. (file:///tunarr/server/build/bundle.js:271941:24) at _FfmpegTranscodeSession.emit (node:events:531:35) at _FfmpegProcess. (file:///tunarr/server/build/bundle.js:269015:12) at _FfmpegProcess.emit (node:events:531:35) at ChildProcess. (file:///tunarr/server/build/bundle.js:268953:14) at ChildProcess.emit (node:events:519:28) at ChildProcess._handle.onexit (node:internal/child_process:294:12) at Process.callbackTrampoline (node:internal/async_hooks:130:17) } 2024-10-05T14:10:19.759Z [error]: Error starting stream after retrying {"sessionId":"c7372594-19e3-4b5c-8bec-241cbdadf950","channel":"8be2d5f0-42fa-458d-86dd-6fba2c7cc321","sessionType":"hls"} err: { "type": "Error", "message": "Error in underlying FFMPEG process: (code=8)", "stack": Error: Error in underlying FFMPEG process: (code=8) at _FfmpegTranscodeSession. (file:///tunarr/server/build/bundle.js:271941:24) at _FfmpegTranscodeSession.emit (node:events:531:35) at _FfmpegProcess. (file:///tunarr/server/build/bundle.js:269015:12) at _FfmpegProcess.emit (node:events:531:35) at ChildProcess. (file:///tunarr/server/build/bundle.js:268953:14) at ChildProcess.emit (node:events:519:28) at ChildProcess._handle.onexit (node:internal/child_process:294:12) at Process.callbackTrampoline (node:internal/async_hooks:130:17) } 2024-10-05T14:10:19.761Z [error]: Received error from session. Shutting down {"sessionType":"hls","channelId":"c79f4dc6-fa35-4cef-afa1-237620e2b85a"} error: {}

chrisbenincasa commented 6 days ago

Interesting. It looks like the the underlying error is a request error from your Plex server for some reason...


https @ 0x55a10174c3c0] HTTP error 400 Bad Request
[in#0 @ 0x55a10174bb80] Error opening input: Server returned 400 Bad Request
Error opening input file https://192-168-1-13.f85e63350a2d4839be9686b04402aa13.plex.direct:32400/library/parts/84130/1630852155/file.mkv?X-Plex-Token=REDACTED.
Error opening input files: Server returned 400 Bad Request
Liquidbings commented 6 days ago

Strange...After reading your comment I tried plex on another device and it works on there... Curious to what the issue is when trying to view it through the plex container.

It also works on the PC using the browser version of plex... So it seems like the Unraid Container version of plex is the one causing the issue.

chrisbenincasa commented 3 days ago

Hmmm.. that's interesting. Perhaps there is an issue of network communication between the containerized Plex + Tunarr.