Ask Your Question
0

Gazebo for Noetic not working in WSL

asked 2020-12-07 09:06:33 -0500

Morris gravatar image

updated 2020-12-08 05:49:04 -0500

I did a clean install of Noetic in Ubuntu 20.04 on WSL 2. This installs Gazebo 11, but Gazebo does not run when I type:

gazebo

Other X11 utilities like xeyes work fine in WSL, so the X-Server and DISPLAY are fine. I also went to the official Gazebo page: http://gazebosim.org/tutorials?tut=in..., and followed those directions, which just confirmed that I already have the latest version of Gazebo.

Has anyone gotten Gazebo working with Noetic in WSL2?

edit retag flag offensive close merge delete

Comments

Has anyone gotten Gazebo working with Noetic?

Shouldn't the question be: "has anyone gotten Gazebo (in Noetic) working on WSL2"?

If Gazebo didn't work in Noetic, I assume ROS Answers would be full of posts about it not working.

gvdhoorn gravatar image gvdhoorn  ( 2020-12-07 09:26:16 -0500 )edit

I would have thought so. But I would also expect that after uninstalling Noetic and Gazebo, and doing a clean install it would just work, but it doesn't.

Morris gravatar image Morris  ( 2020-12-07 09:37:54 -0500 )edit

But I would also expect that after uninstalling Noetic and Gazebo, and doing a clean install it would just work, but it doesn't.

I'm not sure what you mean by this.

Gazebo is a rather heavy 3D application making use of OpenGL. Regular X applications are not. Comparing xeyes to Gazebo isn't really useful, as the former doesn't come close to the complexity in the graphics pipeline of the latter.

gvdhoorn gravatar image gvdhoorn  ( 2020-12-07 09:40:42 -0500 )edit

Ah, I figured it out. I had forgotten to set: export LIBGL_ALWAYS_INDIRECT=0 When I ran in Melodic, it gave me an error if I forgot this, but Noetic doesn't give an error, it just doesn't run. It was helpful discussing this with you, @gvdhoom, thanks!

Morris gravatar image Morris  ( 2020-12-07 18:23:06 -0500 )edit

Please post your edit as an answer instead.

Then accept your own answer.

gvdhoorn gravatar image gvdhoorn  ( 2020-12-08 04:10:25 -0500 )edit

Okay, done.

Morris gravatar image Morris  ( 2020-12-08 05:47:33 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2020-12-08 05:10:18 -0500

Morris gravatar image

I found the problem and solution. Make sure to set this environment variable before running gazebo:

export LIBGL_ALWAYS_INDIRECT=0
edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2020-12-07 09:06:33 -0500

Seen: 632 times

Last updated: Dec 08 '20