A Practical Introduction to Blockchain

--

Within a blockchain infrastructure, we must create a genesis record, and which defines the starting point of the blockchain. This will contain the initial accounts that own cryptocurrency. Initially we can create an Ethereum blockchain using Geth with [Linux version]:

C:\Program Files\Geth> geth --datadir=d:\eth6 init customg.json
INFO [06-26|21:42:43] Allocated cache and file handles database=d:\\eth6
\\geth\\chaindata cache=16 handles=16
INFO [06-26|21:42:43] Writing custom genesis block
INFO [06-26|21:42:43] Successfully wrote genesis state database=chaindat
a hash=10367b.67437b
INFO [06-26|21:42:43] Allocated cache and file handles database=d:\\eth6
\\geth\\lightchaindata cache=16 handles=16
Fatal: Failed to write genesis block: database already contains an incompatible
genesis block (have 0c5f429f24f7078a, new 10367b56f68be716)

The genesis block is created with:

{
"config": {
"chainId": 15,
"homesteadBlock": 0,
"eip155Block": 0,
"eip158Block": 0
},
"difficulty": "200000000",
"gasLimit": "0x3d0900",
"alloc": {
"228041751ddb7365cc4bc75c4985d14d5db2432f": { "balance": "30000000" },
"cdfc92d1b5dd1c9ee1c9e2368abc86a193ae35a5": { "balance": "40000000" },
"c9c425ae15a0e66500ecf5b7a1c10c6ed35600b9": { "balance"…

--

--

Prof Bill Buchanan OBE FRSE
ASecuritySite: When Bob Met Alice

Professor of Cryptography. Serial innovator. Believer in fairness, justice & freedom. Based in Edinburgh. Old World Breaker. New World Creator. Building trust.