geth
Posted TIM
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了geth相关的知识,希望对你有一定的参考价值。
277d8B4B449DE861cF1761DC39Bd723dcA58da2a
geth console 2>>geth.log
personal.newAccount()
eth.accounts
eth.getBalance(eth.accounts[0])
eth.blockNumber
eth.getBlock(180)
miner.setEtherbase(eth.accounts[1])
miner.start(2)
var tx = {from: eth.accounts[1], to: eth.accounts[0], value: web3.toWei(1, "ether")}
personal.sendTransaction(tx, "long2014")
eth.getTransaction("0x4f6d36a65aa6a17cb064f93012e221bce6c7aa51a453a05f7696de432086164c");
geth --datadir data init genesis.json
geth --datadir data --networkid 2 console 2>>geth.log --dev --dev.period=1
{
"config": {
"chainId": 10,
"homesteadBlock": 0,
"eip155Block": 0,
"eip158Block": 0
},
"coinbase" : "0x0000000000000000000000000000000000000000",
"difficulty" : "0x20000",
"extraData" : "",
"gasLimit" : "0xffffffff",
"nonce" : "0x0000000000000042",
"mixhash" : "0x0000000000000000000000000000000000000000000000000000000000000000",
"parentHash" : "0x0000000000000000000000000000000000000000000000000000000000000000",
"timestamp" : "0x00",
"alloc" : {}
}
以上是关于geth的主要内容,如果未能解决你的问题,请参考以下文章