解决ffmpeg拉流转发频繁丢包问题max delay reached. need to consume packet
2024-10-18 10:56:12
软件:
1、流媒体服务器EasyDarwin-windows-8.1.0-1901141151
2、ffmpeg-20181001-dcbd89e-win64-static
3、直播源:rtsp://192.168.1.168/0
4、流媒体服务器EasyDarwin地址rtsp://192.168.1.28/3
问题现象
[rtsp @ 0000000000122bc0] max delay reached. need to consume packet
[rtsp @ 0000000000122bc0] RTP: missed 33 packets
[rtsp @ 0000000000122bc0] max delay reached. need to consume packet
[rtsp @ 0000000000122bc0] RTP: missed 166 packets
[h264 @ 0000000002f4b280] out of range intra chroma pred mode
[h264 @ 0000000002f4b280] error while decoding MB 27 39
[h264 @ 0000000002f4b280] concealing 502 DC, 502 AC, 502 MV errors in P f
[h264 @ 0000000002ed08c0] Increasing reorder buffer to 8
frame= 964 fps= 30 q=29.0 size=N/A time=00:00:33.26 bitrate=N/A dup=141
frame= 999 fps= 31 q=29.0 size=N/A time=00:00:33.77 bitrate=N/A dup=170
[rtsp @ 0000000000122bc0] max delay reached. need to consume packet
[rtsp @ 0000000000122bc0] RTP: missed 12 packets
[h264 @ 0000000002ed1000] corrupted macroblock 55 32 (total_coeff=-1)
[h264 @ 0000000002ed1000] error while decoding MB 55 32
解决方法:
采用以下命令进行拉流转发,运行了几个小时,几乎没有出现丢包现象
ffmpeg -rtsp_transport tcp -i rtsp://192.168.1.168/0 -vcodec copy -f rtsp rtsp://192.168.1.28/11
原因:这是rtsp协议默认使用udp导致的问题,所以rtsp强制使用tcp方式可以一定程度避免丢包。
如果是拉rtsp转rtmp,命令是(没测试)
ffmpeg -rtsp_transport tcp -i rtsp://admin:password@192.168.1.11:554 -vcodec copy -f flv -an rtmp://localhost/live/tests
参考:https://github.com/eguid/FFCH4J/issues/11
最新文章
- Hadoop FS shell commands
- Delphi初学者,向万一老师致敬
- Highcharts图形报表的简单使用
- JS延时提示框
- TCP的流量控制和拥塞控制
- 抓取oschina上面的代码分享python块区下的 标题和对应URL
- linux C 数组操作
- poj1190生日蛋糕
- [转载]DIV CSS设计时IE6、IE7、FF 与兼容性有关的特性
- BZOJ 4013 实验比较
- Qt学习笔记网络(URL和下载的功能都有)
- Linux i2c子系统(三) _解决probe无法执行
- BC高精确度函数使用。
- (2018干货系列三)最新PHP学习路线整合
- iOS中 Swift初级入门学习(三)
- [Hibernate] hibernate.cfg.xml 配置文件的一些设置
- RECON-NG
- Centos7 安装hive
- VBA学习笔记(3)--文件夹操作
- jQuery|简单tab栏切换