diff --git a/ShyftNetwork.json b/ShyftNetwork.json index 9026cd1d6b..6c7897e487 100644 --- a/ShyftNetwork.json +++ b/ShyftNetwork.json @@ -16,24 +16,24 @@ "extraData": "0x0000000000000000000000000000000000000000000000000000000000000000", "gasLimit": "0x16E6387", "minGasLimit": "0x16E6387", - "difficulty": "0x000100000", + "difficulty": "0x000001000", "mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000", "coinbase": "0x0000000000000000000000000000000000000000", "alloc": { - "07d899c4ac0c1725c35c5f816e60273b33a964f7": { - "balance": "0x200000000000000000000000000000000000000000000000000000000000000" + "0x43EC6d0942f7fAeF069F7F63D0384a27f529B062" : { + "balance": "200000000000000000000" }, - "43ec6d0942f7faef069f7f63d0384a27f529b062": { - "balance": "0x200000000000000000000000000000000000000000000000000000000000000" + "0x9e602164C5826ebb5A6B68E4AFD9Cd466043dc4A" : { + "balance": "300000000000000000000" }, - "5bd738164c61fb50eb12e227846cbaef2de965aa": { - "balance": "0x200000000000000000000000000000000000000000000000000000000000000" + "0x5Bd738164C61FB50eb12E227846CbaeF2dE965Aa" : { + "balance": "400000000000000000000" }, - "9e602164c5826ebb5a6b68e4afd9cd466043dc4a": { - "balance": "0x200000000000000000000000000000000000000000000000000000000000000" + "0xC04eE4131895F1d0C294D508AF65D94060AA42BB" : { + "balance": "500000000000000000000" }, - "c04ee4131895f1d0c294d508af65d94060aa42bb": { - "balance": "0x200000000000000000000000000000000000000000000000000000000000000" + "0x07D899C4aC0c1725C35C5f816e60273B33a964F7" : { + "balance": "100000000000000000000" } }, "number": "0x0", diff --git a/config.toml b/config.toml new file mode 100644 index 0000000000..59df6f2ae8 --- /dev/null +++ b/config.toml @@ -0,0 +1,65 @@ +[Eth] +NetworkId = 1 +SyncMode = "fast" +LightPeers = 100 +DatabaseCache = 768 +Etherbase = "0x43ec6d0942f7faef069f7f63d0384a27f529b062" +GasPrice = 18000000000 +EnablePreimageRecording = false + +[Eth.Ethash] +CacheDir = "ethash" +CachesInMem = 2 +CachesOnDisk = 3 +DatasetDir = "/Users/fieldmagic/.ethash" +DatasetsInMem = 1 +DatasetsOnDisk = 2 +PowMode = 0 + +[Eth.TxPool] +NoLocals = false +Journal = "transactions.rlp" +Rejournal = 3600000000000 +PriceLimit = 1 +PriceBump = 10 +AccountSlots = 16 +GlobalSlots = 4096 +AccountQueue = 64 +GlobalQueue = 1024 +Lifetime = 10800000000000 + +[Eth.GPO] +Blocks = 20 +Percentile = 60 + +[Shh] +MaxMessageSize = 1048576 +MinimumAcceptedPOW = 2e-01 + +[Node] +UserIdent = "ShyftTestnetNode" +DataDir = "shyftData" +KeyStoreDir = "." +IPCPath = "geth.ipc" +HTTPHost = "127.0.0.1" +HTTPPort = 8545 +HTTPCors = ["*"] +HTTPVirtualHosts = ["localhost"] +HTTPModules = ["net", "web3", "eth", "shh"] +WSPort = 8546 +WSModules = ["net", "web3", "eth", "shh"] + +[Node.P2P] +MaxPeers = 25 +NoDiscovery = false +BootstrapNodes = ["enode://a979fb575495b8d6db44f750317d0f4622bf4c2aa3365d6af7c284339968eef29b69ad0dce72a4d8db5ebb4968de0e3bec910127f134779fbcb0cb6d3331163c@52.16.188.185:30303", "enode://3f1d12044546b76342d59d4a05532c14b85aa669704bfe1f864fe079415aa2c02d743e03218e57a33fb94523adb54032871a6c51b2cc5514cb7c7e35b3ed0a99@13.93.211.84:30303", "enode://78de8a0916848093c73790ead81d1928bec737d565119932b98c6b100d944b7a95e94f847f689fc723399d2e31129d182f7ef3863f2b4c820abbf3ab2722344d@191.235.84.50:30303", "enode://158f8aab45f6d19c6cbf4a089c2670541a8da11978a2f90dbf6a502a4a3bab80d288afdbeb7ec0ef6d92de563767f3b1ea9e8e334ca711e9f8e2df5a0385e8e6@13.75.154.138:30303", "enode://1118980bf48b0a3640bdba04e0fe78b1add18e1cd99bf22d53daac1fd9972ad650df52176e7c7d89d1114cfef2bc23a2959aa54998a46afcf7d91809f0855082@52.74.57.123:30303", "enode://979b7fa28feeb35a4741660a16076f1943202cb72b6af70d327f053e248bab9ba81760f39d0701ef1d8f89cc1fbd2cacba0710a12cd5314d5e0c9021aa3637f9@5.1.83.226:30303"] +BootstrapNodesV5 = ["enode://06051a5573c81934c9554ef2898eb13b33a34b94cf36b202b69fde139ca17a85051979867720d4bdae4323d4943ddf9aeeb6643633aa656e0be843659795007a@35.177.226.168:30303", "enode://0cc5f5ffb5d9098c8b8c62325f3797f56509bff942704687b6530992ac706e2cb946b90a34f1f19548cd3c7baccbcaea354531e5983c7d1bc0dee16ce4b6440b@40.118.3.223:30304", "enode://1c7a64d76c0334b0418c004af2f67c50e36a3be60b5e4790bdac0439d21603469a85fad36f2473c9a80eb043ae60936df905fa28f1ff614c3e5dc34f15dcd2dc@40.118.3.223:30306", "enode://85c85d7143ae8bb96924f2b54f1b3e70d8c4d367af305325d30a61385a432f247d2c75c45c6b4a60335060d072d7f5b35dd1d4c45f76941f62a4f83b6e75daaf@40.118.3.223:30307"] +StaticNodes = [] +TrustedNodes = [] +ListenAddr = ":31333" +EnableMsgEvents = false + +[Dashboard] +Host = "localhost" +Port = 8080 +Refresh = 5000000000 diff --git a/consensus/ethash/consensus.go b/consensus/ethash/consensus.go index 6ffe8740f5..63d824ec8d 100644 --- a/consensus/ethash/consensus.go +++ b/consensus/ethash/consensus.go @@ -31,6 +31,7 @@ import ( "github.com/ethereum/go-ethereum/core/state" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/params" + "github.com/ethereum/go-ethereum/log" set "gopkg.in/fatih/set.v0" ) @@ -553,7 +554,7 @@ func accumulateRewards(config *params.ChainConfig, state *state.StateDB, header r.Mul(r, blockReward) r.Div(r, big8) state.AddBalance(uncle.Coinbase, r) - + Initialised chain configuration r.Div(blockReward, big32) reward.Add(reward, r) } @@ -561,5 +562,6 @@ func accumulateRewards(config *params.ChainConfig, state *state.StateDB, header if (config.IsShyftNetwork(header.Number)) { state.AddBalance(ShyftNetworkConduitAddress, ShyftNetworkBlockReward) + log.Info("ShyftNetwork") } } diff --git a/geth.json b/geth.json index fa26f786b2..e446533a69 100644 --- a/geth.json +++ b/geth.json @@ -4,8 +4,7 @@ "homesteadBlock":0, "eip150Block":0, "eip155Block":10, - "eip158Block":10, - "eip160Block":10 + "eip158Block":10 }, "nonce": "0x0000000000000042", "alloc": { diff --git a/initShyftGeth.sh b/initShyftGeth.sh new file mode 100755 index 0000000000..c6a8d115e1 --- /dev/null +++ b/initShyftGeth.sh @@ -0,0 +1,2 @@ +#!/bin/sh +./build/bin/geth --identity "ShyftTestnetNode" --keystore ./ --datadir "./shyftData" init ShyftNetwork.json \ No newline at end of file diff --git a/resetShyftGeth.sh b/resetShyftGeth.sh new file mode 100755 index 0000000000..4d3eb577ab --- /dev/null +++ b/resetShyftGeth.sh @@ -0,0 +1,2 @@ +#!/bin/sh +rm -R ./shyftData \ No newline at end of file diff --git a/startShyftGeth.sh b/startShyftGeth.sh new file mode 100755 index 0000000000..7247e8e37a --- /dev/null +++ b/startShyftGeth.sh @@ -0,0 +1,2 @@ +#!/bin/sh +./build/bin/geth --config config.toml --nat=none --mine --minerthreads 4 --targetgaslimit 80000000 --unlock "0x43EC6d0942f7fAeF069F7F63D0384a27f529B062,0x9e602164C5826ebb5A6B68E4AFD9Cd466043dc4A,0x5Bd738164C61FB50eb12E227846CbaeF2dE965Aa,0xC04eE4131895F1d0C294D508AF65D94060AA42BB,0x07D899C4aC0c1725C35C5f816e60273B33a964F7" --password ./unlockPasswords.txt \ No newline at end of file diff --git a/unlockPasswords.txt b/unlockPasswords.txt new file mode 100644 index 0000000000..281413fde7 --- /dev/null +++ b/unlockPasswords.txt @@ -0,0 +1,5 @@ +123456 +123456 +123456 +123456 +123456 \ No newline at end of file