IPv6 #hblink


Dan K2IE
 

What is the current (or planned) state of support for IPv6 in HBlink3?

73 de K2IE


Randy AA6RH
 

That might be a checklist item for the summer. We need to have a long conversation about what we do with Twisted Internet as a foundational platform for HBLink.

Either that, or I need to get smart about IPv6 support in Twisted.

--R
--
Randy Hall AA6RH (not K7AGE, quit asking) 😁


Randy AA6RH
 

Let me answer your question with a question.

Have you tried using an IPv6 address in the config? What happens?

--R
--
Randy Hall AA6RH (not K7AGE, quit asking) 😁


Dan K2IE
 

I specify the OBP host via DNS name.  On my system, IPv6 is preferred.

DNS returns an IPv6 address and an IPv4 address for that host.  So the network stack would prefer to use IPv6 is possible, but  HBlink3 uses IPv4.

Now why not try the address?  Well, what is the format that HBlink3 expects for an IPv6, if in fact it expects one at all?

Do the embedded colons (:) break parsing?  Does HBlink3 expect [  ] around the address.  I don't know.


Randy AA6RH
 

So, just to give plenty of disclosure, HBLink3 uses Twisted Internet as its network layer. This library has supported IPv6 for a long time, and there's no reason that any reasonable IPv6 address specification will work. Pass it along as a string (which is what you do for IPv4 anyway).

I have no idea what priority Twisted gives to IPv4 addresses over IPv6, it's going to take experimentation to learn the whole truth.

Report back with whatever you discover, please.

--R
--
Randy Hall AA6RH (not K7AGE, quit asking) 😁


Dan K2IE
 

Without brackets around address:

Traceback (most recent call last):
  File "bridge.py", line 747, in <module>
    CONFIG = config.build_config(cli_args.CONFIG_FILE)
  File "/opt/hblink3/config.py", line 274, in build_config
    'TARGET_SOCK': (gethostbyname(config.get(section, 'TARGET_IP')), config.getint(section, 'TARGET_PORT')),
socket.gaierror: [Errno -9] Address family for hostname not supported

With brackets around address:

Traceback (most recent call last):
  File "bridge.py", line 747, in <module>
    CONFIG = config.build_config(cli_args.CONFIG_FILE)
  File "/opt/hblink3/config.py", line 274, in build_config
    'TARGET_SOCK': (gethostbyname(config.get(section, 'TARGET_IP')), config.getint(section, 'TARGET_PORT')),
socket.gaierror: [Errno -2] Name or service not known


Randy AA6RH
 

That's more like it. Gives me somewhere to look.

We're using socket.gethostbyname() which only supports IPv4. We'll have to change that. Can you put an issue on the Github repo so I can track it? Thanks.

https://github.com/HBLink-org/hblink3/issues

--R
--
Randy Hall AA6RH (not K7AGE, quit asking) 😁


Dan K2IE
 

I have HBlink running now with IPv6 and have issued a pull request.  There are some operational caveats which I have documented in a README.md comment.  I hope that some of you will also find this useful.