Uploaded image for project: 'Help-Desk'
  1. Help-Desk
  2. HELP-6645

FIWARE.Request.Tech.Kurento-based video recorder produces empty video files..

    Details

    • Type: extRequest
    • Status: Closed
    • Priority: Major
    • Resolution: Done
    • Fix Version/s: 2021
    • Component/s: FIWARE-TECH-HELP
    • Labels:
      None
    • HD-Chapter:
      Data
    • HD-Enabler:
      Kurento

      Description

      Dear FIWARE coach,
      we forward you a support request received from a CreatiFI applicant we are
      not able to solve.
      Please let us know if you need direct contact with the submitter.
      Thanks.

      *************************************
      We are using the Kurento recorder functionality to capture audio/video from
      the users browser. We had the recorder working correctly but after updating
      to v6.4.1~5.g15f6a5f for the server, 6.4.1 for kurento-client & 6.2.0 for
      kurento-utils each video file that is uploaded has a file size of 0 bytes.
      I have granted the user 'kurento' write access on the relevant directories
      as per Andrea Maestrini's instructions but this did not solve our problem.
      I have attached a gist with the client-side code.

      https://gist.github.com/anonymous/504c55321c78e62c54ef49fd3bc102a0

      *************************************

      Since January 1st, old domains won't be supported and messages sent to any domain different to @lists.fiware.org will be lost.
      Please, send your messages using the new domain (Fiware-creatifi-coaching@lists.fiware.org) instead of the old one.
      _______________________________________________
      Fiware-creatifi-coaching mailing list
      Fiware-creatifi-coaching@lists.fiware.org
      https://lists.fiware.org/listinfo/fiware-creatifi-coaching
      [Created via e-mail received from: Andrea Maestrini <amaestrini@create-net.org>]

        Issue Links

          Activity

          Hide
          silviocretti Silvio Cretti added a comment -

          Dear,
          I suggest you to assign the issue to the Kurento owner
          BR

          Show
          silviocretti Silvio Cretti added a comment - Dear, I suggest you to assign the issue to the Kurento owner BR
          Hide
          llopez NaevaTeC Development Team added a comment -

          It looks like the WebRtcEndpoint is not being negotiated in Chrome. It has been advised to check if all UDP ports are open, as only ICE candidates that have ports < 49152 are failing, or so it seems.

          In FF, WebRTC endpoints have been negotiated correctly.

          Show
          llopez NaevaTeC Development Team added a comment - It looks like the WebRtcEndpoint is not being negotiated in Chrome. It has been advised to check if all UDP ports are open, as only ICE candidates that have ports < 49152 are failing, or so it seems. In FF, WebRTC endpoints have been negotiated correctly.
          Hide
          llopez NaevaTeC Development Team added a comment -

          It seems like not all ports are open in the Azure cloud. We advise to open all UDP ports.

          It seems also that the tutorials was not properly set, and can't communicate with the media server. Since browser SPA tutorials require to have WSS enabled in the media server, we encourage the user to switch to a node.js or java based tutorial.
          This is the thread of messaged exchanged so far

          Ah ok. Did you enable WSS in the server then? You should be getting an error in your console if you haven't.

          I'd suggest you use the node or Java versions, as they are easier.

          Ivan Gracia

          On Wed, May 25, 2016 at 12:07 PM, Robert Nolan <robert@vbot.tv> wrote:
          I tried the hello-world JavaScript example. I'm sure it is possible to open a range of ports I just thought it might be easier to limit the range in kms but if that's going to limit the number of concurrent users then that solution won't work. I'll look into opening a range in azure. I wonder would it be a good idea to limit the range to a couple of ports and open them in azure just to test that our instance of kms is working otherwise?

          On Wed, May 25, 2016 at 10:51 AM, Ivan Gracia <igracia@kurento.org> wrote:
          What demo did you try? I've just checked with the hello-world in Java, and it's working in FF. This are the remote candidates sent by the KMS at ws://40.113.159.166:8888/kurento

          Inline image 1Azure is hell. If you limit the number of ports available, you are also limiting the number of concurrent users, as each user requires a couple of UDP ports. There must be a way to config the open ports in Azure by range. Get in touch with their support team and see what they can do. Check also this answer in the list.

          If you want to change the range, you can do so in /etc/kurento/modules/kurento/BaseRtpEndpoint.conf.ini

          Ivan Gracia

          On Wed, May 25, 2016 at 11:37 AM, Robert Nolan <robert@vbot.tv> wrote:
          Hi Ivan,

          So I tested our kms instance this morning with the hello-world example and it's not working in FF or Chrome. There is a STUN server setup in the config file (54.172.47.69:3478). I don't have the exact list of open ports but I can tell you that we are using azure and all ports are closed by default and they need to be opened manually through a GUI one-by-one i.e. a range cannot be specified, so I am assuming the vast majority will be closed so perhaps that is where the problem lies. You mentioned that it is possible to configure kms to limit the range, is this easily done? What effect, if any, will it have on our instance?

          On Tue, May 24, 2016 at 3:18 PM, Ivan Gracia <igracia@kurento.org> wrote:
          Ok. Don't forget to check the open UDP ports in your firewall! Remember that there is a NAT going on there.

          Ivan Gracia

          On Tue, May 24, 2016 at 4:14 PM, Robert Nolan <robert@vbot.tv> wrote:
          Hi Ivan,

          I've switched to using one of the official tutorials. I will do some testing this evening/tomorrow morning to see if our KMS instance is working correctly and I'll get back to you then.

          On Mon, May 23, 2016 at 5:00 PM, Ivan Gracia <igracia@kurento.org> wrote:
          Hi Robert,

          You need to change that in your virtualisation provider's control console. I suppose that's the Fiware-lab console. Please let me know where you are deploying your instance, so I can try and give you a hand.

          I'd suggest that, until we are sure your instance is working, you use one of the official tutorials. I was able to get a WebRTC loopback in FF, but not in Chrome.

          Ivan Gracia

          On Mon, May 23, 2016 at 5:21 PM, Robert Nolan <robert@vbot.tv> wrote:
          Hi Ivan,

          I tested it with FF and I get the same results.
          I will remove the pre-v6 version of KMS later today.
          Below is the list of all open ports on the KMS instance. Let me know if you need any more information.

          Show
          llopez NaevaTeC Development Team added a comment - It seems like not all ports are open in the Azure cloud. We advise to open all UDP ports. It seems also that the tutorials was not properly set, and can't communicate with the media server. Since browser SPA tutorials require to have WSS enabled in the media server, we encourage the user to switch to a node.js or java based tutorial. This is the thread of messaged exchanged so far Ah ok. Did you enable WSS in the server then? You should be getting an error in your console if you haven't. I'd suggest you use the node or Java versions, as they are easier. Ivan Gracia On Wed, May 25, 2016 at 12:07 PM, Robert Nolan <robert@vbot.tv> wrote: I tried the hello-world JavaScript example. I'm sure it is possible to open a range of ports I just thought it might be easier to limit the range in kms but if that's going to limit the number of concurrent users then that solution won't work. I'll look into opening a range in azure. I wonder would it be a good idea to limit the range to a couple of ports and open them in azure just to test that our instance of kms is working otherwise? On Wed, May 25, 2016 at 10:51 AM, Ivan Gracia <igracia@kurento.org> wrote: What demo did you try? I've just checked with the hello-world in Java, and it's working in FF. This are the remote candidates sent by the KMS at ws://40.113.159.166:8888/kurento Inline image 1Azure is hell. If you limit the number of ports available, you are also limiting the number of concurrent users, as each user requires a couple of UDP ports. There must be a way to config the open ports in Azure by range. Get in touch with their support team and see what they can do. Check also this answer in the list. If you want to change the range, you can do so in /etc/kurento/modules/kurento/BaseRtpEndpoint.conf.ini Ivan Gracia On Wed, May 25, 2016 at 11:37 AM, Robert Nolan <robert@vbot.tv> wrote: Hi Ivan, So I tested our kms instance this morning with the hello-world example and it's not working in FF or Chrome. There is a STUN server setup in the config file (54.172.47.69:3478). I don't have the exact list of open ports but I can tell you that we are using azure and all ports are closed by default and they need to be opened manually through a GUI one-by-one i.e. a range cannot be specified, so I am assuming the vast majority will be closed so perhaps that is where the problem lies. You mentioned that it is possible to configure kms to limit the range, is this easily done? What effect, if any, will it have on our instance? On Tue, May 24, 2016 at 3:18 PM, Ivan Gracia <igracia@kurento.org> wrote: Ok. Don't forget to check the open UDP ports in your firewall! Remember that there is a NAT going on there. Ivan Gracia On Tue, May 24, 2016 at 4:14 PM, Robert Nolan <robert@vbot.tv> wrote: Hi Ivan, I've switched to using one of the official tutorials. I will do some testing this evening/tomorrow morning to see if our KMS instance is working correctly and I'll get back to you then. On Mon, May 23, 2016 at 5:00 PM, Ivan Gracia <igracia@kurento.org> wrote: Hi Robert, You need to change that in your virtualisation provider's control console. I suppose that's the Fiware-lab console. Please let me know where you are deploying your instance, so I can try and give you a hand. I'd suggest that, until we are sure your instance is working, you use one of the official tutorials. I was able to get a WebRTC loopback in FF, but not in Chrome. Ivan Gracia On Mon, May 23, 2016 at 5:21 PM, Robert Nolan <robert@vbot.tv> wrote: Hi Ivan, I tested it with FF and I get the same results. I will remove the pre-v6 version of KMS later today. Below is the list of all open ports on the KMS instance. Let me know if you need any more information.
          Hide
          silviocretti Silvio Cretti added a comment -

          Dear FIWARE expert,
          I know that you are in contact with the applicants and you are trying to fix the issue asap.
          What 's going on with the issue?
          BR

          Show
          silviocretti Silvio Cretti added a comment - Dear FIWARE expert, I know that you are in contact with the applicants and you are trying to fix the issue asap. What 's going on with the issue? BR
          Hide
          llopez NaevaTeC Development Team added a comment -

          We haven't had any news since a couple of days. We've requested to have access to a live demo, to check their code, to see if there's something wrong. Also, there were some deployment issued that should be fixed by now, but we don't know the status of that. I'm attaching the thread, and Andrea Maestrini is also aware (cc-ed)

          >>>>>>>>>>>>>>>>>>>>>>>

          Hi Robert, did you check the logs?

          Ivan Gracia

          On Mon, May 30, 2016 at 5:14 PM, Ivan Gracia <igracia@kurento.org> wrote:
          If it fails, it is because the WSS is not correctly enabled in the media server. Could you please check the logs?

          Ivan Gracia

          On Mon, May 30, 2016 at 4:42 PM, Robert Nolan <robert@vbot.tv> wrote:
          I had already tried visiting https://40.113.159.166:8433/kurento but the connection fails. I also read the documentation in full and followed it, I am using a signed-certificate so according to the documentation all that is required is editing the config file, which I have done.

          On Mon, May 30, 2016 at 3:31 PM, Ivan Gracia <igracia@kurento.org> wrote:
          It doesn't matter if it's your own code or the tutorials. If you are using JS, you need to access the url of the KMS and accept also the WSS certificates there. Just visit this address https://40.113.159.166:8433/kurento

          Also, it seems like WSS is not correctly configured. Please read the documentation on that. In there, apart from how to configure the secure websocket port, it says this

          Browser applications: You’ll need to manually accept the certificate as trusted one before secure WebSocket connections can be established. By default, this can be done by connecting to connecting to https://localhost:8433/kurento and accepting the certificate in the browser.
          Do read carefully the documentation, or this process can be endless.

          I can't help you with Azure, sorry! In any case, UDP ports are closed there. Unless you don't figure that out, it will never work. Again, let me encourage you to move your solution to the FIWARE lab, which is a more friendly environment. You'll also get the images there for KMS.

          P.S. I'm adding Andrea to the conversation so he's aware of the progress. I forgot to do that earlier.

          Ivan Gracia

          On Mon, May 30, 2016 at 4:16 PM, Robert Nolan <robert@vbot.tv> wrote:
          I'm never asked to accept the certificates. I'm not sure if we'll be able to move away from Azure, I'll have to discuss that with my colleagues. I'm no longer using the JS tutorials, that error message is from our own JavaScript implementation but I've run the Java hello-world example and it also fails with the following error:
          [KurentoClient] Error sending heartbeat to server. Exception: [KurentoClient] Exception connecting to WebSocket server wss://40.113.159.166:8433/kurento

          On Mon, May 30, 2016 at 3:06 PM, Ivan Gracia <igracia@kurento.org> wrote:
          Did you accept the certificates in the browser? You need to connect to the KMS url through the secure port to accept those.

          For making your life incredibly easier I would suggest:
          Running from Azure: it might be cheaper, but cheaper means shittier. Managing ports is hell there. You are with FIWARE, use the FIWARE-lab!
          Don't use the JS tutorials. You'll keep forgetting that you need to accept the certificates for WSS in your browser too.
          Cheers,

          Ivan Gracia

          On Mon, May 30, 2016 at 4:03 PM, Robert Nolan <robert@vbot.tv> wrote:
          Hi Ivan,

          I've tried to connect to the correct port but the connection is denied:

          WebSocket connection to 'wss://40.113.159.166:8433/kurento' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED

          I have the secure port set in the config file on the kms machine to 8433 and a cert is provided. I've tried to run the Hello-world Java example and it fails also. Any idea what the problem might be?

          On Thu, May 26, 2016 at 11:26 AM, Ivan Gracia <igracia@kurento.org> wrote:
          The port is different. Check the documentation to see which configuration you have to change.

          Ivan Gracia

          On Thu, May 26, 2016 at 12:25 PM, Robert Nolan <robert@vbot.tv> wrote:
          I'll try to get a demo available to you shortly. Maybe you could help me with securing the kms also? I have added a certificate to /etc/kurento/kurento.conf.json but I cannot connect, I get the following error -
          WebSocket connection to 'wss://40.113.159.166:8888/kurento' failed: Error in connection establishment: net::ERR_CONNECTION_CLOSED

          Show
          llopez NaevaTeC Development Team added a comment - We haven't had any news since a couple of days. We've requested to have access to a live demo, to check their code, to see if there's something wrong. Also, there were some deployment issued that should be fixed by now, but we don't know the status of that. I'm attaching the thread, and Andrea Maestrini is also aware (cc-ed) >>>>>>>>>>>>>>>>>>>>>>> Hi Robert, did you check the logs? Ivan Gracia On Mon, May 30, 2016 at 5:14 PM, Ivan Gracia <igracia@kurento.org> wrote: If it fails, it is because the WSS is not correctly enabled in the media server. Could you please check the logs? Ivan Gracia On Mon, May 30, 2016 at 4:42 PM, Robert Nolan <robert@vbot.tv> wrote: I had already tried visiting https://40.113.159.166:8433/kurento but the connection fails. I also read the documentation in full and followed it, I am using a signed-certificate so according to the documentation all that is required is editing the config file, which I have done. On Mon, May 30, 2016 at 3:31 PM, Ivan Gracia <igracia@kurento.org> wrote: It doesn't matter if it's your own code or the tutorials. If you are using JS, you need to access the url of the KMS and accept also the WSS certificates there. Just visit this address https://40.113.159.166:8433/kurento Also, it seems like WSS is not correctly configured. Please read the documentation on that. In there, apart from how to configure the secure websocket port, it says this Browser applications: You’ll need to manually accept the certificate as trusted one before secure WebSocket connections can be established. By default, this can be done by connecting to connecting to https://localhost:8433/kurento and accepting the certificate in the browser. Do read carefully the documentation, or this process can be endless. I can't help you with Azure, sorry! In any case, UDP ports are closed there. Unless you don't figure that out, it will never work. Again, let me encourage you to move your solution to the FIWARE lab, which is a more friendly environment. You'll also get the images there for KMS. P.S. I'm adding Andrea to the conversation so he's aware of the progress. I forgot to do that earlier. Ivan Gracia On Mon, May 30, 2016 at 4:16 PM, Robert Nolan <robert@vbot.tv> wrote: I'm never asked to accept the certificates. I'm not sure if we'll be able to move away from Azure, I'll have to discuss that with my colleagues. I'm no longer using the JS tutorials, that error message is from our own JavaScript implementation but I've run the Java hello-world example and it also fails with the following error: [KurentoClient] Error sending heartbeat to server. Exception: [KurentoClient] Exception connecting to WebSocket server wss://40.113.159.166:8433/kurento On Mon, May 30, 2016 at 3:06 PM, Ivan Gracia <igracia@kurento.org> wrote: Did you accept the certificates in the browser? You need to connect to the KMS url through the secure port to accept those. For making your life incredibly easier I would suggest: Running from Azure: it might be cheaper, but cheaper means shittier. Managing ports is hell there. You are with FIWARE, use the FIWARE-lab! Don't use the JS tutorials. You'll keep forgetting that you need to accept the certificates for WSS in your browser too. Cheers, Ivan Gracia On Mon, May 30, 2016 at 4:03 PM, Robert Nolan <robert@vbot.tv> wrote: Hi Ivan, I've tried to connect to the correct port but the connection is denied: WebSocket connection to 'wss://40.113.159.166:8433/kurento' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED I have the secure port set in the config file on the kms machine to 8433 and a cert is provided. I've tried to run the Hello-world Java example and it fails also. Any idea what the problem might be? On Thu, May 26, 2016 at 11:26 AM, Ivan Gracia <igracia@kurento.org> wrote: The port is different. Check the documentation to see which configuration you have to change. Ivan Gracia On Thu, May 26, 2016 at 12:25 PM, Robert Nolan <robert@vbot.tv> wrote: I'll try to get a demo available to you shortly. Maybe you could help me with securing the kms also? I have added a certificate to /etc/kurento/kurento.conf.json but I cannot connect, I get the following error - WebSocket connection to 'wss://40.113.159.166:8888/kurento' failed: Error in connection establishment: net::ERR_CONNECTION_CLOSED
          Hide
          llopez NaevaTeC Development Team added a comment - - edited

          The platform on which they are deploying does not allow to open a range of UDP ports. Since media goes through UDP, there's not much more we can do, except advise them to switch to a more friendly platform. We've provided the developers with a guide on how to open port ranges in Azure, that we had for internal use based on some 2 year old experiments.

          I don't see there's much more we can do to help them, as we have no control over the virtualisation provider the server is deployed in. I will proceed and close the issue, and will open it again should we get more info on the matter.

          Here are the remaining messages exchanged.
          >>>>>>>>>>>>>>>>>>>

          Hi Robert,

          If there's nothing else we can help you with, I will proceed to close the issue in JIRA. Please do let me know!

          Cheers,

          Ivan Gracia

          On Thu, Jun 2, 2016 at 11:10 AM, Robert Nolan <robert@vbot.tv> wrote:
          I had already checked the line endings and the certificate does have the correct header and footer so unfortunately that's not the problem. I will remove Coturn and try limiting the ports in the BaseRtpEndpoint.conf.ini file instead. Thanks for the pdf, I will have a look at it and see if we can get the full range of ports opened.

          On Thu, Jun 2, 2016 at 9:49 AM, Ivan Gracia <igracia@kurento.org> wrote:
          It got attached twice, sorry!

          Check also if your certificate has these lines

          ----BEGIN CERTIFICATE----
          your certificate goes here
          ----END CERTIFICATE----

          Ivan Gracia

          On Thu, Jun 2, 2016 at 10:38 AM, Ivan Gracia <igracia@kurento.org> wrote:
          Strange about the certificate. I've done some searching, and there might be the possibility that the certificate got "corrupted" if you opened it in windows. Check this Stackoverflow answer, to see if that was the case.

          Limiting the number of ports can be done by setting the maximum and minimum values in /etc/kurento/modules/kurento/BaseRtpEndpoint.conf.ini. I would left Coturn out of the equation for now, as it's another thing that can go wrong

          In any case, your main issue is getting those ports open. Just in case it helps, this is a test I did with Azure a couple of years ago, and managed to get all ports open. You can't do it in their console, though. It's crap!

          Ivan Gracia

          On Thu, Jun 2, 2016 at 10:20 AM, Robert Nolan <robert@vbot.tv> wrote:
          Hi Ivan,

          Yes I checked the logs, there was a permissions error regarding the cert. Got that sorted but it I hit a "no start line" error for the cert itself which I couldn't resolve. I removed ssl altogether for the time being and set up Coturn on the server so I could limit the number of ports as opening the required number of ports is just not possible but it is not behaving as expected.

          On Wed, Jun 1, 2016 at 2:36 PM, Ivan Gracia <igracia@kurento.org> wrote:
          By the way, if you are using a Java or Node.js tutorial, you don't need to secure the WSS connection. You can connect directly to ws://40.113.159.166:8888/kurento and no need to do anything with certificates.

          Ivan Gracia

          Show
          llopez NaevaTeC Development Team added a comment - - edited The platform on which they are deploying does not allow to open a range of UDP ports. Since media goes through UDP, there's not much more we can do, except advise them to switch to a more friendly platform. We've provided the developers with a guide on how to open port ranges in Azure, that we had for internal use based on some 2 year old experiments. I don't see there's much more we can do to help them, as we have no control over the virtualisation provider the server is deployed in. I will proceed and close the issue, and will open it again should we get more info on the matter. Here are the remaining messages exchanged. >>>>>>>>>>>>>>>>>>> Hi Robert, If there's nothing else we can help you with, I will proceed to close the issue in JIRA. Please do let me know! Cheers, Ivan Gracia On Thu, Jun 2, 2016 at 11:10 AM, Robert Nolan <robert@vbot.tv> wrote: I had already checked the line endings and the certificate does have the correct header and footer so unfortunately that's not the problem. I will remove Coturn and try limiting the ports in the BaseRtpEndpoint.conf.ini file instead. Thanks for the pdf, I will have a look at it and see if we can get the full range of ports opened. On Thu, Jun 2, 2016 at 9:49 AM, Ivan Gracia <igracia@kurento.org> wrote: It got attached twice, sorry! Check also if your certificate has these lines ---- BEGIN CERTIFICATE ---- your certificate goes here ---- END CERTIFICATE ---- Ivan Gracia On Thu, Jun 2, 2016 at 10:38 AM, Ivan Gracia <igracia@kurento.org> wrote: Strange about the certificate. I've done some searching, and there might be the possibility that the certificate got "corrupted" if you opened it in windows. Check this Stackoverflow answer, to see if that was the case. Limiting the number of ports can be done by setting the maximum and minimum values in /etc/kurento/modules/kurento/BaseRtpEndpoint.conf.ini. I would left Coturn out of the equation for now, as it's another thing that can go wrong In any case, your main issue is getting those ports open. Just in case it helps, this is a test I did with Azure a couple of years ago, and managed to get all ports open. You can't do it in their console, though. It's crap! Ivan Gracia On Thu, Jun 2, 2016 at 10:20 AM, Robert Nolan <robert@vbot.tv> wrote: Hi Ivan, Yes I checked the logs, there was a permissions error regarding the cert. Got that sorted but it I hit a "no start line" error for the cert itself which I couldn't resolve. I removed ssl altogether for the time being and set up Coturn on the server so I could limit the number of ports as opening the required number of ports is just not possible but it is not behaving as expected. On Wed, Jun 1, 2016 at 2:36 PM, Ivan Gracia <igracia@kurento.org> wrote: By the way, if you are using a Java or Node.js tutorial, you don't need to secure the WSS connection. You can connect directly to ws://40.113.159.166:8888/kurento and no need to do anything with certificates. Ivan Gracia

            People

            • Assignee:
              llopez NaevaTeC Development Team
              Reporter:
              fw.ext.user FW External User
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: