29

I'm trying out Proof-of-Authority in Geth 1.6 for my private network and got it to work on a few nodes using Puppeth.

Now, I have two questions about maintain the private network as the network grows larger over time.

  1. How do I add more sealer accounts in the future? Since, the sealer account are specified on the Genesis block. (Does Clique's Proposal has anything to do with this?)

  2. It seems that there's no block reward generate to the sealer like what happens with the conventional PoW miner. Are there any settings to adjust the block reward?

Any help is appreciated.

1
  • 1
    @Péter Szilágyi could you elaborate more on RPC call clique_propose or just a code snippet to understand the code?? May 31, 2018 at 10:19

3 Answers 3

33

The protocol defines a voting mechanism to dynamically add new signers and remove existing ones. In Geth this can be controlled via the clique.propose(address, authorized) method (clique_propose for remote RPC calls).

To authorize a new signer, existing ones can propose it via clique.propose("0x...", true). When more than half the signers proposed it, the authorization comes into effect immediately and the new account can start signing blocks.

Similarly, existing signers can propose deauthorizing existing ones via clique.propose("0x...", false). Again if half + 1 signers deauthorize a signer, it is immediately removed from the list and blocks minted by it are rejected from that point onward.


The protocol defines that the block reward is zero (and similarly there can't be any uncles). The block and uncle rewards are a subsidy for the effort wasted on PoW. Since Clique is based on PoA, there's zero cost to minting a block, so there shouldn't be any "reward" for doing it either.

Running transactions of course may incur a tiny processing time, but the sealer does get the transaction fees in exchange, so that should cover it.

All in all however note, that PoA is meant for more of a collaborative environments where miners don't try to race each other, rather attempt to play together for a common goal of keeping the network ticking.

4
8

Clique commands

Sealer on a PoA is like a miner on PoW. You start a sealer with geth --mine --unlock "0xa132432bf" with a genesis using the clique consensus. The initial sealers are defined in the genesis block.

  • list sealers clique.getSigners()
  • list propositions: clique.proposals
  • discard a proposition: clique.discard("0x1234234234234")
  • add a new sealer: clique.propose("0x1234243214312", true)
  • remove a sealer: clique.propose("0x1234243214312", false)

So if you want to add a new sealer: you must use geth attach on > 50% of your sealers. Do a proposition with clique.propose. Wait few minutes and check state with clique.getSigners(). When the operation is completed, you can discard your proposition with clique.discard.

PS: you must use clique commands on sealers.

4

The above answers say to type clique.propose, but they do not say where. You must attach to geth.ipc and then you can use the clique.propose("0x...",true) command. You might be able to specifically enable clique through the rpc command as well.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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