ETH 2.0 validator setup tips

Setting up the ETH 2.0 validator using Prysm has been smooth for the most parts. There were just a few hipcups I’d like to share here and hopefully it will save you some time troubleshooting and googling around. Prysm also has a very active discord channel which I got a lot of my answers from. So, if you are stuck with a problem not listed here, just ask in the discord, you’ll get your answer immediately.

Waiting for enough suitable peers before syncing

Initially, I setup the beacon node on my laptop in a docker container so I can run the node in the background. Everything went well until 30 minutes later, my beacon node stopped synchronizing with the network. The docker log was filled with following error message:

initial-sync: Waiting for enough suitable peers before syncing required=3 suitable=0

Searching online, I found the solution: Improve Peer-to-Peer Connectivity.

The problem was suspected to be caused by home network and router that keeps bad traffic from our home network.

The recommended solution:

  1. making network configuration changes, or
  2. run the beacon node in the cloud

I chose the latter option, and started running my beacon node on google cloud platform.

And, my beacon node was running again, synchronizing slowly, very slowly though.

How long does it take to synchronize a beacon node?

Patiently, I waited 3 days and my beacon node was still in the initial sync process with the following log:

initial-sync: Processing block batch ... estimated time remaining 79h57m46s

Reviewing my virtual machine (VM) specification against the system requirement guide, I noticed my VM spec is lower than the minimum required specification.

I was using the E2 series with 1 shared CPU and 4G Memory, 10G SSD.

So, I changed the VM to Compute Specialized C2 series with 4 vCPU, 16G Memory. I also added 100G SSD because I ran out of disk space later.

After the upgrade, the beacon node completed initial synchronization in 2 hours. I later ran another node with the same VM spec and was able to complete synchronization from scratch in a few hours.

In summary, the faster your machine, the faster the synchronization process will complete.

Where to get Görli testnet ETH?

Now that the beacon node is caught up, I need to deposit 32 ETH to the deposit contract. Here are 2 places you can get 33 ETH:

  1. Prysm Discord - request by submitting the message !send [your ethereum address]

  2. faucet

After submitting the deposit and starting my validator node, I can check my validator status from the following explorers for the medalla testnet:

  1. beaconscan medalla
  2. beaconchain medalla

But my validator is stuck in the pending state!! 😞

To understand why the validator is stuck in pending state, we need to understand the Validator Lifecycle.

A validator transitions in the following order:

My validator took 15 days to become active. So, the more pending validators in the queue, the longer it takes to activate.

Another reason my validator took longer to activate because I started the validator when the medalla network was in the non-finality state. During non-finality, validator entry queue will be halted, no new validator will be able to join the network. To return to the finality state, the network will heavily penalize offline active validators and kick them out when their balance fall below 16 ETH. This process took quite a few days though.

See Medalla non-finality mid October for more detailed explanation.

What if I don’t want to run the validator anymore?

Well, you can run the voluntary-exit command to exit your validator. But, there is an exit queue. Yes, there’s a queue to exit the network. That means, your validator will not exit immediately. Just like the entry queue, your validator will only exit once it completes the exit queue.

Depending on the size of the exit queue, this can take days. As shown below, my validator is estimated to take 20 days to exit. In the mean time, you have to keep running the validator or it will be penalized.