webRTC crashed when a client browser connects

  • Target: AGX Orin devkit 64GB

    JetPack: 6.2.1 (L4T: 36.4.4)

  • Jetson-utils: src from git and build/install

  • issue: webRTC makes some problem and crash when a client browser connects

While Text+Vision example (Live Streaming) is running, if a client web browser connect to the webRTC server, it fails with following errors, and the docker container is terminated:

Further logs are attached.

Thanks,

error logs_webRTC.txt (13.4 KB)

*** Please note that this reply is generated by LLM automatically ***

Based on the provided context, it appears that you are experiencing issues with WebRTC on a Jetson AGX Orin devkit with 64GB of memory, running JetPack 6.2.1, L4T 36.4.4, and Jetsonutils built from the git source.

The problem occurs when a client web browser connects to the WebRTC server while the TextVision example Live Streaming is running. The error logs indicate that the docker container is terminated, and the WebRTC connection fails.

To address this issue, I would recommend the following steps:

  1. Verify WebRTC configuration: Ensure that the WebRTC configuration is correct and compatible with the Jetson AGX Orin devkit. Check the WebRTC settings, such as the codec, bitrate, and resolution, to ensure they are suitable for the device.
  2. Check Jetsonutils version: Verify that the Jetsonutils version is compatible with the JetPack and L4T versions. You can check the Jetsonutils version by running the command jetson-utils --version.
  3. Update Jetsonutils: If the Jetsonutils version is outdated, update it to the latest version using the command git pull and then rebuild and reinstall it.
  4. Disable Hardware Acceleration: Try disabling hardware acceleration in the WebRTC settings to see if it resolves the issue. This can be done by setting the enable_hardware_acceleration flag to false in the WebRTC configuration.
  5. Check Docker container configuration: Verify that the Docker container configuration is correct, and the container has sufficient resources (e.g., memory, CPU) to run the WebRTC application.
  6. Monitor system logs: Monitor the system logs to identify any potential issues or errors that may be causing the WebRTC connection to fail.
  7. Test with a different WebRTC example: Try running a different WebRTC example, such as the webrtc-peerconnection example, to see if the issue is specific to the TextVision example.

In comparison to other Jetson devices, the AGX Orin devkit has a more powerful GPU and CPU, which should provide better performance for WebRTC applications. However, the issue may be specific to the TextVision example or the WebRTC configuration.

To further troubleshoot the issue, you can try:

  • Checking the WebRTC documentation for any known issues or limitations on the Jetson AGX Orin devkit.
  • Searching for similar issues on the NVIDIA forums or other online communities.
  • Providing more detailed error logs or system information to help identify the root cause of the issue.

By following these steps, you should be able to identify and resolve the issue with WebRTC on your Jetson AGX Orin devkit.

*** Please give the thumbs up if you get answers you like. Or provide feedback to help us improve the answer. ***

Hi,
The jetson-utils stack is no longer maintained, so it may not work properly if you run any application on the basis of the stack . Would suggest looks for other WebRTC solutions.

Thanks @DaneLLL @carolyuu ,

Jetson AI Lab’s tutorials use jetson-utils based webRTC for video streaming.

@dusty_nv , which stack I should use instead of jetson-utils?

Hi,

Thanks for your patience.

We would like to check this issue locally.
Could you share the command that can trigger the error?

Thansk.

Hi @AastaLLL,

Apologize to my late answer.

Command to reproduce the error is Jetson AI Lab’s NanoVLM case,

especially Live Streaming:

jetson-containers run $(autotag nano_llm) 
python3 -m nano_llm.agents.video_query --api=mlc 
–model Efficient-Large-Model/VILA1.5-3b 
–max-context-len 256 
–max-new-tokens 32 
–video-input /dev/video0 
–video-output webrtc://@:8554/output


I will make clean my target and try it again.

Thanks,

Hi,
Please install the packages for a try:

$ sudo apt install libgstrtspserver-1.0-0 libgstrtspserver-1.0-dev libglew-dev libsoup2.4-dev libjson-glib-dev gstreamer1.0-nice

For further issues please enable the log and see if any warning messages are printed:

$ export GST_DEBUG=*webrtc*:5

When using Chromium browser, may also need to disable #enable-webrtc-hide-local-ips-with-mdns

  1. Open chrome://flags/
  2. Disable Anonymize local IPs exposed by WebRTC.
  3. Re-launch the browser

Hi @DaneLLL,

Gstreamer pkgs are installed and debug mode enabled.

A chrome flag was disabled as well .

When I connect to the live streaming AGX Orin, the agent stops with some error messages as follow:

Attach screenshot and logs.

Thanks,

log_NanoVLM_webrtc.txt (11.1 KB)

Hi,
Please remove the cache and check if nicesrc and nicesink plugins are present:

root@tegra-ubuntu:/# rm /root/.cache/gstreamer-1.0/registry.aarch64.bin
root@tegra-ubuntu:/# gst-inspect-1.0 nicesrc
root@tegra-ubuntu:/# gst-inspect-1.0 nicesink

If gstreamer1.0-nice is installed, the nullptr error should disappear.

It was!

Thanks @DaneLLL,

BTW, Jetson AI Lab’s many comments should be updated.

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.