Eth 2.0 Key Generation: Ubuntu Live USB

This guide demonstrates how to safely generate Eth 2.0 validator keys using Ubuntu live boot from USB.

circle-info

The process to create mainnet and testnet keys is identical, but the keys are NOT interchangeable. Be sure to practice everything on testnet prior to depositing on mainnet.

DISCLAIMER - FOR EDUCATIONAL PURPOSES ONLY

triangle-exclamation

Summary

You will need 2 USB sticks and a PC running either Linux, Windows, or macOS.

Step 1 - Download eth2.0-deposit-cli Key Generator

triangle-exclamation

circle-info

Select the file ending in linux-amd64.tar.gz , then choose "Save". Once complete, the file (aka tarball) should appear in your Downloads folder.

Copy the eth2deposit-cli tarball to the USB:

circle-info

Eject the USB with the tarball and insert the 2nd USB to be used for Ubuntu.

Step 2 - Download Ubuntu

Visit http://www.releases.ubuntu.com/20.04/arrow-up-right and download the desktop image:

Step 3 - Burn Ubuntu ISO image to USB

circle-exclamation

Ubuntu Desktop - Click theicon and search "startup disk creator" :

Choose the Ubuntu ISO and Make Startup Disk:

triangle-exclamation

Installation Complete:

Step 4 - Disconnect Internet

triangle-exclamation

DISCONNECT INTERNET || aka AIR-GAP

Step 5 - Boot into Ubuntu Live USB

Ubuntu USB Startup Process:

  1. Begin with the computer powered down

  2. Plug the Ubuntu live USB into the computer

  3. Start the computer and continually press F-12 to enter one-time boot menu

  4. Choose the Ubuntu live USB from the boot menu

circle-info

Tapping F-12 or F-10 at computer startup is the standard method to enter the one-time boot menu. If that doesn't work you can search "one-time boot menu" for your computer model.

If nothing is working, you may need to use F-2 and enter the BIOS to allow booting from USB.

If successful, the Ubuntu live USB will pull up the GRUB menu. It may automatically continue, otherwise select the first option by hitting ENTER

Select Try Ubuntu:

circle-info

Once you click Try Ubuntu, the Ubuntu 20.04 desktop will begin to load.

Turn Off WiFi and Bluetooth:

Plug in 2nd USB and double click the eth2deposit-cli tarball:

Click Extract in the upper left corner:

Click Home towards the upper left, then click the green Extract

Rename the folder to eth2.0-deposit-cli

Step 6 - Eth 2.0 Key Generation

Open new terminal window using Ctrl + Alt + T

Change directory to eth2.0-deposit-cli folder:

Run ./deposit new-mnemonic:

circle-info

You will be asked to provide the following responses:

  1. Please choose your mnemonic language:

  2. Please choose how many validators you wish to run:

  3. Please choose mainnet or testnet:

  4. Type a password to secure your validator

  5. Repeat password for confirmation

Step 7 - Mnemonic Seed

triangle-exclamation

If you lose the mnemonic seed, your stake is lost forever.

After confirming the password, you'll be given a mnemonic seed phrase:

Write down the mnemonic, then reenter it to ensure it's correct:

circle-info

A few things to keep in mind regarding the 24-word mnemonic phrase:

  • Make sure you use durable paper and permanent pen

  • Store in a waterproof, fireproof bag inside a safe

  • A bank security box is helpful in preventing the $5 wrench attackarrow-up-right

  • Minimum of 2 copies in 2 different locations

  • You can split a copy 12/12 and give to trusted family/friends

circle-info

Once you correctly re-enter the mnemonic, your validator_keys will be created.

Step 8 - deposit_data and keystore files

triangle-exclamation
circle-info

The "pubkey" is the validator public key and should be the same in both files.

Deposit_data file contents:

Keystore file contents:

Copy deposit_data and keystore files to external USB:

circle-info

You can always use your mnemonic seed to generate a new keystore file if necessary.

circle-check

Learn how to run a testnet validator: Pyrmont || Lighthouse Eth2 Staking Guidearrow-up-right

Last updated