-
Notifications
You must be signed in to change notification settings - Fork 2k
ROS in docker: rviz::RenderSystem: error creating render window: OGRE EXCEPTION(3:RenderingAPIException) #1438
Comments
Are following statements needed for the Dockerfile? ...
ENV NVIDIA_VISIBLE_DEVICES \
${NVIDIA_VISIBLE_DEVICES:-all}
ENV NVIDIA_DRIVER_CAPABILITIES \
${NVIDIA_DRIVER_CAPABILITIES:+$NVIDIA_DRIVER_CAPABILITIES,}graphics
... Here is the ...
docker run \
--shm-size 1024m \
--cap-add=SYS_PTRACE \
--device=/dev/bus/usb \
--device=/dev/snd \
--device=/dev/ttyUSB* \
--device=/dev/video* \
--env="DISPLAY=${DISPLAY}" \
--group-add audio \
--group-add video \
--interactive \
--tty \
--name=${CONTAINER_NAME} \
--gpus all \
--net=host \
--privileged \
--security-opt seccomp=unconfined \
--user sensetime \
--workdir /home/xxx \
--volume=$XSOCK:$XSOCK:rw \
--volume=/etc/timezone:/etc/timezone:ro \
--env="TZ=$(cat /etc/timezone)" \
${MOUNT_WS} \
${MOUNT_DATA} \
--volume /media:/media \
--volume /tmp/today-logs:/tmp/today-logs \
--restart=unless-stopped \
-d ${IMAGE_ID} /bin/bash
... |
Without the That said, I'm not very familiar with running ROS in docker (with our without GPUs). Do you have this same error without GPUs, or is it only specific to when you try and launch it with GPU support? |
Currently we add these 2 ENV as docker run options, rviz can be launched normally. Sorry didn’t try rviz without GPU support. I opened this issue just thought it’s a general one and many friends have met while using ROS. |
Hello mate, I get a very similiar error everytime I try to run rviz.
do you know how I can fix this problem? I have tried several NVIDIA drivers but none of them worked. Right now I am using 340.108. Thanks in advance. |
I've got the similar error launching RViz using docker-compose. Error:
Environment:
In my case, adding the followings to the services:
test:
image: osrf/ros:melodic-desktop-full
command: [ "roslaunch", "urdf_tutorial", "display.launch" ]
+ runtime: nvidia
environment:
DISPLAY: :1
+ NVIDIA_VISIBLE_DEVICES: all
+ NVIDIA_DRIVER_CAPABILITIES: all
volumes:
- "/tmp/.X11-unix:/tmp/.X11-unix:rw" According to the official document, docker-compose requires adding |
Host Machine Version: native Ubuntu 18.04.5 LTS, kernel 5.4.0-54-generic
Docker Version: 19.03.14, build 5eb3275d40
ROS Version: Melodic
The text was updated successfully, but these errors were encountered: