728x90
1. 리눅스에 Go 설치하기.
(필자는 윈도우지만, VM으로 리눅스 설치했음)
sudo apt-get update
sudo apt-get install golang -y
wget https://dl.google.com/go/go1.18.3.linux-amd64.tar.gz
sudo tar -C /usr/local -xzf go1.18.3.linux-amd64.tar.gz
가장 최신이 1.18.3이기 때문에 받음.
아래 링크에서 가장 최신의 버전을 확인할 수 있다.
터미널 말고 아래 링크를 통해 직접 다운로드 하는 방법도 있다.
Downloads - The Go Programming Language
Downloads After downloading a binary release suitable for your system, please follow the installation instructions. If you are building from source, follow the source installation instructions. See the release history for more information about Go releases
go.dev
설치가 다 되었으면
go version을 통해 설치가 올바르게 되었는 지 확인 가능하다.
2. Geth 설치하기
sudo apt install -y build-essential libgmp3-dev tree make
git clone https://github.com/ethereum/go-ethereum
cd go-ethereum
make geth
필요한 라이브러리들을 install 해주고
go-ethereum의 줄임말인 geth를 깃클론을 통해 받아오자
다운로드가 끝나면 go-ethereum 디렉토리에서 make geth를 해주자.
빌드가 끝나면, 환경 변수 설정을 해주어야한다.
cd ~
sudo vi .profile
루트 디렉토리에서 profile이라는 파일을 연다.
export PATH=[깃클론받은 디렉토리/go-ethereum/build/bin]:$PATH
soruce ~/.profile
필자같은 경우,
export PATH=/mnt/c/Users/user/Documents/workspace/ethereum/go-ethereum/build/bin:$PATH
이렇게 집어 넣었다.
Geth가 잘 깔렸는지 확인하는 법은
geth version
위 사진처럼 떠야한다.
728x90
'블록체인' 카테고리의 다른 글
[이더리움] web3 라이브러리 설치 및 기능 테스트 (0) | 2022.06.28 |
---|---|
[이더리움] test account 만들어 메타마스크 사용해보기 (0) | 2022.06.27 |
[Typesript] 암호화폐 지갑 웹으로 구현해보기(트랜잭션&정보입력) (0) | 2022.06.17 |
[Typescript] 암호화폐 지갑 대~충 구현해보기(찍먹) (0) | 2022.06.16 |
암호화폐 지갑(wallet)이란? (0) | 2022.06.16 |