◈ 9ce92808be498e9e05590ff27cbfdfe4
RRC hub: 28c7c1a68c735693aa8e6b8193ed44b2 (join room general)
Forum / Help / Are per-interface discovery settings possible?

Are per-interface discovery settings possible?

Started by xf302 1bda10f601e48c7e... ·

xf302 1bda10f601e48c7e...

I'm curious as to if discovery settings can be tuned per each interface 'type'. Basically, I have several Backbone/TCP interfaces and a few Yggdrasil ones, and I would like the cost of peering with Yggdrasil nodes to be less than with IPv4/6 ones. Here is one attempt:

[reticulum]
share_instance = Yes
instance_name = default
respond_to_probes = Yes
enable_transport = False

[logging]
loglevel = 4

[interfaces]

[[Default Interface]]
type = AutoInterface
enabled = Yes
devices = wlp1s0, enp0s31f6

[[Yggdrasil Backbone Interface]]
type = BackboneInterface
enabled = yes
device = tun0
port = 4343
discover_interfaces = True
autoconnect_discovered_interfaces = 4
required_discovery_value = 10
discovery_scope = global
mode = gateway

[[SLEN_YGG]]
type = BackboneInterface
enabled = yes
remote = 201:3295:9019:9fba:2f29:68b3:f4a:3cca
target_port = 4343
transport_identity = 83c0c9ca089b76f2a9be05d64561a06b

The basic idea is that discover_interfaces would be false globally, but enabled for certain listening interfaces, and with specific settings for each one. Unfortunately, this test did not work--no interfaces were discovered at all, and traffic only ever flowed over Auto and the one remote node. The log also didn't throw any related errors as far as I could tell.

Is this actually possible? I know RNS does a good job of managing itself fairly well, but it would be nice just to have this option. The closest thing I see is the interface_discovery_sources option, which doesn't seem to be what I'm after.

On a related note, has anyone ever been able to get a yggdrasil listener interface like above to function? The docs mention it, but again, I never see any traffic on mine (just on the remote ygg nodes).

edited

I do not think so, not in the way you want to do it, but I have to ask what version of RNS are you, and sorry if I misunderstand what you meant. My english is getting better, but I still make mistakes.

I can address the last point first. That function does not seem to be enabled, it is placeholdered with a todo

if is_ygg_ipv6(info["reachable_on"]):
        # TODO: Somehow detect if yggdrasil is enabled on the system
        return

which I take to mean that it can autodiscover yggdrasil, but won't auto connect to them, that comment seems to say that RNS can't detect if Yggdrasil is installed.

Now for the discover_interfaces being false globally, and parsed from the interfaces themselves, I don't think you can do that. Reticulum.py has those globally

  if "reticulum" in self.config:
      for option in self.config["reticulum"]:

          if option == "discover_interfaces":
              v = self.config["reticulum"].as_bool(option)
              if v == True:  Reticulum.__discover_interfaces = True

          if option == "required_discovery_value":
              v = self.config["reticulum"].as_int(option)
              if v > 0: Reticulum.__required_discovery_value = v

          if option == "autoconnect_discovered_interfaces":
              v = self.config["reticulum"].as_int(option)
              if v > 0: Reticulum.__autoconnect_discovered_interfaces = v


So you can't just put those in an interface I don't think. They are read from the [Reticulum] section of the config file. Since Reticulum.py is only looking for them in the [Reticulum] section of the config file, putting them in the interfaces does nothing.

Edit: I reference 1.3.4 which I think is the latest? I haven't setup rngit yet so I am still a github peasant.

xf302 1bda10f601e48c7e...

Thanks, I think that placeholder tells me everything I need to know. Bit dissapointing, but better that it's a todo instead of just absent. I'm on 1.3.4, and lxmd 1.0.1.

Post a Reply

Markdown

Supports Markdown: **bold**, *italic*, `code`, ```code blocks```, [links](url)

Log in to upload images

Proof of work verification for anonymous posting

Copied to clipboard