Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

If only one of IPv4 / IPv6 is configured, try the other protocol silently #2773

Closed
wants to merge 1 commit into from

Conversation

weebl2000
Copy link

@weebl2000 weebl2000 commented Jun 1, 2021

Do not fail if it is missing, unlike when both IPv4 and IPv6 are missing.

should fix #2732

I am not sure if this is the best way to fix it, but currently the problem is that even if a host is IPv6-enabled but only has an IPv4 host address specified when starting the node, it cannot connect to IPv6 addresses. When the P2P protcol is going live, making sure both IPv4 and IPv6 work is even more important I reckon.

In the current situation IOHK relay DNS names do not return AAAA records. Even if AAAA records would be added now, not a single relay that has only an IPv4 host address specified will be able to connect to any of the IPv6 addresses, even though they might be fully IPv6 capable. Unless DNS entries are handled differently that is.

If neither IPv4 or IPv6 is specified, node can connect to IPv6 just fine.

But do not fail, unlike when both IPv4 and IPv6 are missing.

should fix IntersectMBO#2732
@weebl2000
Copy link
Author

@coot I heard you were involved with networking side of things. I was just wondering if this is something that is desirable behavior or not. This is my first PR to cardano-node, I'm not sure if there is some other process I should go through in the development process. If so, please let me know. :)

Copy link
Contributor

@coot coot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good, thanks for your contribution; Just a minor change request.

Comment on lines +172 to +173
-- When IPv4 host is specified, try IPv6, but do not fail if missing.
-- Very relevant if operator is using RFC4941 on their block producing-node.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you make sure lines fit into 80 columns.

@coot
Copy link
Contributor

coot commented Jun 25, 2021

However this removes the ability of using ipv4 only on a ipv6 capable host so I am not sure if this change is desirable. If you want to use ipv6 you can be explicit about it.

@coot
Copy link
Contributor

coot commented Jun 25, 2021

After a discussion we decided against this change because it limits the way one can configure a node. It turns out that there many ipv6 capable hosts which are connected to ipv6 networks that are not connected to the internet.

@coot coot closed this Jun 25, 2021
@weebl2000
Copy link
Author

weebl2000 commented Jun 25, 2021

After a discussion we decided against this change because it limits the way one can configure a node. It turns out that there many ipv6 capable hosts which are connected to ipv6 networks that are not connected to the internet.

I agree you should be able to configure without IPv6, but currently I feel a lot of operator will not know they are limiting IPv6 operation if they only specify IPv4 host address. Would it be a good addition to do add this behavior if an IPv6 address is specified in the topology file? @coot

My primary concern is:

  1. start node with IPv4 host address only specified
  2. IPv6 address is specified in mainnet config under producers
  3. cardano-node will never be able to connect to specified IPv6 address, even though it is IPv6 capable. I feel it should create IPv6 socket or fail when starting to say something is misconfigured.

This is not going to be feasible in the future when IPv6 will be the main address on the internet. Especially when P2P connectivity goes live this will severly limit all cardano-node operators.

@weebl2000
Copy link
Author

weebl2000 commented Jun 25, 2021

After a discussion we decided against this change because it limits the way one can configure a node. It turns out that there many ipv6 capable hosts which are connected to ipv6 networks that are not connected to the internet.

I think the primary concern for not having this change would be IPv6 hosts that are connected to the internet that do not want to connect to IPv6 cardano nodes. If there are hosts that are IPv6 on LAN-only, they will never even try to connect to any IPv6 hosts because IOHK relay DNS names do not specify AAAA addresses currently.

iohk-bors bot added a commit that referenced this pull request Jul 14, 2021
2870: Add comment about IPv4/IPv6 connectivity r=coot a=weebl2000

Since #2773 was rejected.

Co-authored-by: Wessel Nieboer <wessel.nieboer@onior.com>
Co-authored-by: Wessel <wessel@weebl.me>
iohk-bors bot added a commit that referenced this pull request Jul 15, 2021
2870: Add comment about IPv4/IPv6 connectivity r=coot a=weebl2000

Since #2773 was rejected.

Co-authored-by: Wessel Nieboer <wessel.nieboer@onior.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] - IPv6 addresses in mainnet-toplogy.json do not work
2 participants