Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem with the docker during the gazebo launching #11

Open
DavideAntonucci opened this issue Sep 23, 2020 · 9 comments
Open

Problem with the docker during the gazebo launching #11

DavideAntonucci opened this issue Sep 23, 2020 · 9 comments

Comments

@DavideAntonucci
Copy link
Collaborator

​​​​​​​Hi @alaurenzi ,

I've a problem with the docker when I launch gazebo for this reason:

image

@alaurenzi
Copy link
Collaborator

Hi @DavideAntonucci, can you list the exact steps leading to the error?

@DavideAntonucci
Copy link
Collaborator Author

Hi @alaurenzi ,

  1. I've installed the docker and followed the Post-installation steps for Linux, ONLY this one: Manage Docker as a non-root user.
  2. ./docker/run.sh runs the container.
  3. I tried to launch gazebo as you can see in the first comment. I did this because, ./start.sh (starts roscore and but NOT gazebo).

@alaurenzi
Copy link
Collaborator

alaurenzi commented Sep 23, 2020

Unfortunately it looks like an incompatibilty issue with your video drivers.. I cannot reproduce the issue on either of my machines. Did you try

  • to mount your nvidia drivers onto the guest machine as described here (requires editing run.sh and exporting some env variables)
  • to install the nvidia drivers directly on the guest machine as reported here?

Alternatively, you should be able to run just the gazebo backend (replace gazebo with gzserver in the start.sh script). A web frontend server is run by the start.sh script, and should be accessible at localhost:8080 on the host machine.

@DavideAntonucci
Copy link
Collaborator Author

Unfortunately, for this point:

Alternatively, you should be able to run just the gazebo backend (replace gazebo with gzserver in the start.sh script). A web frontend server is run by the start.sh script, and should be accessible at localhost:8080 on the host machine.

I cannot run gzserver for this reason:
libGL error: failed to load driver: swrast.

Moreover, I cannot reach the localhost:8080, it seems that the docker doesn't have internet connection, How I can resolve it?

@alaurenzi
Copy link
Collaborator

Without gzserver, the gzweb probably won't open the connection, probably that's why you can't see anything in the browser.

@torydebra
Copy link
Member

torydebra commented Sep 24, 2020

Same identical problem here, with same steps followed.

  • to mount your nvidia drivers onto the guest machine as described here (requires editing run.sh and exporting some env variables)

With this, nothing change for me

I tried to enter docker as root (adding --user root \ in the run.sh) and installing drivers as described above (apt update && apt install -y nvidia-340 mesa-utils && glxgears).
The problem is not present anymore, but I have this one:

root@72e5d933423d:/home/user# gazebo
No protocol specified
ALSA lib confmisc.c:767:(parse_card) cannot find card '0'
ALSA lib conf.c:4732:(_snd_config_evaluate) function snd_func_card_driver returned error: No such file or directory
ALSA lib confmisc.c:392:(snd_func_concat) error evaluating strings
ALSA lib conf.c:4732:(_snd_config_evaluate) function snd_func_concat returned error: No such file or directory
ALSA lib confmisc.c:1246:(snd_func_refer) error evaluating name
ALSA lib conf.c:4732:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
ALSA lib conf.c:5220:(snd_config_expand) Evaluate error: No such file or directory
ALSA lib pcm.c:2642:(snd_pcm_open_noupdate) Unknown PCM default
AL lib: (EE) ALCplaybackAlsa_open: Could not open playback device 'default': No such file or directory
No protocol specified
No protocol specified

@alaurenzi
Copy link
Collaborator

Maybe related: jessfraz/dockerfiles#6

@torydebra
Copy link
Member

Maybe related: jessfraz/dockerfiles#6

I tried xhost local:docker and its variants, before running the docker image and after, nothing.

@torydebra
Copy link
Member

torydebra commented Sep 24, 2020

... I have this one:

root@72e5d933423d:/home/user# gazebo
No protocol specified
ALSA lib confmisc.c:767:(parse_card) cannot find card '0'
ALSA lib conf.c:4732:(_snd_config_evaluate) function snd_func_card_driver returned error: No such file or directory
ALSA lib confmisc.c:392:(snd_func_concat) error evaluating strings
ALSA lib conf.c:4732:(_snd_config_evaluate) function snd_func_concat returned error: No such file or directory
ALSA lib confmisc.c:1246:(snd_func_refer) error evaluating name
ALSA lib conf.c:4732:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
ALSA lib conf.c:5220:(snd_config_expand) Evaluate error: No such file or directory
ALSA lib pcm.c:2642:(snd_pcm_open_noupdate) Unknown PCM default
AL lib: (EE) ALCplaybackAlsa_open: Could not open playback device 'default': No such file or directory
No protocol specified
No protocol specified

I am almost sure that I does not have change anything, but this error does not happen anymore.
Instead, a new one is there:

user@3a659e4ca877:~$ gazebo
X Error of failed request:  BadValue (integer parameter out of range for operation)
  Major opcode of failed request:  154 (GLX)
  Minor opcode of failed request:  3 (X_GLXCreateContext)
  Value in failed request:  0x0
  Serial number of failed request:  19
  Current serial number in output stream:  20

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants