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

ROS melodic launching on a remote machine with robot upstart

asked 2023-01-09 04:09:56 -0500

Pran-Seven gravatar image

updated 2023-01-09 04:25:25 -0500

Hey! So I have a setup where I want to launch my ROS nodes via a launch file, which in turn will ssh into a udoo board and the launch the necessary files for hardware communication. The launch file works great normally when I do roslaunch, and I have set up a passwordless connection between the PC running ROS and udoo, using the ssh-rsa protocol. I wanted to launch this on the robot upstart so used the robot-upstart package to create a service for launching. This is where my errors start, as the service does not be able to establish a ssh connection between the PC running ROS and the udoo board. The error is as follows:

 Jan 09 15:12:26 seven-robot-2 systemd[1]: Started "bringup test_ru_launch".
    Jan 09 15:12:26 seven-robot-2 root[3298]: test_ru_launch: Using workspace setup file /home/seven-robot-2/Seven_ROS/devel/setup.bash
    Jan 09 15:12:26 seven-robot-2 test_ru_launch-start[3297]: <14>Jan  9 15:12:26 root: test_ru_launch: Using workspace setup file /home/seven-robot-2/Seven_ROS/devel/setup.bash
    Jan 09 15:12:27 seven-robot-2 test_ru_launch-start[3297]: <14>Jan  9 15:12:27 root: test_ru_launch: Launching ROS_HOSTNAME=seven-robot-2, ROS_IP=, ROS_MASTER_URI=http://sevenrobot2:11311/, ROS_HOME=/root/.ros, ROS_LOG_DIR=/tmp
Jan 09 15:12:27 seven-robot-2 test_ru_launch-start[3297]: ls: cannot access '/etc/ros/melodic/test_ru_launch.d/*.xacro': No such file or directory
    Jan 09 15:12:27 seven-robot-2 test_ru_launch-start[3297]: <14>Jan  9 15:12:27 root: test_ru_launch: Generated launchfile: /tmp/test_ru_launch.launch
    Jan 09 15:12:27 seven-robot-2 root[3359]: test_ru_launch: Started roslaunch as background process, PID 3358, ROS_LOG_DIR=/tmp
    Jan 09 15:12:27 seven-robot-2 test_ru_launch-start[3297]: <14>Jan  9 15:12:27 root: test_ru_launch: Started roslaunch as background process, PID 3358, ROS_LOG_DIR=/tmp
    Jan 09 15:12:28 seven-robot-2 test_ru_launch-start[3297]: xacro: in-order processing became default in ROS Melodic. You can drop the option.
    Jan 09 15:12:29 seven-robot-2 test_ru_launch-start[3297]: remote[192.168.2.23-0]: failed to launch on udooqdl:
    Jan 09 15:12:29 seven-robot-2 test_ru_launch-start[3297]: Unable to establish ssh connection to [root@192.168.2.23:22]: Server u'192.168.2.23' not found in known_hosts
    Jan 09 15:12:29 seven-robot-2 test_ru_launch-start[3297]: 
    Jan 09 15:12:29 seven-robot-2 test_ru_launch-start[3297]: RLException: unable to start remote roslaunch child: 192.168.2.23-0
    Jan 09 15:12:29 seven-robot-2 test_ru_launch-start[3297]: The traceback for the exception was written to the log file
    Jan 09 15:12:29 seven-robot-2 test_ru_launch-start[3297]: ... logging to /tmp/edd14b60-9001-11ed-8c81-7c8334b0242e/roslaunch-seven-robot-2-3358.log
    Jan 09 15:12:29 seven-robot-2 test_ru_launch-start[3297]: Checking log directory for disk usage. This may take a while.
    Jan 09 15:12:29 seven-robot-2 test_ru_launch-start[3297]: Press Ctrl-C to interrupt
    Jan 09 15:12:29 seven-robot-2 test_ru_launch-start[3297]: Done checking log file disk usage. Usage is <1GB.
    Jan 09 15:12:29 seven-robot-2 test_ru_launch-start[3297]: [31B blob data]
    Jan 09 15:12:29 seven-robot-2 test_ru_launch-start[3297]: started roslaunch server http://seven-robot-2:46315/
    Jan 09 15:12:29 seven-robot-2 test_ru_launch-start[3297]: remote[192.168.2.23-0] starting ...
(more)
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2023-01-11 00:18:25 -0500

Pran-Seven gravatar image

So the issue turned out to be the fact that, this particular service launched as root, but we had established ssh with the remote machine as a user. Creating new keys and establishing it as the root seemed to fix the issue.

edit flag offensive delete link more

Question Tools

2 followers

Stats

Asked: 2023-01-09 04:09:56 -0500

Seen: 81 times

Last updated: Jan 11 '23