In my netwrok rtmp is not supported,so i am not able to make rtmp connection.
I tried with rtmpt(ports 80,443)and able to get connected and publish the live stream to FMS(using AS3).
But with in 5 to 6 minutes my proxy server block the streaming.Reason,my proxy can allow only 600 http request per minute from a particular computer(client machine),but while publishing through rtmpt after some time http post request coming form client machine increase the limit of 600 per minute,so proxy block the connection.
I am making my connection like this "rtmpt://xx.yy.zz.kk:80/Training" where xx.yy.zz.kk represent internet IP. Please suggest some turnaround so that in case of rtmpt(http tunelling) http post request will not increase periodically. Regards Nitesh kumar
I am making my connection like this "rtmpt://xx.yy.zz.kk:80/Training" where xx.yy.zz.kk represent internet IP.
Please suggest some turnaround so that in case of rtmpt(http tunelling) http post request will not increase periodically.
I don't think there is any possible workaround to get around this problem because traditionally publish is done via rtmp. But what i want to understand from you that whether you are saying that every minute http request keeps on increasing, i mean it can be case that when publish stops for that minute it crosses 600 request limit. I mean if its keeps on increasing for every minute then its real issue which i dont think might be the case - but do let me know
Thanx for reply. I want to say that when I publish video to the server. The request message is more than 600 per minute for every minutes, which lead to block of http request by the ISA. I think I must be doing some mistake, which leads to such problem. There should be one request for the connection and then for every data frame there should be continuation of that but it should not be new request. I calculated when I publish the video using wireshark is around 15-24 request per second. I have compared the request count with one of the application "openmeeting" which is also using rtmp connection but in our proxy it fails to make connection. Then it tries to make connection using rtmpt and get connected. In this case the request is only ones in a second to our proxy which leads to freely flow of video to the server.
I'm trying to give the architecture of my server and api used to publish the video below.
Tomacat server at port 8080 on same PC with FMS at port 80,1935.
Code snippet to publish at client side is:
serverIP = "rtmpt://22.214.171.124:80/live";
private function onNetStatus(event:NetStatusEvent):void
case "NetConnection.Connect.Success" :
private function publishCamera(camName:String,micIndex:int):void
case "160x120" : m_cam.setMode(160,120,15);
case "320x240" : m_cam.setMode(320,240,15);
case "640x480" : m_cam.setMode(640,480,15);
default : m_cam.setMode(320,240,15);
if(micIndex != -1)
m_mic.codec = SoundCodec.SPEEX;
code snippet at server side is:
application.onConnect = function(myClient,Publisher)
clientObj = myClient;
if(streamObj != null)
trace("streamObj: " + streamObj.name);
trace("clientObj: " + clientObj);
if(streamObj.name == clientObj)
trace("streamObj == clientObj");
trace("streamObj != clientObj");
trace("streamObj is null");
trace(clientObj + "connected with IP: " + clientObj.ip);
trace(Publisher + " get connected");
application.onPublish = function(myClient,myStream)
trace("Live Publish began");
streamObj = myStream;
The difference with rtmp vs. rtmpt is that rtmpt being over http is a request-response model. In order for FMS to send any data to the client, we need to have an http request to piggy back the data on an http response. As such, the client sends "idle" http requests to the server even when it has no data to send in order for the server to have a request it can piggy back a response on if it needs to send data to the client. These idle requests are sent very often so the server doesn't have to wait long to be able to send (possibly urgent) data to the client.
I should also note that the idle posts are less important for a publishing client where data is mostly being sent from client to server. But for subscribing clients, the idle posts would be very important for the server to be able to send data to the clients.
Thanks for Your resposne,I agree with you that rtmpt is as requset/response model.I just want to understand
why after 4 to 5 minutes of publish with rtmpt, my http post request from client machine start increasing and
reaches the max limit set by my isa-proxy server.
What is the max request rate that your proxy server will allow?
Just doing a quick calculation, I'd expect to see http requests somewhere between 120-300/min.
This assumes an "idle" request is sent every 500 msec in the case when there is no data being sent that means 120 requests/min.
Assuming audio packets are sent every 20 msec that means 300 requests/min.
If you're seeing more than that, I'm don't have an immediate answer for you.
My proxy server allow 600 http request/min.I analyze with WireShark (network sniffer tool) that intially http post request from client machine to server are
6/Sec.mean 360/min (fine). but then after some time it start increasing.I just want to understand,who is the culprit,Flash Player,Publishing Code,FMS,Proxy/FireWall.
Well, as I mentioned, FlashPlayer is definitely sending lots of http requests; this is part of the rtmpt protocol. And assuming audio every 20 msec (typically), that only accounts for 300/min. So that is roughly in line with what you saw (360/min). Not sure why after some time this starts increasing. What's your audio sample rate?
You can try using the logLiveStream admin API to enable logging of the incoming msgs for a particular stream to see what the msgs are, and what the timestamps are.
Do do this, enable this admin cmd in Users.xml.
This will enable only logLiveStream cmd via http. Alternatively, you could just allow all cmds via http by changing <Allow>All</Allow>, and <Deny></Deny> (empty).
Publish your stream. Then execute the following cmd from a browser.
replacing "adminserver" with the hostname/ip of the FMS admin server, "live/_definst_" with name of the app/inst you're connecting/publishing to, and "foo" with the name of the stream you're publishing. The mode arg says to log all the msgs that FMS receives in the input side for the specified stream.
This will create a log file in the FMS logs directory and will have a name something like, netstream_x_y.log.
I have tried to write log file as per you. I followed the steps written by you but while executing the code I'm getting error :
<description>loglivestream - No such method found!</description>
<timestamp>9/28/2010 1:12:13 PM</timestamp>