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

Rosnode ping rosout does not work on remote machine

asked 2018-05-01 15:28:47 -0500

frodyteen gravatar image

updated 2018-05-01 15:38:37 -0500

I have two PCs, PC1 is the robot computer, which is the master, PC2 is my workstation. Both uses ubuntu 14.4 indigo. On PC2, I am connected to the network and able to do

rostopic list

but when I do rosnode ping rosout it gave me an error:

rosnode: node is [/rosout]
pinging /rosout with a timeout of 3.0s
ERROR: Unknown host [dhcp-59-208] for node [/rosout]

when I run rosnode info i get the following

$ rosnode info /rosout
--------------------------------------------------------------------------------
Node [/rosout]
Publications: 
 * /rosout_agg [rosgraph_msgs/Log]

    Subscriptions: 
     * /rosout [rosgraph_msgs/Log]

Services: 
 * /rosout/set_logger_level
 * /rosout/get_loggers


contacting node http://dhcp-59-208:47096/ ...
ERROR: Communication with node[http://dhcp-59-208:47096/] failed!

So on my PC2 I have the following environments:

ROS_IP=192.168.1.100
ROS_HOSTNAME=192.168.1.100
ROS_MASTER_URI=http://192.168.1.11:11311

PC1:

ROS_IP=192.168.1.100
ROS_HOSTNAME=192.168.100
ROS_MASTER_URI=http://localhost:11311

192.168.100 is my wlan0 ip address, which is the network that pc1 and pc2 are on.

I also found someone who had the same exact issue (https://answers.ros.org/question/225097/rosnode-ping-rosout-does-not-work-on-remote-machine/ ), I am not sure what OP meant by "Using ip-addresses everywhere solved it."

edit retag flag offensive close merge delete

Comments

Can you clarify why you deleted the question?

gvdhoorn gravatar image gvdhoorn  ( 2018-05-02 01:28:41 -0500 )edit

I figured it out soon after, turns out, i needed to add the hostname and IP addressf the robot to my pc's etc/hosts file. Should I reopen it and answer it myself?

frodyteen gravatar image frodyteen  ( 2018-05-02 11:43:56 -0500 )edit

Yes, that would be nice.

i needed to add the hostname and IP addressf the robot to my pc's etc/hosts file.

As I only see IP addresses in both ROS_IP and ROS_HOSTNAME in your question text this is a really strange solution.

gvdhoorn gravatar image gvdhoorn  ( 2018-05-02 11:45:43 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2018-05-02 11:58:29 -0500

frodyteen gravatar image

updated 2018-05-02 12:01:39 -0500

So, I figured out my problem by having export ROS_MASTER_URI=http://192.168.1.11:11311.

Also, I added ROS_IP and ROS_HOSTNAME of my PC1 to etc/hosts file on my PC2. It seems like once I've done this, then it can translate the unknown host to an actually ip adress.

edit flag offensive delete link more

Question Tools

2 followers

Stats

Asked: 2018-05-01 15:28:47 -0500

Seen: 474 times

Last updated: May 02 '18