Unit 5 - ERROR: unknown service

When running the ‘rosservice info /trajectory_by_name’ command I get ‘ERROR: unknown service’ and I’m not sure why? Especially because when I run ‘rossrv show trajectory_by_name_srv/TrajByName’ I get the expected output.

Hi @brianaireland,

Welcome to our community.

In order to see the service details, you have to make sure the /trajectory_by_name service is running.

Please check the list of running services with:

rosservice list

If your service doesn’t appear there, please make sure you launched it first.

Please let us know how it goes after launching the service.

Aaah, of course! Thank you very much for the help, I’m getting the expected output now!

1 Like

The command rossrv show works because you have the TrajByName message compiled. However, the rosservice info command will not work if the ROS program that provides that service is not running.

This means, in order for the command rosservice info /trajectory_by_name to produce any output, you must have launched the ROS program that you created to provide that service.

1 Like

Thank you for the extra clarification!

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.