Answers.Body: <p>I'm pretty sure you can use vlc to both stream and restream it. I use vlc to stream all my tv channels to all my devices(rtsp, mp4, html5).</p>
  
  <p>Search for vlc media player streaming like </p>
  
  <p><a href="https://www.videolan.org/doc/streaming-howto/en/ch04.html" rel="nofollow">https://www.videolan.org/doc/streaming-howto/en/ch04.html</a></p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-01-05T09:08:03.740Z
Answers.LastActivityDate: 2015-01-05T09:08:03.740Z
Answers.UserDisplayName: leaveswater02
Answers.Body: <p>If you just want a plain RTMP stream, you might look at the <a href="https://github.com/arut/nginx-rtmp-module" rel="nofollow">nginx-rtmp</a> module which looks quite easier to set up than crtmpserver.</p>
  
  <p>Just a general suggestion: <a href="http://en.wikipedia.org/wiki/H.264/MPEG-4_AVC" rel="nofollow">H.264</a> compression is a bit CPU-intensive, so if your server is more powerful than your notebook and the server to notebook-connection is good, it might be an idea to stream just "plain frames" with nearly no encoding or compression to the server and let it handle the rest.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-08-07T11:32:42.777Z
Answers.LastActivityDate: 2015-01-02T11:00:31.240Z
Answers.LastEditDate: 2015-01-02T11:00:31.240Z
Answers.UserDisplayName: jwacalex
Answers.Body: <p><a href="https://net7mma.codeplex.com" rel="nofollow noreferrer">https://net7mma.codeplex.com</a> has a server and client implementation which is compatible with VLC and was created for exactly the scenario you cite. From the website:</p>
  <blockquote>
  <p>This project's goal is to allow developers to deliver media to clients freely in less then 10 lines of code utilizing standards complaint protocol implementations. It also aims to provide a re-usable set of classes for working with Rtsp and Rtp/Rtcp and Sdp.</p>
  </blockquote>
  <p>There is a new download link if you wish to try this software out:
  <a href="https://github.com/juliusfriedman/net7mma" rel="nofollow noreferrer">https://github.com/juliusfriedman/net7mma</a></p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2014-08-02T18:03:54.467Z
Answers.LastActivityDate: 2020-06-29T10:32:03.597Z
Answers.LastEditDate: 2020-06-29T10:32:03.597Z
Answers.UserDisplayName: Jay
Answers.Body: <p>It looks like it isn't particularly trivial, however crtmpserver have a tutorial on their wiki <a href="http://wiki.rtmpd.com/tutorial_live_stream_file" rel="nofollow noreferrer">here</a>.  It looks like you have to configure a lua file and then doing a new cmake of the server.  (So very much non-trivial.)</p>
  
  <p>As an alternative, there are other servers that may do this for you more easily such as Red5 and also Adobe has a free offering mentioned in <a href="https://video.stackexchange.com/questions/7681/how-do-i-set-up-an-rtmp-stream-server-and-url-endpoint/">this question</a>.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-04-08T20:57:53.863Z
Answers.LastActivityDate: 2014-04-08T20:57:53.863Z
Answers.LastEditDate: 2017-04-13T12:46:08.110Z
Answers.UserDisplayName: AJ Henderson
Answers.Body: <blockquote>
    <p>A Linux laptop has a webcam connected to it and captures video and
    audio in real time</p>
  </blockquote>
  
  <p>Im using ffmpeg version N-80213-g9511a08 and my system is Ubuntu 15.10</p>
  
  <pre><code>ffmpeg -f video4linux2 -s 320x240 -i /dev/video0 -f flv -s qvga -b 750000 -ar 11025 -metadata streamName=aaa "tcp://server_ip:6666/live" 
  </code></pre>
  
  <blockquote>
    <p>The laptop sends the live video and audio stream to another Linux
    server which has a better internet connection than the laptop, via
    RTSP or RTMP or something similar</p>
  </blockquote>
  
  <p>start crtmpserver.lua</p>
  
  <pre><code>./crtmpserver/crtmpserver crtmpserver/crtmpserver.lua
  </code></pre>
  
  <p>after running the previous command it will show incoming stream like </p>
  
  <p>/home/altanai/crtmpserver/sources/thelib/src/protocols/liveflv/inboundliveflvprotocol.cpp:51 _waitForMetadata: 1
  /home/altanai/crtmpserver/sources/thelib/src/netio/epoll/iohandlermanager.cpp:119 Handlers count changed: 11->12 IOHT_TCP_CARRIER
  /home/altanai/crtmpserver/sources/thelib/src/protocols/liveflv/baseliveflvappprotocolhandler.cpp:45 protocol CTCP(16) &lt;-> TCP(2) &lt;-> [ILFL(3)] registered to app flvplayback
  /home/altanai/crtmpserver/sources/thelib/src/application/baseclientapplication.cpp:251 Stream INLFLV(1) with name <code>127.0.0.1_51036</code> registered to application <code>flvplayback</code> from protocol ILFL(3)
  /home/altanai/crtmpserver/sources/thelib/src/protocols/liveflv/inboundliveflvprotocol.cpp:184 Stream metadata:
  
      
          0.000
          Lavf57.37.101
          0.000
          30.000
          240.000
          2.000
          732.422
          320.000
      
  </p>
  
  <blockquote>
    <p>Any clients that wish to view the stream connect to the Linux server by means of some software such as VLC</p>
  </blockquote>
  
  <p>ffplay -i rtmp://server_ip:1935/live/aaa</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-06-09T10:40:11.660Z
Answers.LastActivityDate: 2016-06-11T09:05:12.037Z
Answers.LastEditDate: 2016-06-11T09:05:12.037Z
Answers.UserDisplayName: Altanai
Body: <p>This is what I would like to do.</p>
  
  <ol>
  <li>A Linux laptop has a webcam connected to it and captures video and audio in real time</li>
  <li>The laptop sends the live video and audio stream to another Linux server which has a better internet connection than the laptop, via RTSP or RTMP or something similar</li>
  <li>Any clients that wish to view the stream connect to the Linux server by means of some software such as VLC</li>
  </ol>
  
  <p>The steps 1 and 3 are not a problem, I think I know how to do them. But:</p>
  
  <p>How do I configure the Linux server in step 2 so that it accepts an RTSP stream input and publishes it in some address such as rtsp://my.ip.address/stream.mp4 for example, which can be opened in VLC by any computer? Is crtmpserver the right tool for this? And how do I configure it? I've read like ten different web pages that explain some example configurations for crtmpserver but haven't really found what I was looking for.</p>
  
Tags: <streaming><live><rtmp>
Title: How to configure crtmpserver for live streaming?
UserDisplayName: kynnysmatto
ThreadText: # How to configure crtmpserver for live streaming?
  
  (Asked by: username_0 on 2014-04-07)
  
  This is what I would like to do.
  
  1. A Linux laptop has a webcam connected to it and captures video and audio in real time
  2. The laptop sends the live video and audio stream to another Linux server which has a better internet connection than the laptop, via RTSP or RTMP or something similar
  3. Any clients that wish to view the stream connect to the Linux server by means of some software such as VLC
  
  The steps 1 and 3 are not a problem, I think I know how to do them. But:
  
  How do I configure the Linux server in step 2 so that it accepts an RTSP stream input and publishes it in some address such as rtsp://my.ip.address/stream.mp4 for example, which can be opened in VLC by any computer? Is crtmpserver the right tool for this? And how do I configure it? I've read like ten different web pages that explain some example configurations for crtmpserver but haven't really found what I was looking for.
  
  **Tags:** streaming, live, rtmp
  
  
  ---
  
  ## 5 answers
  
  ### Answer by username_1 on 2015-01-05. Score: 3
  
  I'm pretty sure you can use vlc to both stream and restream it. I use vlc to stream all my tv channels to all my devices(rtsp, mp4, html5).
  
  Search for vlc media player streaming like
  
  <https://www.videolan.org/doc/streaming-howto/en/ch04.html>
  
  
  ---
  
  ### Answer by username_2 on 2014-08-07. Score: 2
  
  If you just want a plain RTMP stream, you might look at the [nginx-rtmp](https://github.com/arut/nginx-rtmp-module) module which looks quite easier to set up than crtmpserver.
  
  Just a general suggestion: [H.264](http://en.wikipedia.org/wiki/H.264/MPEG-4_AVC) compression is a bit CPU-intensive, so if your server is more powerful than your notebook and the server to notebook-connection is good, it might be an idea to stream just "plain frames" with nearly no encoding or compression to the server and let it handle the rest.
  
  
  ---
  
  ### Answer by username_3 on 2014-08-02. Score: 2
  
  <https://net7mma.codeplex.com> has a server and client implementation which is compatible with VLC and was created for exactly the scenario you cite. From the website:
  
  > This project's goal is to allow developers to deliver media to clients freely in less then 10 lines of code utilizing standards complaint protocol implementations. It also aims to provide a re-usable set of classes for working with Rtsp and Rtp/Rtcp and Sdp.
  
  There is a new download link if you wish to try this software out:
  <https://github.com/juliusfriedman/net7mma>
  
  
  ---
  
  ### Answer by username_4 on 2014-04-08. Score: 1
  
  It looks like it isn't particularly trivial, however crtmpserver have a tutorial on their wiki [here](http://wiki.rtmpd.com/tutorial_live_stream_file). It looks like you have to configure a lua file and then doing a new cmake of the server. (So very much non-trivial.)
  
  As an alternative, there are other servers that may do this for you more easily such as Red5 and also Adobe has a free offering mentioned in [this question](https://video.stackexchange.com/questions/7681/how-do-i-set-up-an-rtmp-stream-server-and-url-endpoint/).
  
  
  ---
  
  ### Answer by username_5 on 2016-06-09. Score: 0
  
  > A Linux laptop has a webcam connected to it and captures video and
  > audio in real time
  
  Im using ffmpeg version N-80213-g9511a08 and my system is Ubuntu 15.10
  
  ```
  ffmpeg -f video4linux2 -s 320x240 -i /dev/video0 -f flv -s qvga -b 750000 -ar 11025 -metadata streamName=aaa "tcp://server_ip:6666/live" 
  
  ```
  
  > The laptop sends the live video and audio stream to another Linux
  > server which has a better internet connection than the laptop, via
  > RTSP or RTMP or something similar
  
  start crtmpserver.lua
  
  ```
  ./crtmpserver/crtmpserver crtmpserver/crtmpserver.lua
  
  ```
  
  after running the previous command it will show incoming stream like
  
  /home/username_5/crtmpserver/sources/thelib/src/protocols/liveflv/inboundliveflvprotocol.cpp:51 \_waitForMetadata: 1
  /home/username_5/crtmpserver/sources/thelib/src/netio/epoll/iohandlermanager.cpp:119 Handlers count changed: 11->12 IOHT\_TCP\_CARRIER
  /home/username_5/crtmpserver/sources/thelib/src/protocols/liveflv/baseliveflvappprotocolhandler.cpp:45 protocol CTCP(16) <-> TCP(2) <-> [ILFL(3)] registered to app flvplayback
  /home/username_5/crtmpserver/sources/thelib/src/application/baseclientapplication.cpp:251 Stream INLFLV(1) with name `127.0.0.1_51036` registered to application `flvplayback` from protocol ILFL(3)
  /home/username_5/crtmpserver/sources/thelib/src/protocols/liveflv/inboundliveflvprotocol.cpp:184 Stream metadata:
  0.000
  Lavf57.37.101
  0.000
  30.000
  240.000
  2.000
  732.422
  320.000
  
  > Any clients that wish to view the stream connect to the Linux server by means of some software such as VLC
  
  ffplay -i rtmp://server\_ip:1935/live/aaa
  
  
  ---
  
  