Gazebo crashes on simulating gpu_ray
My situation is the following: I have a working robot model with a head_hokuyo_sensor
as laser range finder. When using this model on my default setup, everything works fine. When using the model on a virtual machine, Gazebo crashes when the range readings are requested.
At first I thought Gazebo crashed any time when launched in the virtual machine. This is not true. It only crashes when the range readings are requested, either by visualization (as was default in my first try), or by ROS rviz. This is the output when the model is launched and the data is requested by rviz:
$ roslaunch p3dx_gazebo gazebo.launch
... logging to /home/gazebo/.ros/log/0c658438-357b-11e3-952c-080027a2ea94/roslaunch-gazebo-VirtualBox-10513.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.
started roslaunch server http://gazebo-VirtualBox:44541/
SUMMARY
========
PARAMETERS
* /robot_description
* /rosdistro
* /rosversion
* /use_sim_time
NODES
/
gazebo (gazebo_ros/gzserver)
gazebo_gui (gazebo_ros/gzclient)
urdf_spawner (gazebo_ros/spawn_model)
ROS_MASTER_URI=http://localhost:11311
core service [/rosout] found
process[gazebo-1]: started with pid [10534]
process[gazebo_gui-2]: started with pid [10539]
process[urdf_spawner-3]: started with pid [10546]
Gazebo multi-robot simulator, version 1.9.1
Copyright (C) 2013 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org
Gazebo multi-robot simulator, version 1.9.1
Copyright (C) 2013 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org
Msg Waiting for master.spawn_model script started
[ INFO] [1381829287.748584629]: Finished loading Gazebo ROS API Plugin.
[1;[ INFO] [1381829287.754626059]: waitForService: Service [/gazebo/set_physics_properties] has not been advertised, waiting...
32mMsg Waiting for master
Msg Connected to gazebo master @ http://127.0.0.1:11345
Msg Publicized address: 10.0.2.15
OpenGL Warning: Failed to connect to host. Make sure 3D acceleration is enabled for this VM.
libGL error: failed to load driver: vboxvideo
libGL error: Try again with LIBGL_DEBUG=verbose for more details.
[INFO] [WallTime: 1381829287.963248] [0.000000] Loading model xml from ros parameter
[INFO] [WallTime: 1381829287.969376] [0.000000] Waiting for service /gazebo/spawn_urdf_model
[INFO] [WallTime: 1381829288.279075] [0.000000] Calling service /gazebo/spawn_urdf_model
Msg Connected to gazebo master @ http://127.0.0.1:11345
Msg Publicized address: 10.0.2.15
OpenGL Warning: Failed to connect to host. Make sure 3D acceleration is enabled for this VM.
libGL error: failed to load driver: vboxvideo
libGL error: Try again with LIBGL_DEBUG=verbose for more details.
Error [Param.cc:181] Unable to set value [1,0471975511965976] for key[horizontal_fov]
Error [Param.cc:181] Unable to set value [0,100000001] for key[near]
Warning [parser.cc:356] No <sdf> element in file[data-string]
[INFO] [WallTime: 1381829294.465796] [0.001000] Spawn status: SpawnModel: Successfully spawned model
[ INFO] [1381829294.500488438, 0.001000000]: LoadThread function completed
[ INFO] [1381829294.578569308, 0.001000000]: Loading gazebo_ros_control plugin
[ INFO] [1381829294.583119526, 0.001000000]: Starting gazebo_ros_control plugin in namespace: /p3dx
[ INFO] [1381829294.587561148, 0.001000000]: gazebo_ros_control plugin is waiting for model URDF in parameter [/robot_description] on the ROS param server.
[urdf_spawner-3] process has finished cleanly ...
I thought to have solved it by installing
ros-hydro-hokuyo-node
, but it results in the same error. The libGL errors can be resolved by turning on 3D acceleration and usingexport LIBGL_ALWAYS_SOFTWARE=1
, but this does also not resolve the segmentation fault when the range readings are requested.Can you post a backtrace? It would be most useful if you try running gazebo with any ROS infrastructure.
I have tested the setup with the new Gazebo 2.0. The backtrace is the same.