Skip to content

Instantly share code, notes, and snippets.

@TheWimmNetwork
Forked from learner-long-life/Rinkeby.md
Created August 1, 2018 01:32
Show Gist options
  • Select an option

  • Save TheWimmNetwork/39fd7ca9530a7adac04016aee1f07687 to your computer and use it in GitHub Desktop.

Select an option

Save TheWimmNetwork/39fd7ca9530a7adac04016aee1f07687 to your computer and use it in GitHub Desktop.

Revisions

  1. Paul Pham revised this gist Nov 22, 2017. 1 changed file with 74 additions and 36 deletions.
    110 changes: 74 additions & 36 deletions Rinkeby.md
    Original file line number Diff line number Diff line change
    @@ -22,69 +22,94 @@ disk requirements. Mid range machines with HDD storage, decent CPUs and 4GB+ RAM


    ## Step 1: Download Geth
    First, download the latest geth (1.6.1) to your laptop.

    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're just 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/

    (I did it to my MacBook Air).
    Extract it and copy the `geth` binary to somewhere in your path.

    Unknown whether Parity works as well. It will probably take some finagling
    to work with the Geth-style Genesis block.
    ```
    # 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](https://brew.sh/) to install from
    scratch:

    ## Step 2: Download genesis block
    ```
    brew install ethereum
    ```
    and again if you are upgrading just `geth`

    ```
    wget https://www.rinkeby.io/rinkeby.json
    brew install geth
    ```

    ## Step 3: Initialize
    Unknown whether Parity works as well. It will probably take some finagling
    to work with the Geth-style Genesis block.

    ## Step 2: Run Geth in Rinkeby Mode

    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, download rinkeby.json and start Geth with:
    To run a full node, start Geth with the Rinkeby switch:

    ```
    geth --datadir=$HOME/.rinkeby init rinkeby.json
    geth --networkid=4 --datadir=$HOME/.rinkeby --cache=512 --ethstats="yournode:Respect my [email protected]" --bootnodes=enode://a24ac7c5484ef4ed0c5eb2d36620ba4e4aa13b8c84684e1b4aab0cebea2ae45cb4d375b77eab56516d34bfbd3c1a833fc51296ff084b770b94fb9028c4d25ccf@52.169.42.101:30303 --rpc --rpcapi="personal,eth,network"
    geth --rinkeby
    ```

    Note that the credentials here `yournode:Respect my authoritah!` appear to be necessary.
    Unknown whether you can create your own creds on `stats.rinkeby.io` so that you can collect your own testnet mining stats :)

    SECURITY WARNINGS: We've enabled RPC and also loaded the `personal` module to allow testing and participating in smart contracts.
    However, if you do these things on a mainnet node with your unlocked wallet exposed to the internet, you could get hacked
    and all your monies stolen. I'll write a separate gist about a secure way to participate in a mainnet contract with real ETH.

    You can download Geth from https://geth.ethereum.org/downloads/.

    On a MacBook Air with a 10 MBps (standard home internet download speeds),
    I was able to sync all 187k blocks in < 7 minutes,

    ## Step 4: Create an account
    ## Step 3: Create an account

    In a separate `tmux` pane or `screen` buffer or a separate terminal completely, create an account and save the password somewhere safe.

    First, symlink the IPC file so you can `geth attach` to the existing geth process.

    On Linux:
    ```
    mkdir -p ~/.ethereum
    ln -s ~/.rinkeby/geth.ipc ~/.ethereum/
    ```
    After that, attach the console with the appropriate data directory.

    On Mac:
    On Linux it would be:
    ```
    mkdir -p ~/Library/Ethereum
    ln -s ~/.rinkeby/geth.ipc ~/Library/Ethereum
    geth --datadir=$HOME/.rinkeby attach ipc:$HOME/.rinkeby/geth.ipc console
    ```

    After that, attach the console
    On Mac it would be:
    ```
    geth attach
    geth --datadir=$HOME/.rinkeby attach ipc:$HOME/Library/Ethereum/rinkeby/geth.ipc console
    ```

    and create an account (substituting a much better password than `notmyrealpassword`.
    and create an account (substituting a much better password than `notmyrealpassword`).

    ```
    Welcome to the Geth JavaScript console!
    @@ -107,16 +132,27 @@ like 1Password, LastPass, Dashlane, etc.

    Leave that terminal open for now.

    ## Step 5: Request ETH
    ## Step 4: Request ETH

    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) and submit a public gist.
    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

    Since I never use Google+ for social reasons with humans,
    I might as well use this for socializing with robots.

    Go to `http://gist.github.com` and create a gist, pasting a single line into it which is your Rinkeby address.
    [Mine looks like this.](https://gist.github.com/cryptogoth/4e404fb58808a241f622afe80a659c05)
    You can go to `http://plus.google.com` and post publicly
    on any discussion board. [Here's mine.](https://plus.google.com/104143092173669955154/posts/bkAkrmtukQ5)

    Copy this URL:
    ```
    https://plus.google.com/104143092173669955154/posts/bkAkrmtukQ5
    ```

    Copy the address of the gist, e.g. https://gist.github.com/cryptogoth/4e404fb58808a241f622afe80a659c05
    Go to the `Crypto Faucet` section of https://rinkeby.io
    and paste it into the blank.

    @@ -126,7 +162,7 @@ request again for another 8 hours. This is to prevent spammers from swamping the
    and then out-spending everyone else.

    This is the transaction where I received my 3 ETH:
    https://rinkeby.etherscan.io/tx/0xf54c0101b71c645032b786b4eb3f0f0402b665575d34903f5fd1c911aaa22ebb
    https://rinkeby.etherscan.io/address/0x54b7bc5bea3845198ff2936761087fc488504eed

    Now, back in your geth console, wait for at most 15 seconds for the next block to be found, and verify your balance again
    ```
    @@ -137,4 +173,6 @@ Now, back in your geth console, wait for at most 15 seconds for the next block t
    Woohoo! You're rich, in testnet wei :)

    If you found this guide useful, follow us on Twitter at @InvisibleLearn
    or join us on Slack: http://invisible-slack.herokuapp.com/
    or join us on Slack: http://invisible-slack.herokuapp.com/

    You can also leave questions, comments, or feedbacks on this gist.
  2. Paul Pham revised this gist Jul 17, 2017. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions Rinkeby.md
    Original file line number Diff line number Diff line change
    @@ -46,7 +46,7 @@ To run a full node, download rinkeby.json and start Geth with:

    ```
    geth --datadir=$HOME/.rinkeby init rinkeby.json
    geth --networkid=4 --datadir=$HOME/.rinkeby --cache=512 --ethstats='yournode:Respect my [email protected]' --bootnodes=enode://a24ac7c5484ef4ed0c5eb2d36620ba4e4aa13b8c84684e1b4aab0cebea2ae45cb4d375b77eab56516d34bfbd3c1a833fc51296ff084b770b94fb9028c4d25ccf@52.169.42.101:30303 --rpc --rpcapi="personal,eth,network"
    geth --networkid=4 --datadir=$HOME/.rinkeby --cache=512 --ethstats="yournode:Respect my [email protected]" --bootnodes=enode://a24ac7c5484ef4ed0c5eb2d36620ba4e4aa13b8c84684e1b4aab0cebea2ae45cb4d375b77eab56516d34bfbd3c1a833fc51296ff084b770b94fb9028c4d25ccf@52.169.42.101:30303 --rpc --rpcapi="personal,eth,network"
    ```

    Note that the credentials here `yournode:Respect my authoritah!` appear to be necessary.
    @@ -94,7 +94,7 @@ instance: Geth/v1.6.1-stable-021c3c28/darwin-amd64/go1.8.1
    > eth.accounts
    []
    > personal.newAccount"notmyrealpassword")
    > personal.newAccount("notmyrealpassword")
    "0xb2e9fe08ca9a0323103883fe12c9609ed380f475"
    > eth.coinbase
    "0xb2e9fe08ca9a0323103883fe12c9609ed380f475"
  3. Paul Pham revised this gist May 23, 2017. 1 changed file with 5 additions and 1 deletion.
    6 changes: 5 additions & 1 deletion Rinkeby.md
    Original file line number Diff line number Diff line change
    @@ -46,12 +46,16 @@ To run a full node, download rinkeby.json and start Geth with:

    ```
    geth --datadir=$HOME/.rinkeby init rinkeby.json
    geth --networkid=4 --datadir=$HOME/.rinkeby --cache=512 --ethstats='yournode:Respect my [email protected]' --bootnodes=enode://a24ac7c5484ef4ed0c5eb2d36620ba4e4aa13b8c84684e1b4aab0cebea2ae45cb4d375b77eab56516d34bfbd3c1a833fc51296ff084b770b94fb9028c4d25ccf@52.169.42.101:30303
    geth --networkid=4 --datadir=$HOME/.rinkeby --cache=512 --ethstats='yournode:Respect my [email protected]' --bootnodes=enode://a24ac7c5484ef4ed0c5eb2d36620ba4e4aa13b8c84684e1b4aab0cebea2ae45cb4d375b77eab56516d34bfbd3c1a833fc51296ff084b770b94fb9028c4d25ccf@52.169.42.101:30303 --rpc --rpcapi="personal,eth,network"
    ```

    Note that the credentials here `yournode:Respect my authoritah!` appear to be necessary.
    Unknown whether you can create your own creds on `stats.rinkeby.io` so that you can collect your own testnet mining stats :)

    SECURITY WARNINGS: We've enabled RPC and also loaded the `personal` module to allow testing and participating in smart contracts.
    However, if you do these things on a mainnet node with your unlocked wallet exposed to the internet, you could get hacked
    and all your monies stolen. I'll write a separate gist about a secure way to participate in a mainnet contract with real ETH.

    You can download Geth from https://geth.ethereum.org/downloads/.

    On a MacBook Air with a 10 MBps (standard home internet download speeds),
  4. Paul Pham created this gist May 14, 2017.
    136 changes: 136 additions & 0 deletions Rinkeby.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,136 @@
    How to get on Rinkeby Testnet in less than 10 minutes
    =====================================================

    Following instructions from the excellent
    https://www.rinkeby.io/

    # Synchronizing a Full Node

    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.
    ```


    ## Step 1: Download Geth
    First, download the latest geth (1.6.1) to your laptop.
    https://geth.ethereum.org/downloads/

    (I did it to my MacBook Air).
    Extract it and copy the `geth` binary to somewhere in your path.

    Unknown whether Parity works as well. It will probably take some finagling
    to work with the Geth-style Genesis block.

    ## Step 2: Download genesis block

    ```
    wget https://www.rinkeby.io/rinkeby.json
    ```

    ## Step 3: Initialize

    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, download rinkeby.json and start Geth with:

    ```
    geth --datadir=$HOME/.rinkeby init rinkeby.json
    geth --networkid=4 --datadir=$HOME/.rinkeby --cache=512 --ethstats='yournode:Respect my [email protected]' --bootnodes=enode://a24ac7c5484ef4ed0c5eb2d36620ba4e4aa13b8c84684e1b4aab0cebea2ae45cb4d375b77eab56516d34bfbd3c1a833fc51296ff084b770b94fb9028c4d25ccf@52.169.42.101:30303
    ```

    Note that the credentials here `yournode:Respect my authoritah!` appear to be necessary.
    Unknown whether you can create your own creds on `stats.rinkeby.io` so that you can collect your own testnet mining stats :)

    You can download Geth from https://geth.ethereum.org/downloads/.

    On a MacBook Air with a 10 MBps (standard home internet download speeds),
    I was able to sync all 187k blocks in < 7 minutes,

    ## Step 4: Create an account

    In a separate `tmux` pane or `screen` buffer or a separate terminal completely, create an account and save the password somewhere safe.

    First, symlink the IPC file so you can `geth attach` to the existing geth process.

    On Linux:
    ```
    mkdir -p ~/.ethereum
    ln -s ~/.rinkeby/geth.ipc ~/.ethereum/
    ```

    On Mac:
    ```
    mkdir -p ~/Library/Ethereum
    ln -s ~/.rinkeby/geth.ipc ~/Library/Ethereum
    ```

    After that, attach the console
    ```
    geth attach
    ```

    and create an account (substituting a much better password than `notmyrealpassword`.

    ```
    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"notmyrealpassword")
    "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.

    ## Step 5: Request ETH

    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) and submit a public gist.

    Go to `http://gist.github.com` and create a gist, pasting a single line into it which is your Rinkeby address.
    [Mine looks like this.](https://gist.github.com/cryptogoth/4e404fb58808a241f622afe80a659c05)

    Copy the address of the gist, e.g. https://gist.github.com/cryptogoth/4e404fb58808a241f622afe80a659c05
    Go to the `Crypto Faucet` section of https://rinkeby.io
    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/0xf54c0101b71c645032b786b4eb3f0f0402b665575d34903f5fd1c911aaa22ebb

    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
    ```

    Woohoo! You're rich, in testnet wei :)

    If you found this guide useful, follow us on Twitter at @InvisibleLearn
    or join us on Slack: http://invisible-slack.herokuapp.com/