etclabscore / core-geth

A highly configurable Go implementation of the Ethereum protocol.
https://etclabscore.github.io/core-geth
GNU Lesser General Public License v3.0
263 stars 144 forks source link

Why was UDP closed in the latest update? #609

Closed Phoenix1969 closed 5 months ago

Phoenix1969 commented 6 months ago

Peers connecting has become horrible since the last update and i noticed the closed connection. it is effecting the entire network. Why and what are we supposed to do about it?

meowsbits commented 5 months ago

Can you say more about your finding the UDP closed in the latest update? Which update? Where was it closed? I don't believe we ever intended to do that, so we'll need to investigate on your context. We also run several always-on boot nodes and several ephemeral test nodes, and haven't been able to reproduce the issue.

We have indeed received multiple reports of problematic peering (eg. https://github.com/etclabscore/core-geth/issues/610), but haven't been able to solidify a rationale for it with 100% certainty.

What we do know is that per our network explorer on https://etcnodes.org/, the ETC network is dominated by CoreGeth/ETCMCgethNodes, which we know to be configured to be undiscoverable, which certainly doesn't help the network any. Likewise, if your node is undiscoverable (eg firewalled), poor peering can be expected since the protocol becomes unilateral and synchronous rather than bilateral and asynchronous.

ziogaschr commented 5 months ago

@Phoenix1969 can we also please know your location (if allowed to be shared), in order we check on a node in the same locations as you. It might need more time to find good nodes close to you, and we might be able to find the cause and resolve it easier.

LordExodus commented 5 months ago

Upnp doesn't seem to work with the latest version compared to version 1.12.10. When starting, the port is opened on the router but closed again after a short time, maybe with lease time or something

ziogaschr commented 5 months ago

@LordExodus this is a great finding to start with. I will test both versions to verify it. Thanks

ziogaschr commented 5 months ago

You did a great find @LordExodus. Do you know how to build #611 and try this release to let us know if this works for you? If you can't build it yourself and you are willing to test, please let me know your operating system and I can send you a custom build to test with.

LordExodus commented 5 months ago

Please build it for me. I am on win64... Thank you! @ziogaschr

meowsbits commented 5 months ago

Here you go, @LordExodus Build generated here: https://github.com/meowsbits/core-geth/actions/runs/7748823071 Download here: https://github.com/meowsbits/core-geth/actions/runs/7748823071/artifacts/1213713926

LordExodus commented 5 months ago

Thank you for that! @meowsbits @ziogaschr Its working flawless now. This will also fix a lot of undiscoverable ETCMC nodes. Hope the next stable release comes soon, good work

ziogaschr commented 5 months ago

Thanks for testing @LordExodus. Indeed we were trying to find out about the peer issues the last months without luck. Your mention to UPnP helped us to focus here. I looked at this before, but haven't waited for 2 minutes for checking back my router.