3

I started parity node in dev network using this command

parity --jsonrpc --jsonrpc-port 8180 --chain dev --author * --geth

the author is the address of my parity node client

and then I start mining by starting ethminer

ethminer -F http://localhost:8180

I supposed that after mining started my account can gain some ether but I didn't received any ether.

Can you help how can I run private ethereum blockchain using parity and gain some ether for some testing on sending transactions and deploying smart contracts?

1

The address created with an empty phrase contains a lot of tokens that can be used to send transactions, it can be created with UI or a RPC call (make sure to enable the --jsonrpc-apis parity_accounts API):

curl -H "Content-Type: application/json" -X POST --data '{"jsonrpc":"2.0","method":"parity_newAccountFromPhrase","params":["","password"],"id": 1}' localhost:8545

or using the UI:

  1. Go to http://127.0.0.1:8080 in your browser and go through the initial setup.
  2. Click on "NEW ACCOUNT".
  3. Pick "Recover account from recovery phrase".
  4. Leave the phrase empty and fill the other fields.
  5. Go to the newly created account and click "TRANSFER" to conduct your first transaction.
  6. Confirm with a password picked earlier.
  7. A block should get sealed (see in the log) straight away.

No need to create a custom genesis.

Note: I work for Parity.

  • I get {"jsonrpc":"2.0","error":{"code":-32601,"message":"Method not found","data":null},"id":1} error when using curl and UI version seems to have changed, ACCOUNTS -> +RESTORE. I have tokens now but I still can't mine to my author address using ethminer, why? it's 6 blocks deep now. – d9ngle Jul 23 '17 at 7:51
0

To get ethers in your private chain you could preallocate them in the genesis file

    "accounts": {
.
.
.
.

            "0x00a329c0648769a73afac7f9381e08fb43dbea72": { "balance": "1606938044258990275541962092341162602522202993782792835301376" }
        }
  • The dev chain is already preloaded on the account which can be recovered from an empty phrase. – soc1c May 3 '17 at 8:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.