I started a private network with Geth.
Geth 1.5.9-stable
, Windows 10
. Here is My genesis.json
:
{
"nonce": "0x0000000000000042",
"timestamp": "0x0",
"parentHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
"extraData": "0x0",
"gasLimit": "0x8000000",
"difficulty": "0x400",
"mixhash": "0x0000000000000000000000000000000000000000000000000000000000000000",
"coinbase": "0x3333333333333333333333333333333333333333",
"alloc": {
"0x0a53521645e1F9380989ce3F55aF0d8A0f902DAb": {
"balance": "1000000000000000000000000000000"
}
}
}
Then I created two different folder for blockhains:
geth --datadir "C:\Ethereum\TestChains\1" init "C:\Users\user1\Desktop\Ethereum\genesis_1.json"
geth --datadir "C:\Ethereum\TestChains\2" init "C:\Users\user1\Desktop\Ethereum\genesis_1.json"
Then I started running two nodes. One of them with --mine
key:
geth --maxpendpeers=5 --nodiscover --networkid "15985" --datadir "C:\Ethereum\TestChains\1" --port 30304 --rpcport 18999 console
geth --maxpendpeers=5 --nodiscover --networkid "15985" --datadir "C:\Ethereum\TestChains\2" --port 30305 --ipcdisable --mine --minerthreads=2 --etherbase="0x0a53521645e1F9380989ce3F55aF0d8A0f902DAb" console
And finally I adds peer manualy:
admin.addPeer("enode://ec491fe874bcba129add0fab1b3a3a30109fefb5cb1b8497ed1397a1f6a5de54da2c3097cfde4cfc32f3d3297bfb679c7c13948583fe50f7d31d310affe1e112@127.0.0.1:30305")
Both nodes shows "neighboring nodes" by admin.peers
command.
I runs EthereumWallet (Mist) and I see one neighboring peer -
Troubles and qustions:
1)
Transaction not works. I send 1000 eth by EthereumWallet, I see this transaction in Geth , but a few minutes later I see in log
I0322 12:42:41.765915 internal/ethapi/api.go:1026] receipt not found for transaction 0x7811d28051834923f4e4fefe672dfa3bbebcc9876faf336e317e6ff3652be4f5
2) (already solved below)
Geth witn --mine key constantly doing something. This log-messages is every few seconds raised by Geth - I0321 11:12:13.857226 miner/worker.go:517] commit new work on block 624 with 0 txs & 0 uncles. Took 0s
.
He constantly creates new empty blocks (0 txs & 0 uncles
). Why? And why He do not creates a block with My transaction?