Following instructions from the excellent https://www.rinkeby.io/
A full node lets you access all state. There is a light node (state-on-demand) and wallet-only (no state) instructions as well, and these are even faster. I'm using this for dapp development, so I want access to all state.
From the docs above:
A full node synchronizes the blockchain by downloading the full chain from the genesis block to the current head block,
but does not execute the transactions. Instead, it downloads all the transactions receipts along with the entire recent state.
As the node downloads the recent state directly, historical data can only be queried from that block onward.
Initial processing required to synchronize is more bandwidth intensive, but is light on the CPU and has significantly reduced
disk requirements. Mid range machines with HDD storage, decent CPUs and 4GB+ RAM should be enough.
First, install the latest geth (1.7.3) to your machine.
For Ubuntu, you can follow the instructions on the official wiki.
sudo apt-get install software-properties-common
sudo add-apt-repository -y ppa:ethereum/ethereum
sudo apt-get update
sudo apt-get install ethereum
If you need to upgrade geth
from a previous version,
you can just run
sudo apt install geth
If you're downloading this to your Mac, you'll need to download the packages manually to get the latest (1.7.3) release. https://geth.ethereum.org/downloads/
Extract it and copy the geth
binary to somewhere in your path.
# ppham @ Pauls-Air-2 in ~/Downloads [21:46:25]
$ tar zxvf geth-darwin-amd64-1.7.3-4bb3c89d.tar.gz
x geth-darwin-amd64-1.7.3-4bb3c89d/
x geth-darwin-amd64-1.7.3-4bb3c89d/COPYING
x geth-darwin-amd64-1.7.3-4bb3c89d/geth
# ppham @ Pauls-Air-2 in ~/Downloads [21:46:39]
$ sudo mv geth-darwin-amd64-1.7.3-4bb3c89d/geth /usr/local/bin/geth
For older releases on Mac OSX, you can use Homebrew to install from scratch:
brew install ethereum
and again if you are upgrading just geth
brew install geth
Unknown whether Parity works as well. It will probably take some finagling to work with the Geth-style Genesis block.
At this point, you should probably start a tmux
or screen
session, so if you get
interrupted during syncing it will still keep going in the background.
To run a full node, start Geth with the Rinkeby switch:
geth --rinkeby
To run a light node, you can use syncmode
option
geth --rinkeby --syncmode "light"
To follow syncing progress you can attach the console
geth attach ~/.ethereum/rinkeby/geth.ipc
or
geth attach http://localhost:8545
and run this command: eth.syncing
. It will return false
if it's fully synced.
On the console, you can also create your account:
Welcome to the Geth JavaScript console!
instance: Geth/v1.6.1-stable-021c3c28/darwin-amd64/go1.8.1
modules: admin:1.0 clique:1.0 debug:1.0 eth:1.0 miner:1.0 net:1.0 personal:1.0 rpc:1.0 txpool:1.0 web3:1.0
> eth.accounts
[]
> personal.newAccount("nopasswd")
"0xb2e9fe08ca9a0323103883fe12c9609ed380f475"
> eth.coinbase
"0xb2e9fe08ca9a0323103883fe12c9609ed380f475"
> eth.getBalance(eth.coinbase)
0
You'll see a different address than 0xb2e9fe08ca9a0323103883fe12c9609ed380f475
. That one's mine, provided for illustration.
Save your password in a secret place, preferrably encrypted. I use Evernote encrypted text, but you can use any password manager
like 1Password, LastPass, Dashlane, etc.
Leave that terminal open for now.
Because Kovan and Rinkeby both use Proof-of-Authority (clique) to grant ETH, you'll need to request some to get started. However, unlike Kovan which requires you to bootstrap by requesting KETH from another human being, Rinkeby has a super-slick automated faucet, where you submit your address (copied from above) into one of three methods:
- A public tweet on Twitter
- A public Facebook post
- A public Google+ link
I've used my twitter to do this.
Copy the URL:
https://twitter.com/laurogripa/status/959896418675843080
Go to the Crypto Faucet
section of https://rinkeby.io or https://rinkeby.io#faucet
and paste it into the blank.
Choose an option from the dropdown which corresponds to how much Ether you need and how frequently (requesting more Ether will take longer between requests). I requested 3 ETH in 8 hours. Don't worry, you'll get your ETH in seconds, but you can't request again for another 8 hours. This is to prevent spammers from swamping the network by overpowering it with mining power and then out-spending everyone else.
This is the transaction where I received my 3 ETH: https://rinkeby.etherscan.io/tx/0xca4737937c70afb12092adc117846560ff92dfb58fd157cca45cc230eeb82be4
Now, back in your geth console, wait for at most 15 seconds for the next block to be found, and verify your balance again
> eth.getBalance(eth.coinbase)
3000000000000000000
Don't get too excited, this isn't real ETH. XD