1

I cannot launch gazebo on the ubuntu terminl. I have made sure I am using ubuntu 18.04 and ROS melodic and installed gazebo9. Whenever I use 'gazebo -- verbose' command, it throws a few errors (as shown in the attached image). I was hoping if you could help with this problem or had any advice for running gazebo simulation window. I feel that I might have overlooked something which I can't see. I used gazebo --verbose and got the following error message:

Gazebo multi-robot simulator, version 9.19.0
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org

[Msg] Waiting for master.
[Msg] Waiting for master.
[Msg] Connected to gazebo master @ http://127.0.0.1:11345
[Msg] Connected to gazebo master @ http://127.0.0.1:11345
[Msg] Publicized address: 172.23.117.58
[Msg] Publicized address: 172.23.117.58
[Err] [RenderEngine.cc:742] Can't open display: :0
[Wrn] [RenderEngine.cc:88] Unable to create X window. Rendering will be disabled
[Wrn] [RenderEngine.cc:291] Cannot initialize render engine since render path type is NONE. Ignore this warning ifrendering has been turned off on purpose.
[Err] [RenderEngine.cc:742] Can't open display: :0
[Wrn] [RenderEngine.cc:88] Unable to create X window. Rendering will be disabled
[Wrn] [RenderEngine.cc:291] Cannot initialize render engine since render path type is NONE. Ignore this warning ifrendering has been turned off on purpose.
[Wrn] [GuiIface.cc:120] QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'
[Wrn] [GuiIface.cc:120] QXcbConnection: Could not connect to display :0
[Err] [GuiIface.cc:124] Could not connect to any X display.
[Msg] Loading world file [/usr/share/gazebo-9/worlds/empty.world]
ChocoFudge
  • 21
  • 3

1 Answers1

0

It appears you're trying to run gazebo through either an ssh session or WSL. If that is the case you need to make sure you're running an X Server such as xming. If you're going through an ssh connection you also need to make sure you're using X-forwarding by connecting with ssh -XC user@yourHost. Finally you need to make sure the correct environmental variables are set so Gazebo knows which display to use. This needs to be set on all machines being used(both if using ssh or just the one otherwise). It can be set via export DISPLAY=localhost:0.0.

BTables
  • 4,413
  • 2
  • 11
  • 30