Skip to content
This repository has been archived by the owner on Jun 8, 2023. It is now read-only.

Error in launching Rviz from Autoware Docker #359

Closed
KetkiChaudhary opened this issue Oct 17, 2018 · 16 comments
Closed

Error in launching Rviz from Autoware Docker #359

KetkiChaudhary opened this issue Oct 17, 2018 · 16 comments

Comments

@KetkiChaudhary
Copy link

Fill-out only one section depending on whether you are reporting a bug or a new feature.

Bug

Unable to run Rviz from the Runtime Manager.

So, I have installed Autoware using the docker method as described in:
https://github.com/CPFL/Autoware/wiki/Generic-x86-Docker

Now, when I try to run the demo ( as per : https://github.com/CPFL/Autoware-Manuals/blob/master/en/Autoware_QuickStart_v1.1.pdf ), I get stuck at the step 3.2 where I try and launch Rviz from the runtime manager.
I get the following error:

[ INFO] [1539583851.181537990]: rviz version 1.12.16
[ INFO] [1539583851.181578002]: compiled against Qt version 5.5.1
[ INFO] [1539583851.181587881]: compiled against OGRE version 1.9.0 (Ghadamon)
libGL error: No matching fbConfigs or visuals found
libGL error: failed to load driver: swrast
Could not initialize OpenGL for RasterGLSurface, reverting to RasterSurface.
libGL error: No matching fbConfigs or visuals found
libGL error: failed to load driver: swrast
/home/autoware/Autoware/ros/src/util/packages/runtime_manager/../../../.config/rviz/cmd.sh: line 44: 2362 Segmentation fault (core dumped) rosrun rviz rviz

Note: I have both Docker CE and Nvidia docker installed and am using Nvidia GTX 1080.

Expected Behavior

Rviz should launch successfully.

Specifications

  • Ubuntu version: 16.04
  • ROS version: kinetic
  • Autoware branch: master, v1.7
@ajay1606
Copy link

ajay1606 commented Nov 2, 2018

I am also having the problem with Launching RVIZ in autoware Docker.
I am using the following:

Graphics card: NVIDIA GeForce GTX 1070
Ubuntu version: 16.04
ROS version: kinetic
Autoware branch: master, v1.7
Nvidia Driver Version: 410.73
CUDA Version: 10.0

could anyone help to fix this issue?

@RomanDmowski
Copy link

Did you install nvidia-docker1 or nvidia-docker2? Nvidia-docker2 requires libglvnd (GL Vendor-Neutral Dispatch library) to be installed inside the image to get OpenGL calls working correctly. Probably Autoware docker doesn't have OpenGL installed inside so it can't work with nvidia-docker2. See details here: http://wiki.ros.org/docker/Tutorials/Hardware%20Acceleration

@ajay1606
Copy link

ajay1606 commented Nov 5, 2018

Thanks for your reply,
Yes you are right i am using NVIDIA-Docker2:
But, I didn't understand one thing, Currently, I have autoware docker file.
According to the link, Do I edit existing docker file or create a new file?

@RomanDmowski
Copy link

I didn't try this solution (to rebuild Autoware docker).
There are other options:

I tried a lot of solution and after a few days I decided not to use docker images. I built Autoware from source. And it works.

@mdemirst
Copy link

mdemirst commented Nov 5, 2018

I had the same issue, too. It is related to using nvidia-docker2. There is an open PR to solve this problem.

autowarefoundation/autoware#1416

Steps: Replace build.sh and run.sh files (+ created Dockerfile.nvidia-docker-v2) with the ones in the PR. or just merge PR into your branch.

@ajay1606
Copy link

ajay1606 commented Nov 6, 2018

I had the same issue, too. It is related to using nvidia-docker2. There is an open PR to solve this problem.

autowarefoundation/autoware#1416

Steps: Replace build.sh and run.sh files (+ created Dockerfile.nvidia-docker-v2) with the ones in the PR. or just merge PR into your branch.

Thank you so much for your kind response. Much appreciated. it worked for me.

@yuqli
Copy link

yuqli commented Nov 12, 2018

After modifying the changes provided in the PR, when rebuiding autoware I saw this error:

/bin/bash: line 0: cd: /home/autoware/Autoware/ros/src: No such file or directory
fatal: Not a git repository (or any of the parent directories): .git
Could neither symlink nor copy file "/opt/ros/kinetic/share/catkin/cmake/toplevel.cmake" to "/CMakeLists.txt":
- [Errno 13] Permission denied
- [Errno 13] Permission denied: '/CMakeLists.txt'/bin/bash: ./catkin_make_release: No such file or directory
The command '/bin/sh -c /bin/bash -c 'source /opt/ros/kinetic/setup.bash; cd /home/$USERNAME/Autoware/ros/src; git submodule update --init --recursive; catkin_init_workspace; cd ../; ./catkin_make_release'' returned a non-zero code: 127
Sending build context to Docker daemon  17.41kB
Step 1/10 : ARG FROM_ARG
Step 2/10 : FROM ${FROM_ARG}
pull access denied for autoware-kinetic, repository does not exist or may require 'docker login'

Anyone has seen this error before and can kindly points out why? Thanks!

@ajay1606
Copy link

Hello Yugli, did you tried command with $sudo ?? this seems to access permission, So just try adding sudo

@yuqli
Copy link

yuqli commented Nov 13, 2018

@ajay1606 Thanks for the reply. I did used sudo. This is the command I run:

sudo sh build.sh kinetic nvidia

It seems there are actually two errors:

  • [Errno 13] Permission denied: '/CMakeLists.txt'/bin/bash: ./catkin_make_release: No such file or directory
  • pull access denied for autoware-kinetic, repository does not exist or may require 'docker login'

The second error I later found out is this issue: the error is also "kinetic image cannot find". I also did not change the autoware version tag as suggested in the official installation guide

Modifying the run.sh file in this pull request, change the docker build command to docker build --build-arg FROM_ARG=autoware/autoware:latest-kinetic -t autoware-$1-$2 -f Dockerfile.nvidia-docker-v2 . solves the second issue.

I am still looking into the first issue.

@yuqli
Copy link

yuqli commented Nov 13, 2018

@ajay1606 I also directly pull the PR and merged to my local branch. Do I need to modify other configurations? I'm very new to autoware / ros / github and it took me a while to figure out how to get that PR to my local repo..

@yuqli
Copy link

yuqli commented Nov 13, 2018

Still have not resolve the first error (Permission denied) I had, but rviz is running now in docker. Thanks!

@ajay1606
Copy link

Hello Yuqli,
I understood your issue, Seems you have not downloaded the image.
Even I also got same errors in the first time. Later I followed the link below to download the image.
http://ai4sig.org/2018/07/docker-for-autoware/
Try this steps to download the image.
Good luck :)

@twbabyduck
Copy link

twbabyduck commented Jan 3, 2019

Hi,
Here is the link to docker image for autoware (1.9.1-kinetic) with OpenGL support
The error of launching RVIZ should be fixed now : )

You can simply just docker pull the image for testing

docker pull twbabyduck/autoware:1.9.1-kinetic-opengl

@yaozhai
Copy link

yaozhai commented Jan 13, 2019

Still have not resolve the first error (Permission denied) I had, but rviz is running now in docker. Thanks!

Exactly the same issue here.

@RomanDmowski
Copy link

RomanDmowski commented Feb 17, 2019

Here you can find the list of all necessary steps to install Autoware with version 2.0 of NVIDIA Docker Plugin and Docker Image based on the image prepared by user twbabyduck: https://icave2.cse.buffalo.edu/AutowareInstallation.htm

@amc-nu
Copy link
Member

amc-nu commented Feb 23, 2019

As for release 1.10. Nvidia Docker v1 is the preferred method.
Like some of you have kindly pointed out, the current Autoware image does not contain OpenGL files, therefore will cause errors when using nvidia-docker2
Version 1.11 will address this issue, this is being worked out in this PR: If you are interested, you try to pull and test: autowarefoundation/autoware#1946
As a side note, in our tests, nvidia-docker2 works well only on Optimus laptops ,where OpenGL is not installed.
Thank you everyone for all the provided solutions.

@amc-nu amc-nu closed this as completed Feb 23, 2019
@mitsudome-r mitsudome-r transferred this issue from autowarefoundation/autoware Mar 14, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants