0
$\begingroup$

Rosanswers logo

I have a slightly curious problem with /gazebo/delete_model service. I have a scene with some robots and spawn some simple boxes in runtime. Then to reset the environment, I call delete_model service for the objects as following.

for model_name in model_names:
        rospy.loginfo(model_name)
        try:
            res = self.delete_service(model_name)
            rospy.loginfo(res)
        except Exception as exc:
            rospy.loginfo("Service did not process request: " + str(exc))

If there are only 1-2 objects it works fine but if there are more the service freezes removes some of them and then freezes at a random object 90% of the time. When it is frozen, if I manually delete the model from gazebo UI, service call actually returns "successfully deleted" message. Then it gets stuck on the next object. In the sample code, it freezes on "delete_service" call.

I tried a couple of things. First, I tried an empty scene and it worked fine, somehow the fact that there are more models in the scene causes the freeze.

Second, in my scene, before deleting the models I stop gzclient. After deleteing is done, I start gzclient again. And this seems to also work up to like 70-80 objects, after that it also gets some occasional freezes.

I have seen some similar old questions about delete_model freeze in here so I get the feeling this is a bug in gazebo.

My question is: is there a solution or any kind of workaround for this? Also, is this a known issue?

P.S.: My setup is ros-melodic and gazebo9


Originally posted by kky on ROS Answers with karma: 61 on 2019-07-30

Post score: 1

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

After seeing several unanswered questions on Gazebo answers and Ros answer, I am pretty sure the problem is an actual bug with either Gazebo or nouveau drivers. As a workaround, my problem disappeared after installing nvidia driver. (nouveau driver was installed before).


Originally posted by kky with karma: 61 on 2019-08-06

This answer was ACCEPTED on the original site

Post score: 0

$\endgroup$

Your Answer

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