ROS fails to launch on remote with the exception: No existing session

asked 2019-11-08 13:49:50 -0600

Hi all,

Master: OS: Ubuntu 18.04.3 LTS Kernel: Linux 5.0.0-32 and ROS Melodic

Remote: OS: Ubuntu 18.04.2 LTS Kernel:Linux 4.15.0-1032-raspi2 and ROS Melodic

I have verified that ROS_MASTER_URI and ROS_IP are correctly set in both machines and I am able run nodes from the remote, however when I try to launch the remote node from the master machine with a launch file, I receive this error in verbose mode.

    roslaunch smart_model display_model.launch target:=true -vvv

... logging to /home/syn-robotics/.ros/log/18323244-0017-11ea-9b86-100c0009d566/roslaunch-synrobotics-10161.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.

... loading XML file [/opt/ros/melodic/etc/ros/roscore.xml]
... executing command param [rosversion roslaunch]
Added parameter [/rosversion]
... executing command param [rosversion -d]
Added parameter [/rosdistro]
Added core node of type [rosout/rosout] in namespace [/]
... loading XML file [/home/syn-robotics/catkin_ws/src/smart_model/launch/display_model.launch]
Added node of type [smart_model/move_to_target.py] in namespace [/]
Added parameter [/joint_state_publisher/source_list]
Added node of type [joint_state_publisher/joint_state_publisher] in namespace [/]
Added node of type [robot_state_publisher/state_publisher] in namespace [/]
Added parameter [/robot_description]
Added machine [raspberry]
Added node of type [robot_arm/smart_interface.py] in namespace [/]
started roslaunch server http://192.168.0.138:43493/
remote[192.168.0.149-0] starting roslaunch
remote[192.168.0.149-0]: creating ssh connection to 192.168.0.149:22
remote[192.168.0.149-0]: failed to launch on raspberry:

Unable to establish ssh connection to [192.168.0.149:22]: No existing session

[192.168.0.149-0] killing on exit
RLException: unable to start remote roslaunch child: 192.168.0.149-0
The traceback for the exception was written to the log file

I am able to ssh into the remote machine with no problem, and no password. I generated a key and copied into the remote with copy-id, by following this tutorial.

This is my launch-file:

<launch>

  <arg name="model" default="$(find smart_model)/urdf/smart_model.urdf"/>
  <arg name="rvizconfig" default="$(find smart_model)/rviz/smart_model.rviz" />
  <arg name="interactive" default="false"/>
  <arg name="target" default="false"/>



  <node if="$(arg interactive)" name="smart_marker" pkg="smart_model" type="int_marker.py" output="screen"/>
  <!-- <node if="$(arg target)" name="target_marker" pkg="smart_model" type="target_marker.py" output="screen"/> -->
  <node if="$(arg target)" name="move_to_target" pkg="smart_model" type="move_to_target.py" output="screen"/>

  <node name="joint_state_publisher" pkg="joint_state_publisher" type="joint_state_publisher">
    <rosparam param="source_list">[ik_joint_states] </rosparam>
    <!-- <param name="use_gui" value="true"/> -->
  </node>
  <node name="robot_state_publisher" pkg="robot_state_publisher" type="state_publisher" />

  <node if="$(arg interactive)" name="rviz" pkg="rviz" type="rviz" args="-d $(arg rvizconfig)" required="true" />
  <param name="robot_description" textfile="$(arg model)"/>

  <machine name="raspberry" address="192.168.0.149" default="true" env-loader="/home/pi/catkin_ws/devel/remove_env_loader.sh"/>
  <node machine="raspberry" pkg="robot_arm" name="smart_interface" type="smart_interface.py"/>

</launch>

And finally, this is my environment loader file:

#!/bin/bash

export ...
(more)
edit retag flag offensive close merge delete

Comments

2
export ROS_MASTER_URI=192.168.0.138

not sure this is the cause, but in any case this is not a valid ROS_MASTER_URI.

It should probably be:

export ROS_MASTER_URI=http://192.168.0.138:11311

or similar.

gvdhoorn gravatar imagegvdhoorn ( 2019-11-08 15:39:22 -0600 )edit