problem with Admin Console in using "unicast" settings

2 posts / 0 new
Last post
Offline
Last seen: 2 months 2 weeks ago
Joined: 09/10/2022
Posts: 21
problem with Admin Console in using "unicast" settings

I use connext dds version 6.0.0 . I want to disable "multicast discovery" and use "unicast discovery" for all domain participants in domain.
First of all I set this Qos for domain participant in modern c++:

dds::domain::qos::DomainParticipantQos dpQos = dds::core::QosProvider::Default()
.participant_qos(rti::core::builtin_profiles::qos_lib::baseline());
std::map<std::string,std::string> dpPropertyMap = {{"dds.transport.UDPv4.builtin.multicast_enabled", "0"}};
dpQos << rti::core::policy::Property(dpPropertyMap.begin(),dpPropertyMap.end());
dpQos->discovery.multicast_receive_addresses(dds::core::StringSeq({}));
...

I set environment variable in linux:
NDDS_DISCOVERY_PEERS="119@builtin.shmem://,119@localhost,119@192.168.12.5"

In rti persistence service's xml I set this qos:
...
<participant_qos>
<discovery>
<!-- disable the reception multicast for discovery -->
<multicast_receive_addresses/>
<initial_peers>
<element>builtin.shmem://</element>
<element>119@localhost</element>
<element>119@192.168.12.5</element>
</initial_peers>
</discovery>
<property>
<value>
<element>
<name>dds.transport.UDPv4.builtin.multicast_enabled</name>
<value>0</value>
</element>
</value>
</property>
</participant_qos>
...

In Admin Console xml I set this qos:
...
<participant_qos>
<discovery>
<multicast_receive_addresses/>
<initial_peers>
<element>builtin.shmem://</element>
<element>119@127.0.0.1</element>
<element>119@192.168.12.5</element>
</initial_peers>
</discovery>
<property>
<value>
<element>
<name>dds.transport.UDPv4.builtin.multicast_enabled</name>
<value>0</value>
</element>
<element>
<name>dds.transport.UDPv4.builtin.unicast_enabled</name>
<value>1</value>
</element>
</value>
</property>
</participant_qos>
...

I think all things works unless that I have two problem with admin console:
1. Admin console can not discover domains automatically and I should Manually join and leave domains. I mean I should active Preferences>Domains>"Manually join and leave domains" and I should give it domainId and click on "join Domains".
2. Admin console will not open and can not show domains if all initial_peers that set in admin console xml are not connected. In xml that I showed above, admin console will not open if I choose my domain and my pc is not connected to "192.168.12.5" ip.

Howard's picture
Offline
Last seen: 6 hours 42 min ago
Joined: 11/29/2012
Posts: 588

For automatic domain discovery, Admin Console must use multicast.  Since you disabled multicast in your system, Admin Console will not be able to automatically join any domains since it won't discovery any.  So, yes, you will have to use manual discovery mode.

What do you mean that Admin Console "won't open"?  Do you mean that it crashes? 

If so, is there information in the log file?

Documents\rti_workspace\6.0.0\user_config\admin_console\x64Win64\admin_console.log

And finally, is there a reason that you are using the value 119 in "119@locahost" or "119@w.x.y.z"?   This will cause Connext DDS to send out 120 packets every 30 seconds to try to find applications at the addresses given.  That's a waste of CPU and network bandwidth if you don't expect to create 120 DomainParticipants simultaneously on each host address.