How to setup and configure go ethereum
Posted By : Md Imroz Alam | 10-Apr-2017
If we want to change geth source code by our requirement , first we have to setup go-ethereum repository on our machine.
There are no of following changes can be done by go-ethereum source code
a) block difficulty
c) fast mining
d) memory space changes for an unlock account and extra
There are the following step to configure go-ethereum on our local machine.
a) Open Terminal b) Take clone of go-ethereum by following command git clone https://github.com/ethereum/go-ethereum
Download go compiler and installation step a) wget https://storage.googleapis.com/golang/go1.7.4.linux-amd64.tar.gz b) sudo tar -xvf go1.7.4.linux-amd64.tar.gz c) sudo mv go /usr/local d) Create .go directory in home. (It is easy to install the necessary packages without admin privillege) mkdir ~/.go e) Set up the following environment variables GOROOT=/usr/local/go GOPATH=~/.go PATH=$PATH:$GOROOT/bin:$GOPATH/bin f) Update the go command sudo update-alternatives --install "/usr/bin/go" "go" "/usr/local/go/bin/go" 0 sudo update-alternatives --set go /usr/local/go/bin/go g) Test the golang version go version h) sudo apt-get install -y build-essential golang
Last step for check , is go-ethereum configure successfully, by runing following command cd go-ethereum make geth
After successful setup of go-ethereum , we can change their source code and run the geth by following line of code
~/go-ethereum/build/bin/geth --datadir first --networkid 1100 --rpcport 8454 --port 30306 --rpcapi eth,web3,personal,miner,admin,txpool --rpc --rpcaddr '127.0.0.1' --rpccorsdomain '*' --nodiscover console
I hope this will be helpful
Md Imroz Alam
Md. Imroz Alam is a bright Web App Developer, he has good knowledge of Java, J2SE, Jsp, Servlet, jdbc. His hobbies are watching movie, playing carom.