Results 1 to 8 of 8

Thread: automatically/programaticall rtplive recording even when no flash client is connected

  1. #1
    Join Date
    Apr 2012
    Posts
    6

    Default automatically/programaticall rtplive recording even when no flash client is connected

    Hi,
    I want to automatically/programatically record all stream published at rtplive even if no flash client is conneted?

    I was following following article http://www.wowza.com/forums/content.php?37#FlashOnly

    For recording, I have changed application type to rtp-live-record . I also tried LiveStreamrRecord package.

    Problem : Stream becomes live only when at least one flash client is connected . That is stream does not start recording when no flash client is connected.
    I want to start recording stream, as soon as some one starts publishing weather or not any flash client is connected or not. It should be automated.

    I cannot use the Streammanager, because it requires someone to open streammanager and start publishing. I want this to be done automatically/programatically.

    Thanks,
    Sujeet

  2. #2

    Default

    Use StreamType live-record and start the streams automatically using StartupStreams.xml.

  3. #3
    Join Date
    Apr 2012
    Posts
    6

    Default

    Hi,
    Thank for your reply. But I fear that I cannot use StartupStreams.xml because of reasons specified below.
    My workflow is this
    1) Vlc will start publishing on some free random port using RTP/TS
    2) I need to inform wowza programatically that start receiving streams from this port and record the stream
    - Vlc will tell me the udp port. So programatically I will create file mpegts.stream, which will contain udp port on which to listen
    3) Some flash clients may be watching the stream live.

    Problem : 1) I cannot use StartupStreams.xml , because I don't know on which port I will have to listen. I know about the port only when vlc start streaming. Also multiple vlc client may be streaming at the same time, each one will stream to different ports. So I cannot hard code port number in Startupstream.xml

    2) Wowza start recording only when stream is live. Stream becomes live only when atleast one flash client is connected. What I need is that, when the vlc start streaming on some port, I will tell wowza programatically that start listening to this stream even if no flash client is connected. For this I cannot use Streammanager, because it will need someone to manually start receiving some stream. I want this to be automated by some program.

    Can I programatically manage Streammanager to start receiving some stream.

  4. #4
    Join Date
    Apr 2012
    Posts
    6

    Default

    Thanks Randall,

    Found the following post http://www.wowza.com/forums/showthre...ogrammatically

    I need to try that. If it works, then it will solve the purpose.

    Thanks,
    Sujeet

  5. #5

    Default

    "Can I programatically manage Streammanager to start receiving some stream."

    Yes you can, using the Wowza IDE.

    However, I suggest simply altering your VLC command. You can specify the port to publish to when using RTP or MPEGTS. Or, with RTSP or RTMP, you can publish directly to a live application by specifying a streamname and bypass the need to worry about ports, and StreamManager altogether. Here is an ffmpeg example:
    ffmpeg -re -i sample.mp4 -c:a copy -c:v copy -f rtsp rtsp://127.0.0.1:1935/live/myStream

  6. #6
    Join Date
    Apr 2012
    Posts
    6

    Default

    Hi,
    The problem is how can I signal wowza so that it will start recording stream that is published from VLC using RTP/TS protocol.

    Wowza records stream only when I play the stream from flash client.

    I was assuming that if manage Streammanager to start receiving the stream, then wowza will also record the stream. I have implemented MediaCaster-API functions to start/stop a stream from your custom Wowza module. But this doesn't work as expected. Even if I programatically start the stream, it doesn't start recording the stream.

    FFmpeg build from http://ffmpeg.zeranoe.com/builds/ doesnot support rtsp . Also ffmpeg cannot read all webcam natively, so I can't use it.

    Also I tried the following, but it doesn't work - [it doesn't record streams]
    - Start publishing from VLC using RTP/TS
    - Using MediaCaster API to start receiving stream
    - Using LiveStreamRecord_2.0 to start recording [using Form LiveStreamRecord/clientHTTP/HTTPLiveStreamRecord.html]

    -----------------------------------
    In my case recording only starts if some flash client is connected, otherwise no recording happen. How can I record the stream even if no flash client is connected ?

    Thanks,
    Sujeet

  7. #7
    Join Date
    Dec 2007
    Posts
    21,962

    Default

    Use StreamType "live" instead of "rtp-live" and use StreamManager to start the stream with MediaCaster type "rtp-record"

    Using LiveStreamRecord should work if the stream is started.

    Richard

  8. #8

    Default

    "In my case recording only starts if some flash client is connected, otherwise no recording happen. How can I record the stream even if no flash client is connected?"

    You use StreamType live instead of rtp-live, and start the stream using MediaCaster API, Stream Manager, or StartupStreams.xml.

    "Even if I programatically start the stream, it doesn't start recording the stream."

    Use StreamType "live-record", or use StreamType "live" with the LiveRecordModule.

    "FFmpeg build from http://ffmpeg.zeranoe.com/builds/ doesnot support rtsp"

    I am quite certain any version of ffmpeg within the last several years supports RTSP.

    "Also ffmpeg cannot read all webcam natively, so I can't use it."

    Webcams are abstracted by the OS as V4L devices in Linux, and Imaging devices in Windows. So, ffmpeg should work. Do you have an example where VLC is able to capture a webcam but ffmpeg cannot?

    Why do you need to support "all" webcams? Why not just your webcam?

    "Also I tried the following, but it doesn't work"

    The scenario you listed I have had working. That is something we can work on if you wish.

    The method you propose seems unnecessary. I suggest using ffmpeg, or FMLE to publish the streams without needing to worry about ports and making a custom module.

Similar Threads

  1. How to see how many client are connected to live stream?
    By littleantz in forum Server Administration Discussion
    Replies: 2
    Last Post: 05-15-2012, 04:49 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •