open-rmf / free_fleet

A free fleet management system.
Apache License 2.0
156 stars 65 forks source link

After the free fleet server and client are connected, gazebo shuts down. #115

Closed ClobotLucy closed 2 years ago

ClobotLucy commented 2 years ago

Bug report

Required information:

Description of the bug

After the free fleet server and client are connected, gazebo shuts down. Screenshot from 2022-02-08 08-59-37

  1. ros2 launch clober_ros2_sim sim.launch.py ( run gazebo ) Screenshot from 2022-02-08 08-47-55

  2. ros2 launch clober_ros2_sim nav.launch.py ( run navigation2 ) Screenshot from 2022-02-08 08-48-10

  3. ros2 launch clober_ros2_ff clober_ff_client.launch.xml ( run free fleet ros2 client ) Screenshot from 2022-02-08 08-48-47

  4. ros2 launch clober_ros2_ff clober_ff_server.launch.xml ( run free fleet ros2 server ) Screenshot from 2022-02-08 08-48-37

aaronchongth commented 2 years ago

Hello @ClobotLucy! Thanks for bringing this up. As a sanity check, does this happen consistently for you?

Based on your description, it is gazebo that crashes, not the server, is that right? If the server crashes as well, could you check if this is related? https://github.com/open-rmf/free_fleet/issues/113

Just in case this is due to some rogue processes still running in the background, could you try running this command to kill any remaining gazebo process before starting the sim again?

pkill -9 gazebo && pkill -9 gzserver && pkill -9 gzclient
ClobotLucy commented 2 years ago

Hello @aaronchongth The problem consistently occur. ( gzclient crashes. not the free fleet server )

Screenshot from 2022-02-08 13-45-21

After the server(free fleet) and client(free fleet) are connected, gzclient crashes.

Screenshot from 2022-02-08 13-45-49

aaronchongth commented 2 years ago

Hmm, this behavior is new to me. Is it possible to share your simulation .world file? I have a hunch this is related to a gazebo plugin, since the client and server seems to still be running.

ClobotLucy commented 2 years ago

Of course. There is the .world file in that link. https://github.com/CLOBOT-Co-Ltd/clober_ros2_sim/tree/foxy-devel/worlds Thank you.

aaronchongth commented 2 years ago

thanks for sharing @ClobotLucy, nothing seems out of the ordinary after a quick look. Could I trouble you to provide me with the .repos file for your workspace, so I can try to build and recreate it on my end?

You can get it by running

vcs export YOUR_WORKSPACE/src > issue.repos --exact
ClobotLucy commented 2 years ago

Hello @aaronchongth Here is the link to the repository(issue.repos). https://github.com/CLOBOT-Co-Ltd/clober_ros2_sim/blob/foxy-devel/issue.repos

I created a new workspace, downloaded the package through issue.repos, built it, and tested it, but the same issue occurs.

aaronchongth commented 2 years ago

Hello @ClobotLucy! I tried reproducing your setup, but unfortunately have been unable to reproduce the crash.

https://user-images.githubusercontent.com/5383623/154432120-92ff2eee-d872-458a-94a5-7374b10f56c6.mp4

As a sanity check, do you have binaries of RMF installed? Could you check with dpkg -l | grep rmf

Since both the client and the server is running fine, my gut tells me that it is somehow related to the plugins in the world. Could you try commenting out all these plugins, door, lift, toggle_charging, toggle_floors, and try again?

Make sure to delete and rebuild the clobot_ros2_sim package after modifying the world, since the build might decide to skip updating the world file as it already exists in build and install,

rm -rf build/clobot_ros2_sim install/clobot_ros2_sim
colcon build --packages-select clobot_ros2_sim
ClobotLucy commented 2 years ago

@aaronchongth Thanks for checking the question. When I commented out plugins such as door and lift and ran it, no crash occurred. I guess I'll have to test it by reinstalling Gazebo.

Thank you.

aaronchongth commented 2 years ago

@ClobotLucy thanks for verifying! I would be curious to know what the issue was once you do manage to isolate it.

I'll be closing this issue for now