ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

Gazebo command doesn't open Gazebo

asked 2018-08-27 21:19:59 -0600

Padmal gravatar image

Hi!

I've been trying to run hector_quadrotor packages for a research. For this, I have to launch gazebo simulator. I have installed ROS Kinetic on a 64bit Ubuntu 16.04 LTS machine.

When I try to run;

$ roslaunch hector_quadrotor_demo indoor_slam_gazebo.launch

I get RViz open correctly. (I couldn't upload a screenshot). It only shows the image part to the left in this similar image. I don't get gazebo open to show me the 3D view of the environment.

So I checked the console log and it shows the following error message.

[gazebo_gui-3] process has died [pid 21110, exit code 132, cmd /opt/ros/kinetic/lib/gazebo_ros/gzclient __name:=gazebo_gui __log:=/home/knight/.ros/log/764ebc9e-aa64-11e8-b5f5-6045cb73915a/gazebo_gui-3.log].
log file: /home/knight/.ros/log/764ebc9e-aa64-11e8-b5f5-6045cb73915a/gazebo_gui-3*.log

I tried to find such a log file and surprisingly there is none in that folder. I Googled this error message and tried many methods as reinstalling gazebo version 9 and then again version 7 but still it's not opening gazebo.

I tried gazebo command on the console itself and it just stays for a few seconds and then I get console prompt again. So I tried verbose;

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

[Msg] Waiting for master.
Gazebo multi-robot simulator, version 7.14.0
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org

[Msg] Waiting for master.
[Msg] Connected to gazebo master @ http://127.0.0.1:11345
[Msg] Publicized address: 192.168.1.102
[Msg] Connected to gazebo master @ http://127.0.0.1:11345
[Msg] Publicized address: 192.168.1.102

After this set of messages I get the console prompt (knight@AID:~$) again.

When I quit RViz window, it closes with the following message.

 [gazebo-2] killing on exit

I wonder what could be the possible reason/s for this failure. Help is much appreciated. Thanks a lot!

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
2

answered 2018-11-11 10:46:24 -0600

robowarrior gravatar image

Hey there,

I kind of faced a similar situation earlier but was able to fix it with a slight change without any installation/uninstallation.

You might have figured this out already but I'll put the fix here as it might be helpful for others.

The problem is the gzclient's setup_path variable.

Edit the /opt/ros/kinetic/lib/gazebo_ros/gzclient file by replacing this line:

setup_path=$(pkg-config --variable=prefix gazebo)/share/gazebo/

with this line:

setup_path=/usr/share/gazebo/

Then everything worked well for me.

edit flag offensive delete link more

Comments

could not understand,what you are asking to replace please explain elaborately

nullspace gravatar image nullspace  ( 2020-09-01 12:28:45 -0600 )edit

please any one help me to sort this error out

nullspace gravatar image nullspace  ( 2020-09-01 12:31:50 -0600 )edit

how will replace the line it is asking administrator problem and could not do in xfce4 also

nullspace gravatar image nullspace  ( 2020-09-02 05:02:46 -0600 )edit

The suggested method works perfectly.

setup_path=/usr/share/gazebo/

jungx148 gravatar image jungx148  ( 2020-09-08 21:47:48 -0600 )edit

@null change the file permission first using chmod then replace that line.. worked fine for me.

HyperX360 gravatar image HyperX360  ( 2020-10-02 10:27:47 -0600 )edit

I was not able to edit that file. My computer doesnt let me edit that file. What should I do?

Shivam gravatar image Shivam  ( 2021-09-26 20:16:06 -0600 )edit

Question Tools

2 followers

Stats

Asked: 2018-08-27 21:19:59 -0600

Seen: 10,947 times

Last updated: Aug 27 '18