In the first part of the installation, we are going to install the Raspbian Linux Operating System and configure it in a reliable and secure way.ġ. Installation Install and configure the OS The total cost for this setup is $160 with an estimated annual recurring cost of $10/year for electricity. Headless installation might be difficult for beginners, so it is sometime easier to connect the Pi to a screen via HDMI (mini) and a keyboard.Ī Heatsink is recommended to keep the CPU cool and reduce the risk of hardware failure due to overheating. If you would like to connect to the Internet through Ethernet, you would need an Ethernet Cable That should give you a few years before rebuilding the whole thing on a larger disk.įinally we use a 3.5A USB-C power supply to power up the SBC. It is recommended that you use at least a 500GB SSD because the actual size of the Ethereum mainnet after a fast sync is about 200GB. In order to store the large Ethereum state database, which requires very high Disk IO performance, we connect a Samsung SSD T5 (500GB) to the board via USB3.0. To host the operating system (OS), I use a SanDisk 16GB Ultra microSD
You can help secure the network the more independent nodes running the more copies there are of the blockchain and the more resilient it is.You will own a trusted Ethereum stack you can rely on to manage your assets and send transactions to the network yourself (remote nodes are generally reliable but are controlled by 3rd parties and typically throttle heavy usage).Some people might ask what the benefits are of running your own node.
In this guide we will follow the second synchronisation mode, fast (with full garbage collection), to run a full-node on a RaspberryPi 4.
But very few people (such as Block Explorers) need an archive node. (bear in mind, it takes more than 2.3 TB of space). gcmode archive disables the garbage collection and keep all the historical state data blocks after blocks of Ethereum since the Genesis. This saves a lot of space and it takes less than 200 GB at this stage (Sept 2019) to run a full node in this setup. gcmode full enables the garbage collection to keep in memory only the latest 128 tries. Garbage collection is used to discard old state tries and save some space. But this approach, less secure and more suitable for IOT/mobiles, only uses 100MB of space.īlockchain garbage collection mode : Unlike full and fast, is not a full node as it doesn't store the entire blockchain but only the block headers, and it depends on full nodes. Light sync: Light mode syncs directly to the last few blocks, does not store the whole blockchain in database. When the chain reaches a recent state (head - 1024 blocks), geth switches to full sync mode, import the remaining blocks and process them as in the classical sync (full) to obtain a full node.
Instead of processing all the transactions that ever happened, fast sync downloads all the transaction receipts and the entire recent state database and perform a PoW verification. At the end of the process, the node is a full node.įast sync: A fast sync also downloads all the data (block headers and block bodies) but exchanges processing power for bandwidth usage. This method is the most traditional and stable but can take a very a long time (up to a few weeks) and would require a more powerful machine. Here is a summary of the different options available to synchronise the Ethereum blockchain with Geth (Go-Ethereum):įull sync: A full sync downloads all the data (block headers and block bodies), processes the entire blockchain one link at a time, and replays all transactions that ever happened in history (transaction processing and PoW verification).
Syncing Ethereum has always been a pain point for many people because it's a complex process with multiple options, including different verification modes which requires different setup that can cost a lot of money and takes weeks to sync. So I was really excited to try to sync an Ethereum Full Node on the number one Single-Board Computer (SBC). My wife recently offered me the latest Raspberry Pi 4 (model B) 4GB. Running an Ethereum Full Node on a RaspberryPi 4 (model B)