19

An enode is a way to describe an Ethereum node in the form of a URI. The hexadecimal node ID is encoded in the username portion of the URL, separated from the host by an @ sign. The hostname can only be given as an IP address, DNS domain names are not allowed. The port in the host name section is the TCP listening port. If the TCP and UDP (discovery) ports ...


13

Expanding on Hudson Jameson's answer: "The hexadecimal node ID is encoded in the username portion of the URL" The username portion is a 512-bit public key that is used to verify communication came from a particular node on the network. More about the RLPx protocol used can be found here. Main parts of that: Node discovery and network formation are ...


10

UDP-based discovery is one of the main paradigms of peer discovery. For example, Universal Plug and Play (UPnP) uses the UDP-based Simple Service Discovery Protocol (SSDP), and BitTorrent has a UDP-based Local Peer Discovery protocol. The general method is to multicast (broadcast?) over UDP and see who responds. The fact that UDP is unreliable - i.e. in ...


7

No, there is no peer discovery methods other than modifying the boot nodes. The IP addresses are configured in the source code of the clients. If the IP changes, the list of the last bootstrap node that it connected to will change (the old IP will be removed and when the node connects again the new IP will be stored in the list). What are the peer ...


5

I have the same issue but with parity on a Hetzner server. Is this a part of the node discovery protocol? It would only make sense, if geth would be assuming that there are other nodes in the local network. Yes, somehow. I also tried to wrap my head around this. The clients share recent peers with other clients and this also includes private address ...


4

In a private chain the discovery protocol didn't work. you have one of 2 options use --bootnodes or a static file /static-nodes.json where you store your nodes. Idea : you could write a simple code which scan the network and add the nodes to the nodes json file. read also : Peer discovery not working on private network


3

You can use implementations of existing clients: Besu - Java implementation Geth - Go implementation Parity1 - Rust implementation 1 At this point, I would be careful to use Parity's implementation because Parity has officially stated it won't maintain the codebase any longer and judging by the commit activity, its starting to show already.


3

I doubt there has ever been an actual case of this happening (don't quote me on that unless you also quote that I said not to quote me on it). In order for a block to be valid by Parity and not valid for Geth, a miner would have to knowingly create a block with a time sufficiently in the future, and this is against their best interest since nodes will ...


2

I'd consider using a distributed key-value store such as ETCD (https://coreos.com/etcd/docs/latest/getting-started-with-etcd.html). You could set up an ETCD alongside ethereum and share arbitrary data between each node. While this works well for your specific use case, it may be worth it to consider piggybacking on the Bit Torrent DHT -- a publicly ...


2

Correct. Ethereum node discovery works by nodes gossiping enode addresses between each other, so you have to connect to at least one node manually. The mainnet/testnets get around this inconvenience by having bootstrap nodes hardcoded into clients that lets nodes connect and discover more nodes quickly.


2

Just brainstorming here but I guess the reason block times are accurate is for the same reason the miners agree on all of the other parameters a block must have. Eg they agree that they pay 3 Eth, at time of writing, for each new block. If a miner tries to award themselves more than the block reward their block is rejected. Similarly if a miner submits a ...


2

There is also a rust enr-cli library to assist with decoding ENR strings. You can install it via cargo install enr-cli --version 0.1.0-alpha An example of its use is: $ enr-cli -e -Iu4QGuiaVXBEoi4kcLbsoPYX7GTK9ExOODTuqYBp9CyHN_PSDtnLMCIL91ydxUDRPZ-jem-...


1

You can use the enr library (written in rust). use enr::Enr; fn main() { let enr_string = "-Iu4QGuiaVXBEoi4kcLbsoPYX7GTK9ExOODTuqYBp9CyHN_PSDtnLMCIL91ydxUDRPZ-jem-o0WotK6JoZjPQWhTfEsTgmlkgnY0gmlwhDbOLfeJc2VjcDI1NmsxoQLVqNEoCVTC74VmUx25USyFe7lL0TgpXHaCX9CDy9H6boN0Y3CCIyiDdWRwgiMo"; let enr: Enr = enr_string.parse().unwrap(); println!( "...


1

Geth attempts to connect to 25 peers by default, as stated on the CLI commands page. This can be changed with: --maxpeers value Maximum number of network peers (network disabled if set to 0) (default: 25)


1

Bootnodes is a cheap and effective solution to aid the network self-discovery, but they need to catch up with a proper genesis file to isolate your network. When you run geth, the genesis block is recreated from scratch and then it begin to sync with peers at block 1. For you private blockchain, you need to provide this file to all of your nodes so they ...


Only top voted, non community-wiki answers of a minimum length are eligible