Kurento Docker running in VMWare cannot get remote stream

840 views
Skip to first unread message

kyof...@gmail.com

unread,
Oct 7, 2015, 1:39:15 AM10/7/15
to kurento
As title, I run the kurento docker server in vmware and i couldnt get the remote stream to be shown. The full story is: 
I tried to put the official kurento docker container (https://hub.docker.com/r/kurento/kurento-media-server/) in a VMWware image running RedHat Enterprise (network is bridged). I started the kurento server with command listed in the official website "docker run --name kms -p 8888:8888 -d kurento/kurento-media-server:6.1.0"
And then i tried to test if the server was running by issuing  the command "curl -i -N -H "Connection: Upgrade" -H "Upgrade: websocket" -H "Host: 127.0.0.1:8888" -H "Origin: 127.0.0.1" http://127.0.0.1:8888/kurento" which is also in the website. 

The output is a little bit different, it is:
HTTP/1.1 500 Internal Server Error Server: 
WebSocket++/0.5.1

And the output listed in the website is:
1:8888/kurento 
HTTP/1.1 500 Internal Server Error Server: 
WebSocket++/0.5.1

Anyway, i further checked the debug logs with "docker logs kms". No error message was seen and there was a message showing that the server was started properly.

Next, i started my express.js server and test the kurento docker. everything is set, the kurento client output shows no error too. the client debug info is as follow:

.....
a=rtcp-fb:100 goog-remb
a=rtpmap:116 red/90000
a=rtpmap:117 ulpfec/90000
a=rtpmap:96 rtx/90000
a=fmtp:96 apt=100
a=ssrc-group:FID 897116420 4205752114
a=ssrc:897116420 cname:aEonyHp6G2kc+no0
a=ssrc:897116420 msid:inKWmYUlkvaFc6mBnjLqIjCLxJoJonY02BQ7 7071f0f3-9890-49a0-9e6d-563343c4f4e3
a=ssrc:897116420 mslabel:inKWmYUlkvaFc6mBnjLqIjCLxJoJonY02BQ7
a=ssrc:897116420 label:7071f0f3-9890-49a0-9e6d-563343c4f4e3
a=ssrc:4205752114 cname:aEonyHp6G2kc+no0
a=ssrc:4205752114 msid:inKWmYUlkvaFc6mBnjLqIjCLxJoJonY02BQ7 7071f0f3-9890-49a0-9e6d-563343c4f4e3
a=ssrc:4205752114 mslabel:inKWmYUlkvaFc6mBnjLqIjCLxJoJonY02BQ7
a=ssrc:4205752114 label:7071f0f3-9890-49a0-9e6d-563343c4f4e3

2015-10-02 15:32:08.878 WebRtcPeer.js:165 ICE candidate received
2015-10-02 15:32:08.889 WebRtcPeer.js:165 ICE candidate received
2015-10-02 15:32:08.890 WebRtcPeer.js:165 ICE candidate received
2015-10-02 15:32:08.891 WebRtcPeer.js:165 ICE candidate received
2015-10-02 15:32:09.050 WebRtcPeer.js:218 SDP answer received, setting remote description
2015-10-02 15:32:09.084 WebRtcPeer.js:205 Remote URL: blob:http%3A//10.1.80.227/292b621e-3988-48e2-9a0e-44747a2e0b3b


The client debug info is exactly the same as the one running without docker in Ubuntu (which is working perfectly, able to get remote stream).  The local stream is working properly. 


Thanks for your help.


kyof...@gmail.com

unread,
Oct 7, 2015, 3:45:20 AM10/7/15
to kurento, kyof...@gmail.com
Update:
I further tested the application, the remote stream works sometimes only if i accept sharing video and audio device after few seonds (around 5-8 seconds). 

Patxi Gortázar

unread,
Oct 7, 2015, 1:22:35 PM10/7/15
to kurento, kyof...@gmail.com
I'm a bit confused about your configuration. You say your vmware image is bridged with your host machine, but at the same time you're testing the media server using a port mapping from the vmware image to a local port in the loopback: 127.0.0.1:8888. Later on, you run your express.js application, and I see in the logs the private IP 10.1.80.227. This can make a difference, because when port mappings are used, it may be the case that the UDP connections are not mapped, and hence no media can reach the application. Also, when using a private IP we must ensure there is no NAT involved. Otherwise, you would need to configure a STUN/TURN server.

We need a little more information about your environment to ensure what's going on, concretely:

Could you please post the url connection used in your express.js application? It is ws://127.0.0.1:8888/kurento or ws://10.1.80.227:8888/kurento?

Can you run the docker image locally (directly in your host) and check if your express.js application works by accessing the media-server directly on ws://localhost:8888/kurento?

kyof...@gmail.com

unread,
Oct 7, 2015, 6:37:20 PM10/7/15
to kurento
I am sorry that I missed to mention the website access point and local network configuration.

In my local machine which is running windows OS, uses a VMware to setup a development environment with image of Redhat Enterprise. I host a docker kurento inside the VMware image (the express.js is of course also hosted in the VMware image with port 80). Now i bridge the network of the VMware image to the windows OS. So i access the website in Windows OS with ip 10.1.80.227 (in VMware, i see the ifconfig of eth0 is 10.1.80.227), so the websocket url should be ws://10.0.80.227:8888. as kurento docker server port is 8888

I know it is not secure that I later tried to expose all ports and UDP by running docker kurento with --net=host the application still cannot get the remote stream for most of the time. (It works occasionally if i try to confirm to allow use my camera and audio devices after few seconds)

Patxi Gortázar

unread,
Oct 8, 2015, 1:42:43 PM10/8/15
to kurento, kyof...@gmail.com
From what you say, this is the configuration:
  • kurento is running on docker image with port 8888 exposed to vmware vm and attached to its bridged IP 10.1.80.227 with an option like "-p 10.1.80.227:8888:8888".
  • express.js app is running on the vmware vm on port 10.1.80.227:80
  • Browser is running on the host machine (Windows OS) and accessing the express.js app through IP 10.1.80.227 and port 80, and reaching the media server on IP 10.1.80.227 
It's strange that you can get video in some cases but not in others. It may be a problem with the vmware bridging. Given that the media must traverse two mappings: from the docker image to the vm and from the vm to the bridged network. 

Just to get a deeper insight: 
  • Can you confirm you're starting the docker container with "-p 10.1.80.227:8888:8888"?
  • can you try using a stun server so that we see if there's a problem with the bridging?
  • which browser are you using?
  • when you get media, it works indefinitely or it stops working at some moment?

kyof...@gmail.com

unread,
Oct 8, 2015, 9:45:14 PM10/8/15
to kurento, kyof...@gmail.com

  • You are probably right about the configuration except that i tried running the docker with option "-p 10.1.80.227" but it didn't work and i tried to map everything using option "--net=host". This option as i mentioned before, work occasionally after some delay of accepting to use camera and audio.
  • You reminded me, is there a way to change the kurento docker (https://hub.docker.com/r/kurento/kurento-media-server/) configuration so that i can use a stun server? 
  • Chrome and Firefox updated to latest version
  • works occasionally only if I wait few seconds before clicking accept to allow use of my camera and audio devices

kyof...@gmail.com

unread,
Oct 15, 2015, 5:25:40 AM10/15/15
to kurento, kyof...@gmail.com
Update: without using --net=host option on the docker. client can never get the remote stream. Something is wrong with the UDP settings for the official kurento docker (https://hub.docker.com/r/kurento/kurento-media-server/)
Reply all
Reply to author
Forward
0 new messages