Author

Topic: CLONINING ETHEREUM IS EASIER THAN MAKING A CRYPTONOTE OR FORKNOTE (Here is How) (Read 258 times)

member
Activity: 98
Merit: 11
Video about how to create your own Ethereum Blockchain
https://www.youtube.com/watch?v=Vn73EX7zbCc
member
Activity: 98
Merit: 11
We are going to automate this process.
member
Activity: 98
Merit: 11



Method 1:

sudo apt-get install software-properties-common
sudo add-apt-repository -y ppa:ethereum/ethereum
sudo apt-get update
sudo apt-get install ethereum

If you want to stay on the bleeding edge, install the ethereum-unstable package instead.

After installing, run geth account new to create an account on your node.

You should now be able to run

geth

and connect to the network.


mkdir my-eth-chain
cd my-eth-chain

gedit myGenesis.json

Code:
{
    "config": {
        "chainId": 15,
        "homesteadBlock": 0,
        "eip155Block": 0,
        "eip158Block": 0
    },
    "difficulty": "0x400",
    "gasLimit": "0x2100000",
    "alloc": {
        "7a69b359e86893efa3d9732e4c65ced51567edd0":
         { "balance": "0x1337000000000000000000" }     
    }
}

    chainid: this provides a way to send transactions that work on ethereum without working on ETC (ethereum classic) or the Morden testnet. EIP 155 suggests following chainid values for different networks: ethereum mainnet (1), morden /expanse mainnet (2), ropsten (3), rinkeby (4), rootstock mainnet (30), rootstock testnet (31), kovan (42), ethereum classic mainnet (61), ethereum classic testnet (62), geth private chains (1337 by default). In our example we have used 15, which is not used by any of these networks.

    homesteadBlock: the value 0 indicates, it is using ethereum homestead release. Homestead is the 2nd major ethereum release — and couple of days back on 16th Oct, 2017, ethereum did a hard fork to move to the byzantium release.

    eip155Block: the value 0 indicates, this block supports EIP (ethereum improvement proposal)155. EIPs describe standards for the ethereum platform, including core protocol specifications, client APIs, and contract standards.

    eip158Block: the value 0 indicates, this block supports EIP (ethereum improvement proposal)158.

    difficulty: a value corresponding to the difficulty level applied during the nonce discovery of this block. In this blog I explain how the difficulty is calculated in ethereum, in detail.

    gasLimit: gas is the internal pricing for running a transaction or contract in ethereum. Each instruction sent to the Ethereum Virtual Machine (EVM) to process a transaction or smart contract costs a specific amount of gas. If the required amount of gas is not provided to the transaction, it will fail before completion. When you do any ethereum transaction, you specify a gas limit — that is the maximum gas all the operations corresponding to that transaction can consume. The gasLimit parameter in the block specifies, the aggregated gasLimit from all the transactions included in the block.

    alloc: this allows to pre-allocate ether to one or more accounts from the genesis block. In the above genesis block, the pre-allocation is done to the account we created at the begining.


geth --mine --rpc --networkid 1999 --datadir

(CHANGE THE 1999 VALUE)

    networkid: network identifier of this ethereum network. You pick a value you want. For example: olympic (0), frontier (1), morden (2), ropsten(3).

    mine: enables mining.

    rpc: enables an HTTP-RPC server. Wallet applications can connect to this mining node over http.

    rpcaddr: specifies the HTTP-RPC server listening interface (default: “localhost”)

    rpcport: specifies the HTTP-RPC server listening port (default: 8545)

    rpcapi: specifies the API’s offered over the HTTP-RPC interface (default: “eth,net,web3”)


--rpcapi "web3,eth"

--rpccorsdomain "*"

geth --mine --rpc --networkid 1999 --datadir /path/to/data/dir console

geth --datadir /path/to/data/dir attach ipc:/path/to/data/dir /geth.ipc

> eth.accounts
["0x7a69b359e86893efa3d9732e4c65ced51567edd0"]

> eth.getBalance("0x7a69b359e86893efa3d9732e4c65ced51567edd0")
1.295e+21

Download MetaMask
https://metamask.io/

> personal.unlockAccount( "0x7a69b359e86893efa3d9732e4c65ced51567edd0","password")

> var sender = "0x7a69b359e86893efa3d9732e4c65ced51567edd0";
> var receiver = "0xA9f28458eE1170F285440990c196c1592D3a73f5"
> var amount = web3.toWei(1, "ether")

> eth.sendTransaction({from:sender, to:receiver, value: amount})

> eth.getBalance("0xA9f28458eE1170F285440990c196c1592D3a73f5")
1000000000000000000

https://remix.ethereum.org/

geth --mine --rpc --rpccorsdomain "*" --networkid 1999 --datadir

To connect, remix to our private network, we need to change the Environment to Web3 Provider, under the tab Run. When you do this change, remix will prompt you to specify the Web3 Provider Endpoint — set the value http://localhost:8545. Unless you have changed the port explicitly, the default mining node will start on the port 8545.

Code:
pragma solidity ^0.4.11;
contract Hello  {
      // a string variable
      string public greeting;

    // the function with the same name as the class is a constructor
     function Hello(string _greeting) {
         greeting = _greeting;
     }
 
     // change the greeting message
     function setGreeting(string _greeting) {
         greeting = _greeting;
     }
 
     // get the greeting message
     function greet() constant returns (string _greeting) {
        _greeting = greeting;
     }
 }

Click the Details button

Now we can deploy our smart contract to our private blockchain. Under the Run tab, make sure you have the right ethereum account selected, and then the right gas limit is specified. You can keep gas price and value as zero.

> personal.unlockAccount( "0x7a69b359e86893efa3d9732e4c65ced51567edd0","password")

Click "Create"

member
Activity: 98
Merit: 11
Also, while I was first learning how to make Coins, I found this Compiler Scrypt
https://github.com/MahatmaJapa/AltcoinCompiler

And we are planning on creating more of those, if anyone wants to start going through all of our stuff and automating the process, we are going to start making it where people can just go on a Website, fill in some things, click "Build" or whatever, and a Coin pops out the other side.

And we are going to do it for a lot of different kinds of Coins.
member
Activity: 98
Merit: 11
member
Activity: 98
Merit: 11
I just found this Ethereum Guide that explains setting up the Blockchain, choosing your Ethereum Release you want to use, creating a Wallet, making Smart Contacts, and making a Block Explorer.
https://medium.facilelogin.com/build-your-own-blockchain-b8eaeea2f891

So Akasha आकाश will exist soon. We will launch it within a week or so.
member
Activity: 98
Merit: 11
Btw, we are doing Graphene next.


Quote
Obtaining and Running Graphene

Graphene is Open Source software available on GitHub. The root repository may be found at the Cryptonomex site. There are three projects to be cloned: graphene, graphene-ui, and fc. OCI’s GitHub page includes forks of graphene and graphene-ui, which serve as our research base repository. You may clone OCI’s copy of graphene by visiting https://github.com/objectcomputing/graphene and https://github.com/objectcomputing/graphene-ui
Comprehensive build and deploy instructions for both kits are included in their respective Readme.md file.

Graphene ships with three executables: the witness_node, cli_wallet, and genesis_util. Once built, you can try running a witness node. Note this example shows how to run the witness node with command line options. 

Code:
dhcp19:graphene phil$ cd programs/witness_node
dhcp19:witness_node phil$ ./witness_node --rpc-endpoint 127.0.0.1:8090 --enable-stale-production -w '"1.6.0"'
2560491ms th_a       main.cpp:126                  main                 ] Writing new config file at /tao_builds/phil/projects/blockchain/phil/graphene/programs/witness_node/witness_node_data_dir/config.ini
2560511ms th_a       witness.cpp:89                plugin_initialize    ] witness plugin:  plugin_initialize() begin
2560511ms th_a       witness.cpp:99                plugin_initialize    ] key_id_to_wif_pair: ["GPH6MRyAjQq8ud7hVNYcfnVPJqcVpscN5So8BhtHuGYqET5GDW5CV","5KQwrPbwdL6PhXujxW37FSSQZ1JiwsST4cqQzDeyXtP79zkvFD3"]
2560511ms th_a       witness.cpp:117               plugin_initialize    ] witness plugin:  plugin_initialize() end
2560512ms th_a       application.cpp:357           startup              ] Replaying blockchain due to version upgrade
2560512ms th_a       application.cpp:254           operator()           ] Initializing database...
2560518ms th_a       db_management.cpp:51          reindex              ] reindexing blockchain
2560518ms th_a       db_management.cpp:104         wipe                 ] Wiping database
2560549ms th_a       object_database.cpp:87        wipe                 ] Wiping object database...
2560549ms th_a       object_database.cpp:89        wipe                 ] Done wiping object databse.
2560549ms th_a       object_database.cpp:94        open                 ] Opening object database from /tao_builds/phil/projects/blockchain/phil/graphene/programs/witness_node/witness_node_data_dir/blockchain ...
2560549ms th_a       object_database.cpp:100       open                 ] Done opening object database.
2560560ms th_a       db_debug.cpp:85               debug_dump           ] total_balances[asset_id_type()].value: 0 core_asset_data.current_supply.value: 1000000000000000
2560560ms th_a       db_management.cpp:58          reindex              ] !no last block
2560560ms th_a       db_management.cpp:59          reindex              ] last_block: 
2560562ms th_a       thread.cpp:95                 thread               ] name:ntp tid:123145365336064
2560562ms th_a       thread.cpp:95                 thread               ] name:p2p tid:123145366409216
2560566ms th_a       application.cpp:143           reset_p2p_node       ] Configured p2p node to listen on 0.0.0.0:64207
2560568ms th_a       application.cpp:195           reset_websocket_serv ] Configured websocket rpc to listen on 127.0.0.1:8090
2560568ms th_a       witness.cpp:122               plugin_startup       ] witness plugin:  plugin_startup() begin
2560568ms th_a       witness.cpp:129               plugin_startup       ] Launching block production for 1 witnesses.
 
********************************
*                              *
*   ------- NEW CHAIN ------   *
*   - Welcome to Graphene! -   *
*   ------------------------   *
*                              *
********************************
 
Your genesis seems to have an old timestamp
Please consider using the --genesis-timestamp option to give your genesis a recent timestamp
 
2560568ms th_a       witness.cpp:140               plugin_startup       ] witness plugin:  plugin_startup() end
2560568ms th_a       main.cpp:179                  main                 ] Started witness node on a chain with 0 blocks.
2560568ms th_a       main.cpp:180                  main                 ] Chain ID is 0e435e3d20d8efa4e47fae56707a460e35c034aa2b0848e760e51beb13b3db04

After you get the node running, you can connect to the node using the cli_wallet. In a second terminal window, run the command line wallet application.

Code:
dhcp19:graphene phil$ cd program/cli_wallet
dhcp19:cli_wallet phil$ ./cli_wallet
Logging RPC to file: logs/rpc/rpc.log
2838642ms th_a       main.cpp:120                  main                 ] key_to_wif( committee_private_key ): 5KCBDTcyDqzsqehcb52tW5nU6pXife6V2rX9Yf7c3saYSzbDZ5W
2838649ms th_a       main.cpp:124                  main                 ] nathan_pub_key: GPH6MRyAjQq8ud7hVNYcfnVPJqcVpscN5So8BhtHuGYqET5GDW5CV
2838650ms th_a       main.cpp:125                  main                 ] key_to_wif( nathan_private_key ): 5KQwrPbwdL6PhXujxW37FSSQZ1JiwsST4cqQzDeyXtP79zkvFD3
Starting a new wallet with chain ID 0e435e3d20d8efa4e47fae56707a460e35c034aa2b0848e760e51beb13b3db04 (from egenesis)
2838655ms th_a       main.cpp:172                  main                 ] wdata.ws_server: ws://localhost:8090
2838726ms th_a       main.cpp:177                  main                 ] wdata.ws_user:  wdata.ws_password: 
Please use the set_password method to initialize a new wallet before continuing
2838792ms th_a       thread.cpp:95                 thread               ] name:getline tid:123145506545664
new >>>

At this point, you can use the help command to explore how to use the wallet interface.
member
Activity: 98
Merit: 11



Method 1:

sudo apt-get install software-properties-common
sudo add-apt-repository -y ppa:ethereum/ethereum
sudo apt-get update
sudo apt-get install ethereum

If you want to stay on the bleeding edge, install the ethereum-unstable package instead.

After installing, run geth account new to create an account on your node.

You should now be able to run

geth

and connect to the network.

Make sure to check the different options and commands with geth --help

Download this and put it in a folder
https://raw.githubusercontent.com/ethereum/genesis_block_generator/master/mk_genesis_block.py

python mk_genesis_block.py --extradata hash_for_#1028201_goes_here > genesis_block.json

https://forum.ethereum.org/discussion/2571/python-error-when-trying-to-create-genesis-block

python mk_genesis_block.py --extradata 0x11bbe8db4e347b4e8c937c1c8370e4b5ed33adb3db69cbdb7a38e1e50b1b82fa > genesis_block.json

If you can get through the errors there, then go here:
https://blog.ethereum.org/2015/07/27/final-steps/

Method 2: (Requires you to try method 1 at least 1 time through so you have everything installed, but you have to close that Window that Started Mining)

If not, now you have everything you need to do it this way

mkdir my-eth-chain
cd my-eth-chain

gedit myGenesis.json

put this in that file
Code:
{
   "config": {
      "chainId": 1994,
      "homesteadBlock": 0,
      "eip155Block": 0,
      "eip158Block": 0,
      "byzantiumBlock": 0
   },
   "difficulty": "400",
   "gasLimit": "2000000",
   "alloc": {
      "7b684d27167d208c66584ece7f09d8bc8f86ffff": {
          "balance": "100000000000000000000000"
      },
      "ae13d41d66af28380c7af6d825ab557eb271ffff": {
          "balance": "120000000000000000000000"
      }
   }
}

geth --datadir ./myDataDir init ./myGenesis.json

geth --datadir ./myDataDir --networkid 1114 console 2>> myEth.log

(CHANGE THE 1114 to something else)

    Open another terminal window

    cd to my-eth-chain

    Type tail -f myEth2.log

    In the geth JavaScript console of your 1st peer (back to the other terminal window), type:


> personal.newAccount("")

> eth.coinbase

Check your balance with
> eth.getBalance(eth.coinbase)
Run
> miner.start()


Then go here:
https://blog.ethereum.org/2015/07/27/final-steps/

what do you mean with cloning ethereum?

do you mean you double etheruem out of nothing?

No, creating a New Blockchain and Genesis Block and everything.

I am about to show to create a Token on the Private Blockchain also.
sr. member
Activity: 1470
Merit: 325



Method 1:

sudo apt-get install software-properties-common
sudo add-apt-repository -y ppa:ethereum/ethereum
sudo apt-get update
sudo apt-get install ethereum

If you want to stay on the bleeding edge, install the ethereum-unstable package instead.

After installing, run geth account new to create an account on your node.

You should now be able to run

geth

and connect to the network.

Make sure to check the different options and commands with geth --help

Download this and put it in a folder
https://raw.githubusercontent.com/ethereum/genesis_block_generator/master/mk_genesis_block.py

python mk_genesis_block.py --extradata hash_for_#1028201_goes_here > genesis_block.json

https://forum.ethereum.org/discussion/2571/python-error-when-trying-to-create-genesis-block

python mk_genesis_block.py --extradata 0x11bbe8db4e347b4e8c937c1c8370e4b5ed33adb3db69cbdb7a38e1e50b1b82fa > genesis_block.json

If you can get through the errors there, then go here:
https://blog.ethereum.org/2015/07/27/final-steps/

Method 2: (Requires you to try method 1 at least 1 time through so you have everything installed, but you have to close that Window that Started Mining)

If not, now you have everything you need to do it this way

mkdir my-eth-chain
cd my-eth-chain

gedit myGenesis.json

put this in that file
Code:
{
   "config": {
      "chainId": 1994,
      "homesteadBlock": 0,
      "eip155Block": 0,
      "eip158Block": 0,
      "byzantiumBlock": 0
   },
   "difficulty": "400",
   "gasLimit": "2000000",
   "alloc": {
      "7b684d27167d208c66584ece7f09d8bc8f86ffff": {
          "balance": "100000000000000000000000"
      },
      "ae13d41d66af28380c7af6d825ab557eb271ffff": {
          "balance": "120000000000000000000000"
      }
   }
}

geth --datadir ./myDataDir init ./myGenesis.json

geth --datadir ./myDataDir --networkid 1114 console 2>> myEth.log

(CHANGE THE 1114 to something else)

    Open another terminal window

    cd to my-eth-chain

    Type tail -f myEth2.log

    In the geth JavaScript console of your 1st peer (back to the other terminal window), type:


> personal.newAccount("")

> eth.coinbase

Check your balance with
> eth.getBalance(eth.coinbase)
Run
> miner.start()


Then go here:
https://blog.ethereum.org/2015/07/27/final-steps/

what do you mean with cloning ethereum?

do you mean you double etheruem out of nothing?
member
Activity: 98
Merit: 11
And apparently, the way to get consensus is to have your Genesis.json file put into your Ethereum Wallet. And it will turn the old Wallet into a Wallet for your Blockchain.
member
Activity: 98
Merit: 11
geth --datadir path/to/custom/data/folder --networkid 15 --bootnodes

$ geth --mine --minerthreads=1 --etherbase=0x0000000000000000000000000000000000000000
member
Activity: 98
Merit: 11
bootnode --genkey=boot.key
bootnode --nodekey=boot.key

To get your Public URL for everyone
member
Activity: 98
Merit: 11



Method 1:

sudo apt-get install software-properties-common
sudo add-apt-repository -y ppa:ethereum/ethereum
sudo apt-get update
sudo apt-get install ethereum

If you want to stay on the bleeding edge, install the ethereum-unstable package instead.

After installing, run geth account new to create an account on your node.

You should now be able to run

geth

and connect to the network.

Make sure to check the different options and commands with geth --help

Download this and put it in a folder
https://raw.githubusercontent.com/ethereum/genesis_block_generator/master/mk_genesis_block.py

python mk_genesis_block.py --extradata hash_for_#1028201_goes_here > genesis_block.json

https://forum.ethereum.org/discussion/2571/python-error-when-trying-to-create-genesis-block

python mk_genesis_block.py --extradata 0x11bbe8db4e347b4e8c937c1c8370e4b5ed33adb3db69cbdb7a38e1e50b1b82fa > genesis_block.json

If you can get through the errors there, then go here:
https://blog.ethereum.org/2015/07/27/final-steps/

Method 2: (Requires you to try method 1 at least 1 time through so you have everything installed, but you have to close that Window that Started Mining)

If not, now you have everything you need to do it this way

mkdir my-eth-chain
cd my-eth-chain

gedit myGenesis.json

put this in that file
Code:
{
   "config": {
      "chainId": 1994,
      "homesteadBlock": 0,
      "eip155Block": 0,
      "eip158Block": 0,
      "byzantiumBlock": 0
   },
   "difficulty": "400",
   "gasLimit": "2000000",
   "alloc": {
      "7b684d27167d208c66584ece7f09d8bc8f86ffff": {
          "balance": "100000000000000000000000"
      },
      "ae13d41d66af28380c7af6d825ab557eb271ffff": {
          "balance": "120000000000000000000000"
      }
   }
}

geth --datadir ./myDataDir init ./myGenesis.json

geth --datadir ./myDataDir --networkid 1114 console 2>> myEth.log

(CHANGE THE 1114 to something else)

    Open another terminal window

    cd to my-eth-chain

    Type tail -f myEth2.log

    In the geth JavaScript console of your 1st peer (back to the other terminal window), type:


> personal.newAccount("")

> eth.coinbase

Check your balance with
> eth.getBalance(eth.coinbase)
Run
> miner.start()


Then go here:
https://blog.ethereum.org/2015/07/27/final-steps/
Jump to: