ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

launch only remotely installed package on remote machine

asked 2017-06-27 10:24:24 -0500

sihe gravatar image

updated 2017-06-27 10:35:57 -0500


I have the following setup:

  • a computer where the roscore runs
  • a remote computer, where a certain node named zed_ros_wrapper ( the node to read out images of the ZED stereo camera) should run

I would like to launch the whole system with a launch file on the computer where the roscore runs.

When I try to launch the zed_ros_wrapper node remotely, i get the following error:

Traceback (most recent call last):
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/", line 307, in main
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/", line 268, in start
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/", line 217, in _start_infrastructure
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/", line 132, in _load_config
roslaunch_strs=self.roslaunch_strs, verbose=self.verbose)
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/", line 451, in load_config_default
loader.load(f, config, verbose=verbose)
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/", line 746, in load
self._load_launch(launch, ros_config, is_core=core, filename=filename, argv=argv, verbose=verbose)
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/", line 718, in _load_launch
self._recurse_load(ros_config, launch.childNodes, self.root_context, None, is_core, verbose)
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/", line 662, in _recurse_load
self._param_tag(tag, context, ros_config, verbose=verbose)
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/", line 95, in call
return f(*args, **kwds)
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/", line 256, in _param_tag
vals = self.opt_attrs(tag, context, ('value', 'textfile', 'binfile', 'command'))
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/", line 202, in opt_attrs
return [self.resolve_args(tag_value(tag,a), context) for a in attrs]
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/", line 183, in resolve_args
return substitution_args.resolve_args(args, context=context.resolve_dict, resolve_anon=self.resolve_anon)
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/", line 370, in resolve_args
resolved = _resolve_args(resolved, context, resolve_anon, commands)
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/", line 383, in _resolve_args
resolved = commands[command](resolved, a, args, context)
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/", line 151, in _find
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/", line 197, in _find_executable
full_path = _get_executable_path(rp.get_path(args[0]), path)
File "/usr/lib/python2.7/dist-packages/rospkg/", line 203, in get_path
raise ResourceNotFound(name, ros_paths=self._ros_paths)
ResourceNotFound: zed_wrapper
ROS path [0]=/opt/ros/kinetic/share/ros
ROS path [1]=/home/ubuntu/git_catkin_ws/src
ROS path [2]=/home/ubuntu/catkin_ws/src/image_pipeline/camera_calibration

[... the entire ROS_PACKAGE_PATH ... ]

ROS path [37]=/opt/ros/kinetic/share
ROS path [38]=/home/ubuntu/git_catkin_ws/src/ORB_SLAM2/Examples/ROS

Something to mention is maybe that the zed_wrapper_node is installed on the remote machine, but not on the machine running ... (more)

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted

answered 2017-06-27 10:31:48 -0500

sihe gravatar image

updated 2017-06-27 10:35:41 -0500

I discovered, that apparently the package zed_ros_wrapper needs to be detectable also on the host machine in order to be launched on the remote machine. I don't know why this is, but as soon as I compiled a dummy package also called zed_ros_wrapper on the host machine, the error would disappear and the node would launch without problems on the remote machine.

So as a general rule, to be launched on a remote computer, packages need also to be installed (or at least a package of the same name should be detectable) on the host computer from which the node is remotely launched. Does anybody know of a hint in the ROS documentation about this?

edit flag offensive delete link more


This hack doesn't seem to work anymore... unfortunately...

Rufus gravatar image Rufus  ( 2021-02-10 02:10:51 -0500 )edit

See my workaround here

Rufus gravatar image Rufus  ( 2021-02-10 03:14:26 -0500 )edit

answered 2017-06-27 11:45:48 -0500

gvdhoorn gravatar image

updated 2017-06-27 11:46:10 -0500

Your error is currently 'by design' and expected - albeit perhaps not very nice.

See wiki/roslaunch/XML:

Substitution args are currently resolved on the local machine. In other words, environment variables and ROS package paths will be set to their values in your current environment, even for remotely launched processes

edit flag offensive delete link more


What I then don't understand is how using on the two computers different catkin_ws names causes no problems. On my host machine it's called "git_catkin_ws", and on the remote machine it's called "catkin_ws". Shouldn't this cause problems when the ROS pkg path is set to the current envirnm.?

sihe gravatar image sihe  ( 2017-06-28 07:53:36 -0500 )edit

I can't say why you're not running into any errors.

gvdhoorn gravatar image gvdhoorn  ( 2017-06-28 10:20:58 -0500 )edit

Question Tools



Asked: 2017-06-27 10:24:24 -0500

Seen: 560 times

Last updated: Jun 27 '17