Skip to content

How to connect from an ethereum node on Raspberry to a Private Network whit PoA

Notifications You must be signed in to change notification settings

AdriGeorge/RaspberryNode

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 

Repository files navigation

Ethereum node on Raspberry

Getting Started

These instructions will allow you to connect to an ethereum private network.

Pre-requisites

  • You need the original genesis.json file from the private network and the enode from the bootnode

  • Install go-ethereum

pi$: sudo add-apt-repository -y ppa:ethereum/ethereum
pi$: sudo apt-get update
pi$: sudo apt-get install ethereum

Check version

$ geth version

Other Operating systems: https://github.com/ethereum/go-ethereum/wiki/Building-Ethereum

Setup

1] Create enviroment

pi$: mkdir fileName
pi$: mkdir fileName/node
pi$: cd fileName

Put the same genesis.json file from the private network into "fileName" and init the node

fileName$: geth --datadir node/ init genesis.json

Create a new account (you can create as many you want) and save the data

fileName$: geth --datadir node/ account new
fileName$: echo 'password' >> node/password.txt
fileName$: echo 'address' >> accounts.txt

Create a sh file to run your node

fileName$: touch startnode.sh

Modify the file with this string: remove [] and write your configuration

geth --datadir node/ --syncmode 'full' --minerthreads=1 --port [] --rpc --rpcaddr '[]' --rpcport [] --rpcapi 'personal,db,eth,net,web3,txpool,miner' --bootnodes '[]' --networkid [] --gasprice '0' -unlock '[]' --password node/password.txt --mine --ipcpath "~/fileName/node/geth.ipc"

Make your sh file executable

fileName$: chmod +x ./startnode.sh

2] Start the node and connect

fileName$: ./startnode.sh

Open a new terminal

filename$: cd node
node$: geth attach geth.ipc

3] Wait until 50%+1 of signers give you the autorization (clique.propose("address", true))

Now you can interact with the blockchain from console. For the full list of command check: https://ethereum.stackexchange.com/questions/28703/full-list-of-geth-terminal-commands

About

How to connect from an ethereum node on Raspberry to a Private Network whit PoA

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published