illuspas / Node-Media-Server

A Node.js implementation of RTMP/HTTP-FLV/WS-FLV/HLS/DASH/MP4 Media Server
https://www.npmjs.com/package/node-media-server
MIT License
5.9k stars 1.51k forks source link

FLV ffmpeg -Error writing trailer of rtmp #525

Open ninanoe opened 2 years ago

ninanoe commented 2 years ago

When publishing a stream to NMS it works, only for some time and after a few minutes it crashes.

2022/05/22 19:02:35 [I] Exit terminated rtmp://127.0.0.1:1935/live/play4: I/O error

C:\nms>av_interleaved_write_frame(): Unknown error Last message repeated 1 times Error writing trailer of rtmp://127.0.0.1:1935/live/play4_720: Error number -10054 occurred Error writing trailer of rtmp://127.0.0.1:1935/live/play4_360: Error number -10054 occurred

--

ffmpeg erros is

av_interleaved_write_frame(): Unknown errortime=00:03:17.60 bitrate=4011.5kbits/s speed=0.999x Last message repeated 1 times Error writing trailer of rtmp://str-01.ninanoe.net/live/play4: Error number -10054 occurred

After debug logs I could see it is writing on the NMS server, so the problem look to be at NMS ?

ffmpeg -re -i http://domain.com/28144 -vf yadif -c:v libx264 -x264-params "no-scenecut=1" -preset:v ultrafast -crf 27 -tune zerolatency -c:a aac -ar 44100 -f flv -flvflags "no_duration_filesize" "rtmp://localhost/live/play4"

YoJames2019 commented 1 year ago

did you ever get this fixed?