Example Running GETH-LH

Update & Install Go-Ethereum

sudo apt update && sudo apt upgrade && sudo apt install software-properties-common curl tar wget build-essential micro unzip git jq chorny python3-pip
sudo add-apt-repository -y ppa:ethereum/ethereum 
sudo apt update -y 
sudo apt install ethereum -y

Installing Lighthouse Consensus

wget https://github.com/sigp/lighthouse/releases/download/v4.0.1/lighthouse-v4.0.1-x86_64-unknown-linux-gnu-portable.tar.gz 
tar -xvf lighthouse-v4.0.1-x86_64-unknown-linux-gnu-portable.tar.gz 
sudo cp lighthouse /usr/local/bin lighthouse --version

Installing Golang

wget https://go.dev/dl/go1.20.2.linux-amd64.tar.gz 
sudo rm -rf /usr/local/go && sudo tar -C /usr/local -xzf go1.20.2.linux-amd64.tar.gz micro ~/.bashrc 
export PATH=$PATH:/usr/local/go/bin < Add on top bottom & CTRL + S & CTRL + Q
source ~/.bashrc 
go version

Installing Repository

git clone https://github.com/gitshock-labs/testnet-list 
cd testnet-list 
git checkout master 
mkdir logs beacon-1 beacon-2 validator

# CREATE LOG FILES
cd logs 
touch beacon-1.log beacon-2.log validator.log 
cd ..

Installing Deposit CLI

git clone https://github.com/gitshock-labs/staking-cli.git 
cd staking-cli 
git checkout main
pip3 install -r requirements.txt 
python3 setup.py install ./deposit.sh install 
./deposit.sh new-mnemonic --num_validators=1 --mnemonic_language=english --chain=cartenz --folder=/home/ubuntu/testnet-list/validator 

Save the mnemonic!

Create JWTSecret

openssl rand -hex 32 | tr -d "\n" > "jwt.hex"

Initialise genesis block

geth --datadir "geth-data" init execution/genesis.json 
geth account new --datadir "geth-data"

Running GETH

nohup geth \
--http \
--http.api=web3,admin,net,eth,txpool \
--datadir="/home/ubuntu/testnet-list/geth-data" \
--http.corsdomain="*" \
--networkid=1881 \
--authrpc.jwtsecret="/home/ubuntu/testnet-list/jwt.hex" \
--http.addr 0.0.0.0 \
--authrpc.addr 0.0.0.0 \
--http.port 8545 \
--authrpc.port 8551 \
--discovery.port 30303 \
--port 30303 \
--cache 1024 \
--gcmode archive \
--syncmode=full \
--identity="Dana-Pooetry" \
> /home/ubuntu/testnet-list/logs/geth_1.log &

Login Console Javascript Geth

geth attach http://localhost:8545 

admin.addPeer("enode://0e2b41699b95e8c915f4f5d18962c0d2db35dc22d3abbebbd25fc48221d1039943240ad37a6e9d853c0b4ea45da7b6b5203a7127b5858c946fc040cace8d2d63@147.75.71.217:30303") admin.addTrustedPeer("enode://0e2b41699b95e8c915f4f5d18962c0d2db35dc22d3abbebbd25fc48221d1039943240ad37a6e9d853c0b4ea45da7b6b5203a7127b5858c946fc040cace8d2d63@147.75.71.217:30303") 
net.listening
net.peerCount
admin.peers

Check your peers if you see the list peer same like on Nodemoon you connect to chain!

before running lighthouse you need compare all path directory to your directory! like --testnet-dir --datadir, logfile, jwtsecret!

Running Lighthouse

nohup lighthouse beacon \
--http \
--eth1 \
--gui \
--http-address 127.0.0.1 \
--testnet-dir="/home/ubuntu/testnet-list/consensus" \
--datadir /home/ubuntu/testnet-list/beacon-1 \
--http-allow-origin="*" \
--http-allow-sync-stalled \
--execution-endpoints http://127.0.0.1:8551 \
--http-port 5052 \
--enr-udp-port=9000 \
--enr-tcp-port=9000 \
--discovery-port=9000 \
--port 9000 \
--jwt-secrets="/home/ubuntu/testnet-list/jwt.hex" \
--graffiti "Lighthouse_VC" \
--suggested-fee-recipient=0x36f5e59bcfa6e194eadfbc8dc40113098f21d530 \
> /home/ubuntu/testnet-list/logs/beacon-1.log &

# Open New Terminal Grab Your ENR Key
curl http://localhost:5052/eth/v1/node/identity | jq 

before running lighthouse you need compare all path directory to your directory! like --testnet-dir --datadir, logfile, jwtsecret!

Running Lighthouse

nohup lighthouse beacon \
--http \
--eth1 \
--gui \
--http-address 127.0.0.1 \
--testnet-dir="/home/ubuntu/testnet-list/consensus" \
--datadir /home/ubuntu/testnet-list/beacon-2 \
--http-allow-origin="*" \
--http-allow-sync-stalled \
--execution-endpoints http://127.0.0.1:8551 \
--http-port 5053 \
--enr-udp-port=9001 \
--enr-tcp-port=9001 \
--discovery-port=9001 \
--port 9001 \
--jwt-secrets="/home/ubuntu/testnet-list/jwt.hex" \
--graffiti "Lighthouse_VC" \
--suggested-fee-recipient="CHANGE-YOU-ADDRESS" \
--boot-nodes="YOUR-ENR-KEY,enr:-MS4QHXShZPtKwtexK2p9yCxMxDwQ-EvdH_VemoxyVyweuaBLOC_8cmOzyx7Gy-q6-X8KGT1d_rhAn_ekXnhpCkA_REHh2F0dG5ldHOIAAAAAAAAAACEZXRoMpBMfxReAmd2k___________gmlkgnY0gmlwhJNLR9mJc2VjcDI1NmsxoQJB10N42nK6rr7Q_NIJNkJFi2uo6itMTOQlPZDcCy09T4hzeW5jbmV0c4gAAAAAAAAAAIN0Y3CCIyiDdWRwgiMo,enr:-MS4QEw_RpORuoXgJ0279QuVLLFAiXevNdYtU7vR8S1CY7X9CS6tceMbaxdIIJYRmHN43ClqHtE2b0H0maSb18cm9D0Hh2F0dG5ldHOIAAAAAAAAAACEZXRoMpBMfxReAmd2k___________gmlkgnY0gmlwhJNLR9mJc2VjcDI1NmsxoQOkQIyCVHLbLjIFMjqNSJEUsbYMe4Tsv9blUWvN6Rsft4hzeW5jbmV0c4gAAAAAAAAAAIN0Y3CCIymDdWRwgiMp,enr:-LS4QExQqM_G3y2CfedjrGEbapN5Vprdy7Iq2gzfylwLW8PQf4Tf82XnQxLg9PbH8QLwsMaoWwYjTo7xHQ4oy4eCn7kBh2F0dG5ldHOIAAAAAAAAAACEZXRoMpBMfxReAmd2k___________gmlkgnY0iXNlY3AyNTZrMaEDec2pARmw1GLJHiXIDaG-6J74gZ1SyDcF_CuVUzRsmX2Ic3luY25ldHMAg3RjcIIjKoN1ZHCCIyo,enr:-Ly4QASQytrMTDShxZLaYNw_gLFKr_jgn264t812QqCIYtRXDAvLjNokixeG5nXJdCL94VcCmpF_HVIgJhgvR871pwABh2F0dG5ldHOIAAAAAAAAAACEZXRoMpBMfxReAmd2k___________gmlkgnY0gmlwhDZSKp-Jc2VjcDI1NmsxoQJ01SgLN3nyqQc-6-pvOnVL4p3TKaqTEj8xcTyyVFLk-4hzeW5jbmV0cwCDdGNwgiMsg3VkcIIjLA" \
> /home/ubuntu/testnet-list/logs/beacon-2.log &

NEXT STEP? RUNNING VALIDATOR NODE, DEPOSIT AND STAKING, PLEASE WAIT ANNOUNCEMENTS!

Last updated