'facet'에 해당되는 글 1건

  1. 2022.10.18 [Blockchain][Ethereum] 이더리움 테스트 노드(Goerli) 설치
IT/Blockchain2022. 10. 18. 18:02

안녕하세요. IT반장입니다.

이번 시간에는 이더리움 테스트를 위한 테스트 노드 Goerli 설치하는 방법을 소개하겠습니다.

 

 

목차

1. 기본 환경 설정
2. geth 노드 설치 및 실행
3. prysm 모듈 설치 및 실행
4. 기타



0. 설치 환경

- 하드웨어: 최소 CPU 4 core, Mem 8 G, SSD 400 G (AWS c5.xlarge, c5.2xlarge)

- OS: 리눅스(Ubuntu20.04 등)

 

1. 기본 환경 설정

# 관련 패키지 설치
sudo apt-get install
sudo apt-get update

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

# geth 버전 확인
geth version

#---------------------------
Geth
Version: 1.10.25-stable
Git Commit: 69568c554880b3567bace64f8848ff1be27d084d
Architecture: amd64
Go Version: go1.18.5
Operating System: linux
GOPATH=
GOROOT=go
#---------------------------

 

2. geth 노드 설치 및 실행

# 디렉토리 생성
mkdir ethereum
cd ethereum
mkdir consensus
mkdir execution
cd consensus
mkdir prysm
cd prysm

# 키 생성
openssl rand -hex 32 | tr -d "\n" > "jwt.hex"

# geth 실행
nohup geth --goerli --http --http.api eth,net,engine,admin --authrpc.jwtsecret ./jwt.hex > geth.log &

# --syncmode snap/full/light 선택 가능
# 백그라운드 실행 설정(nohup ... &) 및 로깅 설정( > geth.log)은 필요시 사용한다.

# 로그 확인
tail -f geth.log

 

3. prysm 모듈 설치 및 실행

# 신규 터미널에서 prysm 다운로드
cd ethereum/consensus/prysm
curl https://raw.githubusercontent.com/prysmaticlabs/prysm/master/prysm.sh --output prysm.sh && chmod +x prysm.sh
wget https://github.com/eth-clients/eth2-networks/raw/master/shared/prater/genesis.ssz

# prysm 실행
./prysm.sh beacon-chain --execution-endpoint=http://localhost:8551 --prater --jwt-secret=./jwt.hex --genesis-state=genesis.ssz --suggested-fee-recipient=0x01234567722E6b0000012BFEBf6177F1D2e9758D9

# 관련 동의 후 백그라운드 실행
nohup ./prysm.sh beacon-chain --execution-endpoint=http://localhost:8551 --prater --jwt-secret=./jwt.hex --genesis-state=genesis.ssz --suggested-fee-recipient=0x01234567722E6b0000012BFEBf6177F1D2e9758D9 > prysm.log &

# 수수료 수신할 주소는 변경한다.
# 백그라운드 실행 설정(nohup ... &) 및 로깅 설정( > prysm.log)은 필요시 사용한다.

# 로그 확인
tail -f prysm.log

 

4. 기타

# 블록을 Sync 하는데 약 4-5일 소요된다. 
[2022-10-18 08:05:33]  INFO p2p: Peer summary activePeers=39 inbound=0 outbound=39
[2022-10-18 08:05:36]  INFO initial-sync: Processing block batch of size 63 starting from  0x0f88f3c9... 156800/4131028 - estimated time remaining 116h12m19s blocksPerSecond=9.5 peers=39

# 따라서 geth 실행시 --syncmode light 등을 적용하여 목적에 맞게 노드를 운영한다.
 

 


참고 목록

[1] https://notes.ethereum.org/@launchpad/goerli

[2] https://docs.prylabs.network/docs/install/install-with-script 

[3] https://goerli.net/

[4] https://eth-clients.github.io/checkpoint-sync-endpoints/#goerli

[5] https://goerli-faucet.pk910.de/

 


문서 이력

- v1.0 (20221018) :  최초 등록

- v1.1 (20221027) :  설치 환경 추가

 


도움이 되셨다면 

 눌러 주세요.^^

 


 

반응형
Posted by IT반장