5

My colleagues and I had the issue that sometime ros2 topics were not shown in “ros2 topic list” or that we could not “ros2 topic echo” the data. After further investigation, we concluded that the problem occurred when we connected/disconnected new devices to the network ports after the ROS2 nodes were already running. We are able to reproduce two cases:

Case 1

Case 2

Setup:

  • Ubuntu 22.04
  • ROS2 humble
  • Direct connection to network port, no switch in between.

The problem is shown with any DDS vendor. The only thing that solves these problems is a restart of the ros2 daemon and a restart of the ROS2 nodes. (ros2 daemon restart alone is not sufficient)

My first conclusion in case 1 is that the DDS is not performing a new discovery into the new active network interface. For case 2, I am still unsure what the problem is, but it seems that the DDS creates a dependency on the network interface connected at start.

Is anyone else able to reproduce these issues?

Greenonline
  • 1,508
  • 4
  • 18
  • 32
Renzo
  • 81
  • 4
  • Hi and welcome. Where did you source those images from? Or did you create them yourself? – Greenonline Jan 23 '23 at 14:12
  • 1
    I created myself – Renzo Jan 24 '23 at 09:15
  • For future reference, please don't cross post questions. It's against stack exchange policy. But thank you for at least reposting the answer here for others reference. The other post is https://discourse.ros.org/t/network-issues-ros-topic-visibility-dependency-to-network-interfaces/29385 – Tully Jan 24 '23 at 20:16

1 Answers1

3

Apparently this is a well known issue: https://github.com/ros2/rmw/pull/344#issuecomment-1398852633

In their own words:

The use-case is the following: all the existing DDS implementations currently scan for available network interfaces only once, i.e. when a DDS participant is created. This usually happens when you call rclcpp::init(). If a network interface is not available at that time it will be ignored. For example: you start a ROS application, then you bring up WiFi -> the ROS application will not use WiFi.

Renzo
  • 81
  • 4