[FFmpeg-user] HTTP Reconnect not Recovering

Robert Nagy ronag89 at gmail.com
Fri Jul 29 15:44:32 EEST 2016


I'm unable to get ffplay/ffmpeg to properly wait and reconnect to a http
stream.

1. ffplay -reconnect 1 -i
http://localhost:8000/file/cir7q2zxh00013l5hh0src1fh.mxf
2. Kill file server
3. Start file server
4. ffplay does not recover

I've also tried with a H264 stream with similar results. Am I doing
something wrong here or misunderstanding the reconnect feature?

Given that I'm getting decoder errors after the 3rd reconnect (before the
file server has started) it looks like the decoder is either getting
incomplete data or just continuing without waiting for the complete data.
Do I need to provide some other flag somewhere?

ffplay -reconnect 1 -i
http://localhost:8000/file/cir7q2zxh00013l5hh0src1fh.mxf
ffplay version 3.1.1 Copyright (c) 2003-2016 the FFmpeg developers
  built with Apple LLVM version 7.3.0 (clang-703.0.31)
  configuration: --prefix=/usr/local/Cellar/ffmpeg/3.1.1 --enable-shared
--enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables
--enable-avresample --cc=clang --host-cflags= --host-ldflags=
--enable-opencl --enable-libx264 --enable-libmp3lame --enable-libxvid
--enable-libtheora --enable-libvorbis --enable-libvpx --enable-librtmp
--enable-libass --enable-ffplay --enable-openssl --enable-libwebp
--disable-lzma --enable-nonfree --enable-vda
  libavutil      55. 28.100 / 55. 28.100
  libavcodec     57. 48.101 / 57. 48.101
  libavformat    57. 41.100 / 57. 41.100
  libavdevice    57.  0.101 / 57.  0.101
  libavfilter     6. 47.100 /  6. 47.100
  libavresample   3.  0.  0 /  3.  0.  0
  libswscale      4.  1.100 /  4.  1.100
  libswresample   2.  1.100 /  2.  1.100
  libpostproc    54.  0.100 / 54.  0.100
Input #0, mxf, from '
http://localhost:8000/file/cir7q2zxh00013l5hh0src1fh.mxf':
  Metadata:
    uid             : 4d1aae04-d0ab-054c-95dd-c34331a6c180
    generation_uid  : e3383bad-5640-d74c-b17d-52f501bf5232
    company_name    : AVID
    product_name    : TRMG
    product_version : 3.01
    product_uid     : 00000000-0000-0000-0000-000000000000
    modification_date: 2016-05-25 19:02:01
    material_package_umid:
0x060A2B340101010501010D13130000007BC188289BB1014EA5B0C324D39FBD82
    timecode        : 00:00:00:00
  Duration: 00:01:36.20, start: 0.000000, bitrate: 52773 kb/s
    Stream #0:0: Video: mpeg2video (4:2:2), yuv422p(tv, bt709), 1920x1080
[SAR 1:1 DAR 16:9], 50000 kb/s, 25 fps, 25 tbr, 25 tbn, 50 tbc
    Metadata:
      file_package_umid:
0x060A2B340101010501010D13130000005E29E99955696B49929422F6D96275AA
    Stream #0:1: Audio: pcm_s24le, 48000 Hz, 1 channels, s32 (24 bit), 1152
kb/s
    Metadata:
0x060A2B340101010501010D13130000005E29E99955696B49929422F6D96275AA=    0KB
sq=    0B f=0/0
    Stream #0:2: Audio: pcm_s24le, 48000 Hz, 1 channels, s32 (24 bit), 1152
kb/s
    Metadata:
      file_package_umid:
0x060A2B340101010501010D13130000005E29E99955696B49929422F6D96275AA
2016-07-29 14:40:33.552 ffplay[37392:18604198] 14:40:33.552 WARNING:  140:
This application, or a library it uses, is using the deprecated Carbon
Component Manager for hosting Audio Units. Support for this will be removed
in a future release. Also, this makes the host incompatible with version 3
audio units. Please transition to the API's in AudioComponent.h.
[http @ 0x7faffac2f0e0] Stream ends prematurely at 24747376, should be
634606248
[http @ 0x7faffac2f0e0] Will reconnect at 24747376 error=Input/output error.
[tcp @ 0x7faffad53d80] Connection to tcp://localhost:8000 failed
(Connection refused), trying next address
[tcp @ 0x7faffad53d80] Connection to tcp://localhost:8000 failed:
Connection refused
[http @ 0x7faffac2f0e0] Failed to reconnect at 24747376.
[tcp @ 0x7faffad53d80] Connection to tcp://localhost:8000 failed
(Connection refused), trying next address
[tcp @ 0x7faffad53d80] Connection to tcp://localhost:8000 failed:
Connection refused
[http @ 0x7faffac2f0e0] Stream ends prematurely at 24747376, should be
634606248
[http @ 0x7faffac2f0e0] Will reconnect at 24747376 error=Input/output error.
[tcp @ 0x7faffd02a8e0] Connection to tcp://localhost:8000 failed
(Connection refused), trying next address
[tcp @ 0x7faffd02a8e0] Connection to tcp://localhost:8000 failed:
Connection refused
[http @ 0x7faffac2f0e0] Failed to reconnect at 24747376.
[http @ 0x7faffac2f0e0] Stream ends prematurely at 24747376, should be
634606248
[http @ 0x7faffac2f0e0] Will reconnect at 24747376 error=Input/output error.
[mpeg2video @ 0x7faffe809e00] ac-tex damaged at 14 64    0B f=0/0
[mpeg2video @ 0x7faffe809e00] Warning MVs not available
[mpeg2video @ 0x7faffe809e00] concealing 480 DC, 480 AC, 480 MV errors in B
frame


More information about the ffmpeg-user mailing list