Answers.Body: <p>Recently I've had the chance to research a bit in this area, and I've come across some rumors that ffmpeg's support for RTSP is somewhat buggy, i.e. it stops suddenly or yields mangled frames.
  If you need only video, you can use openrtsp app from Live555 it can output stream to stdout to be consumed with -i -" in ffmpeg (Live555's client seems to be state of the art wiht RTSP)</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-09-26T21:17:08.123Z
Answers.LastActivityDate: 2016-09-26T21:17:08.123Z
Answers.UserDisplayName: Pawel K
Body: <p>I need to provide MPEG-DASH live content generation from several IP cameras.</p>
  
  <p>I use <a href="https://github.com/arut/nginx-rtmp-module" rel="nofollow"><strong>ngx_rtmp_module</strong></a> + <strong>ffmpeg</strong> for creating MPEG DASH content.
  Everything work fine, but if I leave the conversion running for long periods of time, ffmpeg stops working after 1-2 days (sometimes early, sometimes later).</p>
  
  <p>This is the ffmpeg command I'm using:</p>
  
  <pre><code>ffmpeg -re -f rtsp -rtsp_transport tcp -i &lt;rtsp_url&gt; -c copy -movflags empty_moov+omit_tfhd_offset+frag_keyframe+default_base_moof -f flv rtmp://localhost/myapp/mystream
  </code></pre>
  
  <p>Then ffmpeg tells me that some RTSP packets were lost and it freezes its work process.</p>
  
  <p>Does anyone know any another tools that can do this conversion that won't stop until I tell it to or there is a problem with the camera? Or possibly another way with ffmpeg that avoids this issue?</p>
  
  <p>Thanks in advance.</p>
  
Tags: <ffmpeg><live>
Title: FFMPEG RTSP -> MPEG-DASH Stops on Long Streams
UserDisplayName: ArhiChief
ThreadText: # FFMPEG RTSP -> MPEG-DASH Stops on Long Streams
  
  (Asked by: username_0 on 2016-05-20)
  
  I need to provide MPEG-DASH live content generation from several IP cameras.
  
  I use [**ngx\_rtmp\_module**](https://github.com/arut/nginx-rtmp-module) + **ffmpeg** for creating MPEG DASH content.
  Everything work fine, but if I leave the conversion running for long periods of time, ffmpeg stops working after 1-2 days (sometimes early, sometimes later).
  
  This is the ffmpeg command I'm using:
  
  ```
  ffmpeg -re -f rtsp -rtsp_transport tcp -i <rtsp_url> -c copy -movflags empty_moov+omit_tfhd_offset+frag_keyframe+default_base_moof -f flv rtmp://localhost/myapp/mystream
  
  ```
  
  Then ffmpeg tells me that some RTSP packets were lost and it freezes its work process.
  
  Does anyone know any another tools that can do this conversion that won't stop until I tell it to or there is a problem with the camera? Or possibly another way with ffmpeg that avoids this issue?
  
  Thanks in advance.
  
  **Tags:** ffmpeg, live
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2016-09-26. Score: 1
  
  Recently I've had the chance to research a bit in this area, and I've come across some rumors that ffmpeg's support for RTSP is somewhat buggy, i.e. it stops suddenly or yields mangled frames.
  If you need only video, you can use openrtsp app from Live555 it can output stream to stdout to be consumed with -i -" in ffmpeg (Live555's client seems to be state of the art wiht RTSP)
  
  
  ---
  
  