Skip to content

Instantly share code, notes, and snippets.

@zsfelfoldi
Last active October 14, 2015 12:11
Show Gist options
  • Save zsfelfoldi/25412c4cd285a2384345 to your computer and use it in GitHub Desktop.
Save zsfelfoldi/25412c4cd285a2384345 to your computer and use it in GitHub Desktop.
Instructions for trying the light client prototype
- download and compile my light branch:
https://github.com/zsfelfoldi/go-ethereum/tree/light
(better clone the entire branch, it will not work when pulled in current develop)
- run geth in light mode, with a new datadir and peer discovery disabled
./geth --mode "light" --datadir "~/.light" --nodiscover console
- add my node: (an archive node that supports the LES protocol)
admin.addPeer("enode://2b01f9b612bfb0e0dceb03cd3801a5f957169cc05422459bdac6a0a18a84ed290061a79fdccf8d5a572d47abd1aa6eab2044a795c5db6a45191c5b93bd15bbe2@195.38.100.244:30303")
- wait for a few minutes to download the header chain (sometimes it starts a bit slow but should speed up quickly)
- some examples to try: (our options are limited since transaction sending doesn't work yet through the LES protocol)
eth
eth.getBlock(12345)
eth.getBalance("7456c5b2c5436e3e571008933f1805ccfe34e9ec") // should return about 300 ETH
eth.getBalance("7456c5b2c5436e3e571008933f1805ccfe34e9ed") // non-existent address, should return 0
eth.getCode("db15058402c241b04a03846f6fb104b1fbeea10b") // a contract code
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment