Building your own Ethereum full node can be challenging due to the lack of clear documentation. This guide provides step-by-step instructions to help you set up a node efficiently.
Hardware Requirements for Node Setup
Recommended Configuration:
- CPU: 4 cores
- RAM: 8GB
- Storage: 500GB SSD
- Network: 5Mbps+ bandwidth
Minimum Configuration:
- CPU: 2 cores
- RAM: 4GB
- Storage: 500GB HDD
- Network: 2Mbps bandwidth
👉 Optimize your node performance with these tips
Hosting Location: Domestic vs. International
- International servers generally offer smoother installation due to fewer restrictions.
- Domestic cloud services (e.g., Alibaba Cloud) are reliable but may require additional steps to bypass firewall limitations.
Step-by-Step Installation Guide
1. Install Go Language
Required for compiling go-ethereum:
yum install golangVerify installation:
go version
# Output: go1.9.6 linux/amd642. Install Git
To fetch go-ethereum source code:
yum install https://centos6.iuscommunity.org/ius-release.rpm
yum install epel-release
yum install git2uCheck version:
git version
# Output: git version 2.16.43. Fetch and Compile go-ethereum
Clone the repository and switch to the stable branch:
git clone https://github.com/ethereum/go-ethereum.git
cd go-ethereum/
git checkout release/1.8Compile the source:
make allBinary files (including geth) will be generated in build/bin.
4. Add geth to System PATH
Edit /etc/profile and append:
export PATH=$PATH:/opt/ethereum/go-ethereum/build/binReload the profile:
source /etc/profileVerify:
geth version5. Key geth Startup Parameters
Essential flags for node operation:
--datadir "path": Specifies blockchain data storage location.--cache 4096: Increases sync speed (recommended: 1024+ MB).--rpc,--ws: Enable remote procedure calls and WebSocket.
Example command:
geth --datadir data --cache 4096 --rpc --rpcport 6666 --rpcaddr 0.0.0.0 --ws --wsaddr 0.0.0.0 --wsport 6667 --wsorigins "*"6. Run geth in Background
Use nohup for persistent operation:
nohup geth [parameters] & > nohup.outTo stop the process:
kill -INT $(ps -ef | grep geth | grep -v grep | awk '{print $2}')Monitoring Sync Status
Attach to the running node:
geth attach data/geth.ipcCheck sync progress:
> eth.syncing
{
currentBlock: 6143193,
highestBlock: 6143296,
knownStates: 91512910,
pulledStates: 91498893
}Verify peer connections:
> net.peerCount
8👉 Explore advanced node management techniques
Completion Indicators
eth.blockNumberreturns a non-zero value.Logs show continuous block imports:
INFO [08-16|14:20:35] Imported new chain segment blocks=1...
FAQ
1. How long does initial sync take?
Typically 24–48 hours depending on hardware and network speed.
2. Why is eth.blockNumber showing 0 during sync?
This is normal until the node catches up with the latest block.
3. What if net.peerCount is 0?
Check firewall settings and ensure ports (30303 TCP/UDP) are open.
4. Can I run a node on a Raspberry Pi?
Possible but not recommended due to hardware limitations (use light clients instead).
5. How much storage does a full node require?
Over 500GB (SSD strongly recommended for performance).
6. Is it safe to expose RPC/WS ports?
Limit access via IP whitelisting or reverse proxies to mitigate risks.
This guide covers Ethereum mainnet node setup from hardware selection to synchronization. For troubleshooting, consult community forums or share your questions below.
🚀 Pro Tip: Regularly update geth to access the latest features and security patches!