Robotics StackExchange | Archived questions

[ros2cli] lifecycle list sub command seg faults

When I run ros2cli lifecycle list (ROS2 installed from deb packages, executed without and with options -c or -a set) the execution hangs. After hitting ctrl+c I get a Segmentation fault (core dumped). Is the sub command Not meant to be used already?

Asked by thinwybk on 2018-07-10 01:31:43 UTC

Comments

Answers

The command is expected to work correctly. In the case that no nodes are detected that are using managed lifecycles (i.e. no nodes with /<node_name>/get_state service etc.), it should return an empty list and exit on its own.

A daemon may be used to speed up the listing of nodes. You can check if it is running with ros2 daemon status, and if it's running you can check its rmw implementation by checking the arguments shown by e.g. ps aux | grep ros2_daemon. This info will be useful for debugging.

It might help to reset the daemon. Could you try updating all ros2 packages, run ros2 daemon stop and then run ros2 lifecycle list again twice? The first call to ros2 lifecycle list will not use a daemon, but it will start a new daemon that will be used for future calls.

If you are still encountering unexpected behaviour could you advise what happens with just ros2 node list and ros2 service list? (as well as your platform)

Asked by dhood on 2018-07-10 02:19:18 UTC

Comments