Gazebo | Ignition | Community
Ask Your Question

jake.anq's profile - activity

2017-05-10 12:18:39 -0500 received badge  Taxonomist
2017-02-20 07:44:01 -0500 received badge  Famous Question (source)
2017-02-20 07:44:01 -0500 received badge  Notable Question (source)
2017-02-20 07:44:01 -0500 received badge  Popular Question (source)
2015-07-28 07:25:01 -0500 asked a question Physics Glitching, Velocity NaN

I am running a ROS-based simulation involving a quadcopter from the hector_quadrotor packages. While driving the quadcopter manually, it is fairly easy to crash the quadcopter in such a way that the physics glitches and causes the model to reposition itself at the origin (usually) and refuse to accept further input other than rotation on the spot. It often drifts randomly at this time as well.

After the problem has occurred, calling the /gazebo/getmodelstate ROS service reveals that the linear and angular velocities of the quadcopter are NaN:

$ rosservice call /gazebo/get_model_state "model_name: 'quadrotor' \
relative_entity_name: ''" 
    x: 0.0
    y: 0.0
    z: 0.0
    x: 0.0
    y: 0.0
    z: 0.0
    w: 1.0
    x: nan
    y: nan
    z: nan
    x: nan
    y: nan
    z: nan
success: True
status_message: GetModelState: got properties

I am using a fully-updated ROS Hydro install on Ubuntu 14.04 with Gazebo v2.2.3.

The ideal solution would be to prevent crashes causing the models to glitch out at all, however if there was a way to reset a model to fix the problem without requiring Gazebo to be relaunched it would work for me.

Thank you for your help and please let me know if there's any other information that might be helpful.

2015-07-28 06:42:01 -0500 received badge  Scholar (source)
2014-08-05 09:14:45 -0500 received badge  Famous Question (source)
2014-05-05 17:44:55 -0500 received badge  Popular Question (source)
2014-05-05 17:44:55 -0500 received badge  Notable Question (source)
2014-04-22 22:10:39 -0500 answered a question gzserver segfaults upon startup

After looking around in gdb a bit more, I solved the problem by manually copying the contents of the .gazebo/models directory from the computer that had a working gzserver to the one that did not work. It all seems to work properly now, although I am still puzzled as to why it is still segfaulting.

For anyone else who comes across this problem, the files required are the .tar.gz archives in the sun/ and ground_plane/ folders found here:

2014-04-22 21:52:44 -0500 asked a question gzserver segfaults upon startup

Hi all

I have just installed Gazebo 2.2.1 from source. When attempting to start the server ($ gzserver), the program appears to do nothing for ~30 seconds then has a segmentation fault. The program output and backtrace is as follows:

(gdb) run
Starting program: /home/jake/Builds/gazebo/build/gazebo/gzserver 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/".
[New Thread 0x7fffe0103700 (LWP 12683)]
Gazebo multi-robot simulator, version 2.2.1
Copyright (C) 2012-2014 Open Source Robotics Foundation.
Released under the Apache 2 License.

[New Thread 0x7fffdf639700 (LWP 12684)]
[New Thread 0x7fffdee38700 (LWP 12685)]
Msg Waiting for master
Msg Connected to gazebo master @
Msg Publicized address:
Warning [] Getting models from[]. This may take a few seconds.
[New Thread 0x7fffde42b700 (LWP 12686)]
[Thread 0x7fffde42b700 (LWP 12686) exited]
[New Thread 0x7fffde42b700 (LWP 12687)]
[Thread 0x7fffde42b700 (LWP 12687) exited]
[New Thread 0x7fffde42b700 (LWP 12688)]
[Thread 0x7fffde42b700 (LWP 12688) exited]
*** Large number of similar lines removed for clarity ***
[New Thread 0x7fffde42b700 (LWP 12803)]
[Thread 0x7fffde42b700 (LWP 12803) exited]
[New Thread 0x7fffde42b700 (LWP 12804)]
[Thread 0x7fffde42b700 (LWP 12804) exited]
[New Thread 0x7fffde42b700 (LWP 12805)]
[Thread 0x7fffde42b700 (LWP 12805) exited]

Program received signal SIGSEGV, Segmentation fault.
strlen () at ../sysdeps/x86_64/strlen.S:106
106 ../sysdeps/x86_64/strlen.S: No such file or directory.
(gdb) bt
#0  strlen () at ../sysdeps/x86_64/strlen.S:106
#1  0x00007ffff2e5f7a0 in mkdirhier () from /usr/lib/
#2  0x00007ffff2e5e19d in tar_extract_dir () from /usr/lib/
#3  0x00007ffff2e5e3fb in tar_extract_file () from /usr/lib/
#4  0x00007ffff2e5fc32 in tar_extract_all () from /usr/lib/
#5  0x00007ffff7b96a1a in gazebo::common::ModelDatabase::GetModelPath (this=this@entry=0x64f4e0 <SingletonT<gazebo::common::ModelDatabase>::GetInstance()::t>, _uri=..., 
    _forceDownload=_forceDownload@entry=true) at /home/jake/Builds/gazebo/gazebo/common/
#6  0x00007ffff7bad0a9 in gazebo::common::SystemPaths::FindFileURI (this=this@entry=0x64fd40 <SingletonT<gazebo::common::SystemPaths>::GetInstance()::t>, _uri=...)
    at /home/jake/Builds/gazebo/gazebo/common/
#7  0x00007ffff7bad527 in gazebo::common::SystemPaths::FindFile (this=this@entry=0x64fd40 <SingletonT<gazebo::common::SystemPaths>::GetInstance()::t>, _filename=..., 
    _searchLocalPath=_searchLocalPath@entry=true) at /home/jake/Builds/gazebo/gazebo/common/
#8  0x00007ffff7b7fd07 in gazebo::common::find_file (_file=...) at /home/jake/Builds/gazebo/gazebo/common/
#9  0x000000000043ca7c in operator()<std::basic_string<char>, std::basic_string<char> (*)(const std::basic_string<char>&), boost::_bi::list1<const std::basic_string<char>&> > (
    this=<optimised out>, f=<optimised out>, a=<synthetic pointer>) at /usr/include/boost/bind/bind.hpp:243
#10 operator()<std::basic_string<char> > (a1=..., this=<optimised out>) at /usr/include/boost/bind/bind_template.hpp:47
#11 boost::detail::function::function_obj_invoker1<boost::_bi::bind_t<std::string, std::string (*)(std::string const&), boost::_bi::list1<boost::arg<1> > >, std::string, std::string const&>::invoke (function_obj_ptr=..., a0=...) at /usr/include/boost/function/function_template.hpp:132
#12 0x00007ffff5e47bef in sdf::findFile(std::string const&, bool, bool) () from /usr/lib/x86_64-linux-gnu/libsdformat ...