Gazebo Answers logo

Gazebo will crash intermittently when I run it from roslaunch in conjunction with other ROS nodes

  • If I roslaunch a .launch file that starts a .world file via gazebo_ros, Gazebo does not crash.
  • However, my .launch file also contains a .urdf with plugins (that may use ROS and Gazebo messaging) and some other ROS nodes (containing SMACH finite state machines for example). In this case, Gazebo does crash intermittently, once every 2 - 10 launches.
  • The crashing appears to become more frequent (a crash every 2-4 launches) as the number of ROS node's in the launch file goes up.
  • My solution is to Ctrl-C the Terminal window and then simply roslaunch the .launch file again. Sometimes I have to repeat this process a couple times. Repeated Gazebo crashes also appear to become more frequent as the number of nodes I'm launching goes up.
  • A weird trick, if I:
  • $ roslaunch myfile.launch
  • and then immediately click on my terminal window and drag-it across my monitor.
    Gazebo will almost never crash. I have no idea why this works. I just know it does (for me).

Error Message
libGL error: failed to create drawable ...
[gazebo_gui-2] process has died ...

Also, I think there's a segmentation fault one, but I wasn't able to produce it on demand (as I said, the crashing seems somewhat random / non-deterministic)

Graphics Card
I have a non-NVIDIA Graphics Card:

01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Bonaire XTX [Radeon R7 260X/360]

Looking through the forums, there seem to be a number of related questions:

On startup of gazebo I get intermittent error
Diagnosis: ROS or Gazebo threading bug, race condition, graphics card
Workaround: Set gazebo_ros debug parameter to true, set node respawn="true" in .launch file

gazebo crashes immediately using roslaunch after installing gazebo ros packages gazebo_gui-3 error when starting gazebo with roslaunch
Diagnosis: gazebo_ros can't handle extra roslaunch __name and __log arguments
Workaround: start gazebo from separate terminal with rosrun
Solution?: https://github.com/ros-simulation/gazebo_ros_pkgs/commit/c1681bc009d94cec96bf173adfd2a3d2510c7e5e


When I Ctrl-C the terminal window where I ran roslaunch, I usually get the following [gazebo-2] escalating to SIGTERM message:

  [gazebo-2] escalating to SIGTERM
  [rosout-1] killing on exit
  Exception ignored in: <gdb.GdbOutputFile object at 0x7fdbc6477518>
  Traceback (most recent call last):
    File "/usr/share/gdb/python/gdb/__init__.py", line 43, in flush
      def flush(self):
  [master] killing on exit
  shutting down processing monitor...
  ... shutting down processing monitor complete

Including this in case it is relevant

How to run Gazebo without crashing?
Is there something obvious I'm missing. What's the best way for me to go about diagnosing/fixing this problem?

Thank you.

Originally posted by josephcoombe on Gazebo Answers with karma: 609 on 2017-12-01

Post score: 0


1 Answer 1


Gazebo Answers logo

Update: The easiest fix appears to be to use a NVIDIA Graphics Card. Teammate has been running exact same launch files on his machine w/o any problems.

Originally posted by josephcoombe with karma: 609 on 2018-01-04

This answer was ACCEPTED on the original site

Post score: 0


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.