Skip links

Introduction to EZC staking

EZC (EZChain Coin) holders can participate in primary network staking as Delegators on EZChain mainnet.

A delegator is a token holder, who wants to participate in staking, but chooses to trust an existing validating node through delegation. Delegations are initiated through a special “addDelegator” transaction issued to the Platform Chain (P-Chain).

1. Token used for staking: EZC

2. Reward Token: EZC

3. The minimum amount of EZC staking: 25 EZC

4. The maximum amount of EZC staking: Unlimited

5. Reward payment method: the blockchain system will automatically the principal (the EZC you have staked) and the interest (the EZC you are rewarded) on the last day of the staking term.

6. Bonus Rate: is pegged when you start staking and valid throughout your staking cycle.

You can view the current reward rate data on P-chain’s Explorer : https://explorer.ezchain.com/validators. That is the number Annual Staking Reward (annual interest rate), and currently, it is ~ 50%.

The “Annual Staking Reward” will gradually decrease depending on the amount of “Total Staked” of the entire network.

So the sooner and longer you stake, the more profitable you will be. Because the “Annual Staking Reward” is high when the “Total Staked” of the entire network is still a tiny amount.

In addition, when you choose the amount of EZC that you intend to stake, the EZChain web wallet will also estimate for you the amount of bonus EZC that you will receive at the end of the period.

In the “Estimated Reward” section, as the example here is, when you Staking 1000 EZC within two months, you will receive a bonus of 83.56 EZC at the end of the period

7. Staking time: you can choose from 2 weeks to 1 year.

Note: if you select a long staking term, you will benefit more because the current “Annual Staking Reward” is high. If you choose a short time, then when that time is over, and you want to continue staking, the staking cycle will be the following ratio will be calculated according to the “Annual Staking Reward” rate at that time

Investors, please see the instructions here or attract file to perform the staking steps on the EZChain network. In addition, please contact the following email address for more information about the program for detailed instructions: [email protected]

Detailed instructions for EZC staking

EZChain is a multi-chain platform including X Chain, P Chain, and C Chain. P Chain is used to manage metadata, manage validator nodes, and user staking. Therefore, to participate in staking on EZChain, you need to have money in P-Chain.

Step 1: Swap EZC from C-Chain to P-Chain

EZChain Wallet supports the Cross Chain swap feature to transfer money between Chains.

1. On the home page on the left side of the screen, select Cross Chain

  • In the Source Chain section, select C Chain
  • In Destination Chain, select P Chain
  • Enter the amount you want to swap, then press Confirm

2. Select Transfer to complete the swap

When the transaction is completed, you will see the money in the Balance P-Chain.

Step 2: Perform Staking on EZChain using the Delegate feature

1. On the left side of the home screen, select Earn on the home page. Select Add Delegator

2. There is a list of validator nodes in the network that appears, along with the amount that can be delegated and the maximum time that can be staked on that validator node. Choose a node that suits your needs and click Select.

3. Fill in the staking delegate information. Then press Confirm.

Included:

  • Staking End Date section: choose the time you want to end Staking.
  • Staking Amount section: enter the amount of EZC you want to stake.

4. Check the information and select Submit.

After performing the delegate, you will have to wait about 15 minutes to complete this Staking.

Once done, you can check the reward information in the Estimate Reward section of the Earn tab.

How investors can withdraw EZC

Step 1: install Metamask and import/switch to your investor wallet that you registered with EZChain
Step 2: Access to smart-contract on Blockchain Explorer at: https://cchain- explorer.ezchain.com/address/wallet_addr/write- contract
Step 3: Click on Metamask icon on your browser and choose Connect to let Metamask know that you will use this Wallet to interact with smart-contract Token Vesting:

When successfully connected, you will see the following screen (Connect to )

Step 4: Click “ Write ” at 3. investorWithdraw (note: DO NOT click on any other functions)

Now Metamask will have a popup for you to confirm that the transaction will be made to interact with smart-contract Token Vesting:

Check if the smart-contract address is correct (under format 0x05E…1C0A), then click on Confirm

Step 5: wait for the transaction to be completed and check for EZC in your Wallet.

Run an EZChain Node

The quickest way to learn about EZChain is to run a node and interact with the network.

In this tutorial, we will:

  • Install and run an EZChain node
  • Connect to EZChain Mainnet

Requirements

EZChain is an incredibly lightweight protocol, so nodes can run on commodity hardware. Note that as network usage increases, hardware requirements may change.

  • CPU: Equivalent of 4 vCPU
  • RAM: 8 GiB
  • Storage: 80 GiB
  • OS: Ubuntu 20.04

Run an EZChain Node

Let’s install ezcgo, the Go implementation of an EZChain node, and connect to the EZChain Network

Download EZCGo

The node is a binary program, So you can download the pre-built binary for easier setup the node

- Create the folder and change current path to this folder to download ezcgo binaries:

mkdir -p /opt/ezchain && cd /opt/ezchain

- Download the binary of ezcgo with command:

wget https://ezchain-binary.sgp1.digitaloceanspaces.com/ezcgo-v1.1.tar.gz

- Extract the ezcgo binaries compress file:

tar xvf ezcgo-v1.1.tar.gz

- When extract success, you will see the ezcgo binary and the plugins folder - that contain the binary of evm:

Start a Node, and Connect to EZChain

- Start your own EZChain node with command:

./ezcgo --public-ip=<your_server_public_ip> --http-host 0.0.0.0 
--http-port=9650 --staking-port=9651 --db-dir=db/node 
--log-level=info --api-admin-enabled=true 
--http-allowed-origins='*'

When the node starts, it has to sync up (catch up with the rest of the network). You will see logs about syncing. When a given chain is done syncing, it will print a log like this:

INFO [03-21|05:22:32.031] <X Chain> snow/engine/ezcgo/transitive.go#292: bootstrapping finished with 1 vertices in the accepted frontier
INFO [03-21|05:22:32.044] <P Chain> snow/engine/snowman/transitive.go#329: bootstrapping finished with 8ndyi1P6SMdcCbgCk3RpHk3Bx6NumZk6ghrzooRSKhLqXE9Tr as the last accepted block
INFO [03-21|05:22:32.045] <C Chain> snow/engine/snowman/transitive.go#329: bootstrapping finished with 2BaVsniDKhYWfxemEPFS2eED923nc4jK328yiAinCQXFrG3H4u as the last accepted block

To check if a given chain is done syncing, in another terminal window call info.isBootstrapped by copying and pasting the following command:

curl -X POST --data '{
   "jsonrpc":"2.0",
   "id"     :1,
   "method" :"info.isBootstrapped",
   "params": {
       "chain":"X"
   }
}' -H 'content-type:application/json;' 127.0.0.1:9650/ext/info

If this returns true, the chain is synced with the network.

{"jsonrpc":"2.0","result":{"isBootstrapped":true},"id":1}

If you make an API call to a chain that is not done bootstrapping, it will return API call rejected because chain is not done syncing.

Your node is running and connected now.

You can use Ctrl + C to stop this node.

You can check your node ID with command:

curl --location --request POST '127.0.0.1:9650/ext/info' \
--header 'Content-Type: application/json' \
--data-raw '{
    "jsonrpc":"2.0",
    "id"     :1,
    "method" :"info.getNodeID",
    "params" :{
    }
}'

Sample response:

{
   "jsonrpc": "2.0",
   "result": {
       "nodeID": "NodeID-6JQD1WHeHQiyz9nYnrvJWVQ8rfTV6ybvt"
   },
   "id": 1
}

Add a validator with EZChain Wallet

When you have run EZChain node sucessfully and finish sync up with the rest of network, you can join your running node as a validator of EZChain network to take profit from validator rewards.

In this section, we’ll add your node to the Primary Network as a validator on EZChain.

DANGER

Note that once you issue the transaction to add a node as a validator, there is no way to change the parameters. You can’t remove your stake early or change the stake amount, node ID, or reward address. Please make sure you’re using the correct values in the API calls below.

Open EZChain Wallet by access to the web wallet address: https://wallet.ezchain.com/

Go to Earn tab and choose Add Validator:

Fill out the staking parameters. When you’ve filled in all the staking parameters and double-checked them, click Confirm.

The parameters include:

  1. Node ID: ID of the node you have run before, and get by call curl at previous section
  2. Staking End Date: time you want to end the staking process and get rewards
  3. Staking amount: Amount EZC you want to add to validator node to stake
  4. Delegation fee: fee that users who delegate to your node charge for you
  5. Reward address(Optional): the P-Chain address you want to receive reward after finish staking, default is the address of current wallet

Make sure the staking period is at least 2 weeks, the delegation fee rate is at least 2%, and you’re staking at least 2,000 EZC.

You should see this success message, and your balance should be updated.

Go back to the Earn tab, and click Estimated Rewards.

Once your validator’s start time has passed, you will see the rewards it may earn, as well as its start time, end time, and the percentage of its validation period that has passed.

All Done!

Backup your Node to keep the nodeID for disaster recovery

Once you have your node up and running, it's time to prepare for disaster recovery. Should your machine ever have a catastrophic failure due to either hardware or software issues, or even a case of natural disaster, it's best to be prepared for such a situation by making a backup.

When running, a complete node installation along with the database can grow to be multiple gigabytes in size. Having to back up and restore such a large volume of data can be expensive, complicated and time-consuming. Luckily, there is a better way.

Instead of having to back up and restore everything, we need to back up only what is essential, that is, those files that cannot be reconstructed because they are unique to your node. For EZChain node, unique files are those that identify your node on the network, in other words, files that define your NodeID.

Even if your node is a validator on the network and has multiple delegations on it, you don't need to worry about backing up anything else, because the validation and delegation transactions are also stored on the blockchain and will be restored during bootstrapping, along with the rest of the blockchain data.

The installation itself can be easily recreated by installing the node on a new machine, and all the remaining gigabytes of blockchain data can be easily recreated by the process of bootstrapping, which copies the data over from other network peers.

NodeID

NodeID is a unique identifier that differentiates your node from all the other peers on the network. It's a string formatted like NodeID-6JQD1WHeHQiyz9nYnrvJWVQ8rfTV6ybvt. In essence, NodeID is defined by two files:

  • staker.crt
  • staker.key

In the default installation, they can be found in the working directory, specifically in ~/.ezcgo/staking/. All we need to do to recreate the node on another machine is to run a new installation with those same two files.

Backup

To back up your node, we need to store staker.crt and staker.key files somewhere safe and private, preferably to a different computer, to your private storage in the cloud, a USB stick or similar. Storing them to a couple of different, secure locations increases the safety.

Let's get the staker files off the machine running the node.

From Local Node​

If you're running the node locally, on your desktop computer, just navigate to where the files are and copy them somewhere safe.

On a default Linux installation, the path to them will be ~/.ezcgo/staking/. Select and copy the files from there to a backup location. You don't need to stop the node to do that.

From Remote Node on cloud or somewhere else​

If you're running the node on Cloud Server, or Physical Server, you need to login to your server via SSH, or using some remote copy tool like: scp or rsync to get staker cert and key file to local machine to backup

When you have means of remote login into the machine, you can copy the files over with the following command:

scp -r [email protected]:/home/ubuntu/.ezcgo/staking ~/ezchain_backup

This assumes the username on the remote machine is ubuntu, replace with correct username in both places if it is different. Also, replace PUBLICIP with the actual public IP of the remote machine.

Restore​

To restore your node from a backup, we need to do the reverse: restore staker.key and staker.crt from the backup to the working directory of the node

First, we need to do the usual installation of the node like the . This will create a new NodeID, which we need to replace. When the node is installed correctly, log into the machine where the node is running and stop it.

Then copy the backup cert from local machine to remote machine:

scp ~/ezchain_backup/staker.* [email protected]:/home/ubuntu/.ezcgo/staking

Finally, re-run the EZChain Node. And then check the nodeID with curl call API:

curl -X POST --data '{
   "jsonrpc":"2.0",
   "id"     :1,
   "method" :"info.getNodeID"
}' -H 'content-type:application/json;' 127.0.0.1:9650/ext/info

All Done!

This website uses cookies to improve your web experience.