Croeseid 5 Testnet: Running Nodes
Croeseid 5 Testnet is Cronos PoS Chain Testnet. It is a new chain based on Croeseid Testnet and runs in parallel with Croeseid 4. It serves as an alpha testnet for exploring new features, instead of the upgraded version of Croeseid 4 testnet.
This is detailed documentation for setting up a Validator or a full node on Cronos PoS Croeseid 5 testnet testnet-croeseid-5
.
Pre-requisites
Supported OS
We officially support macOS, Windows, and Linux only. Other platforms may work but there is no guarantee. We will extend our support to other platforms after we have stabilized our current architecture.
Prepare your machine
To run Cronos PoS Chain nodes in the testnet, you will need a machine with the following minimum requirements:
Archive Node:
RAM: 16GB (goleveldb)
Disk: 281GB
CPU: 4 cores
Default pruned node
RAM 16GB (goleveldb)
Disk: 83GB (Depends on how long the node is running for)
CPU: 4 cores
Step 1. Get the Cronos PoS Chain testnet binary
Remarks: The following is the minimal setup for a validator node.
Reminder: The binary for testnet and the binary for mainnet are two different binaries. Please make sure you are using the correct binary.
To simplify the following step, we will be using Linux (Intel x86) for illustration. Binary for Mac (Intel x86 / M1 and Windows are also available.
To install Cronos PoS Chain released testnet binaries from GitHub:
You can verify the installation by checking the version of the chain-maind, the current version is
4.2.2-croeseid
.
Reminder: For macOS users: the binary is not signed, you have to follow the steps here to make the binary runnable.
Step 2. Configure chain-maind
chain-maind
Before kick-starting your node, we will have to configure your node so that it connects to the Croeseid testnet:
Step 2-0 (Optional) Clean up the old blockchain data
If you would like to clean up the old blockchain data for Croeseid Testnet and start over again, it can be done by running:
and remove the old Genesis file by
You can not override the previous validator through
chain-maind init
. If you want to have a new validator, you need to manually remove thepriv_validator_key.json
:Then, in Step 2-1,
chain-maind init
should help you to generate a new validator key file.
Step 2-1 Initialize chain-maind
chain-maind
First of all, you can initialize chain-maind by:
This
moniker
will be the displayed ID of your node when connected to the Cronos PoS Chain network. When providing the moniker value, make sure you drop the square brackets since they are not needed. The example below shows how to initialize a node namedpegasus-node
:NOTE:
Depending on your chain-maind home setting, the chain-maind configuration will be initialized to that home directory. To simplify the following steps, we will use the default chain-maind home directory
~/.chain-maind/
for illustration.You can also put the
chain-maind
to your binary path and run it bychain-maind
Step 2-2 Configure chain-maind
Download and replace the Croeseid Testnet
genesis.json
by:In
~/.chain-maind/config/app.toml
, update minimum gas price to avoid transaction spammingFor network configuration, in
~/.chain-maind/config/config.toml
, please modify the configurations ofpersistent_peers
,create_empty_blocks_interval
andtimeout_commit
by:
Note: We suggest using persistent_peers
instead of seeds
to provide a stable state-sync experience.
Step 2-3 Enable STATE-SYNC
STATE-SYNC is supported in our testnet.
With state sync, your node will download data related to the head or near the head of the chain and verify the data. This leads to drastically shorter times for joining a network for validator.
However, you should keep in mind that the block before state-sync trust height
will not be queryable. So if you want to run a full node, better not use state-sync feature to ensure your node has every data on the blockchain network.
For validator, it will be fast to sync the near head of the chain and join the network.
Follow the below optional steps to enable state-sync.
For state-sync configuration, in
~/.chain-maind/config/config.toml
, please modify the configurations of [statesync]enable
,rpc_servers
,trust_height
andtrust_hash
by:NOTE:
For Mac environment, if
jq
is missing, you may install it by:brew install jq
Step 3. Run everything
CAUTION
This page only shows the minimal setup for a validator node.
Furthermore, you may want to run full nodes as sentries (see Tendermint), restrict your validator connections to only connect to your full nodes, test secure storage of validator keys, etc.
Step 3-1. Create a new key and address
Run the following to create a new key. For example, you can create a key with the name Default
by:
You should obtain an address with tcro
prefix, e.g. tcro1quw5r22pxy8znjtdkgqc65atrm3x5hg6vycm5n
. This will be the address for performing transactions.
Step 3-2. Obtain test token
Croeseid 5 faucet is on the way. If you need testing tokens, you can send a message on Discord #request-tcro-croeseid channel, stating who you are and your tcro.....
address for Croeseid 5.
Step 3-3. Obtain the validator public key
You can obtain your validator public key by:
The public key should be in a json format, for example:
Step 3-4. Run everything
Once the chain-maind
has been configured, we are ready to start the node and sync the blockchain data:
Start chain-maind, e.g.:
Remarks: If you see errors saying too many files opened...
, then you need to set a higher number for maximum open file descriptors in your OS.
If you are on OSX or Linux, then the following could be useful:
(Optional for Linux) Start chain-maind with systemd service, e.g.:
Example: /etc/systemd/system/chain-maind.service created by script
It should begin fetching blocks from the other peers. Please wait until it is fully synced before moving onto the next step.
You can query the node syncing status by
If the above command returns
false
, It means that your node is fully synced; otherwise, it returnstrue
and implies your node is still catching up.One can check the current block height by querying the public full node by:
and you can check your node's progress (in terms of block height) by
Step 3-5. Send a create-validator
transaction
create-validator
transactionOnce the node is fully synced, we are now ready to send a create-validator
transaction and join the network, for example:
You will be required to insert the following:
--from
: Thetrco...
address that holds your funds;--pubkey
: The validator public key( See Step 3-3 above );--moniker
: A moniker (name) for your validator node;--security-contact
: Security contact email/contact method.
Step 3-6. Check your validator status
Once the create-validator
transaction completes, you can check if your validator has been added to the validator set:
To further check if the validator is signing blocks, kindly run this script, for example:
Alternatively, you can run it on this browser based IDE, by specifying your validator public key in the "YOUR_PUBKEY"
field, where this key can be obtained by running
Step 4. Perform Transactions
Step 4-1. query bank balances
- Check your transferable balance
query bank balances
- Check your transferable balanceYou can check your transferable balance with the balances
command under the bank module.
Example: Check your address balance
Step 4-2. tx bank send
- Transfer operation
tx bank send
- Transfer operationTransfer operation involves the transfer of tokens between two addresses.
Send Funds [tx bank send <from_key_or_address> <to_address> <amount> <network_id>
]
tx bank send <from_key_or_address> <to_address> <amount> <network_id>
]Example: Send 10tcro from one address to another.
Step 4-3. tx staking
- Staking operations
tx staking
- Staking operationsTo get the 'validator-addr' with bech32 prefix, you can run this command:
Staking operations involve the interaction between an address and a validator. It allows you to create a validator and lock/unlock funds for staking purposes.
Delegate your funds to a validator [tx staking delegate <validator-addr> <amount>
]
tx staking delegate <validator-addr> <amount>
]To bond funds for staking, you can delegate funds to a validator by the delegate
command
Example: Delegate funds from Default
to a validator under the address tcrocncl16k...edcer
Unbond your delegated funds [tx staking unbond <validator-addr> <amount>
]
tx staking unbond <validator-addr> <amount>
]On the other hand, we can create a Unbond
transaction to unbond the delegated funds
Example: Unbond funds from a validator under the address tcrocncl16k...edcer
Once your funds are unbonded, they will be locked until the unbonding_time
has passed.
Reward related transactions and queries
After you have delegated or created a validator, the reward will be accumulated, you can check/ withdraw it by:
query distribution validator-outstanding-rewards
- Query un-withdrawn rewards for a validator
query distribution validator-outstanding-rewards
- Query un-withdrawn rewards for a validatorWe can check the distribution outstanding (un-withdrawn) rewards for a validator and all of their delegations by operator address.
Example: Check all outstanding rewards under the operator address tcrocncl1...zrf8
tx distribution validator-outstanding-rewards
- Query un-withdrawn rewards for a validator
tx distribution validator-outstanding-rewards
- Query un-withdrawn rewards for a validatorthe We can check distribution outstanding (un-withdrawn) rewards for a validator and all of their delegations by operator address.
Example: Withdraw all outstanding under a delegation address:
Slashing related transaction
tx slashing unjail
- Unjail a validator
tx slashing unjail
- Unjail a validatorValidator could be punished and jailed due to network misbehaviour, we can check the jailing status of a validator, for example:
Where "jailed": true
implies that the validator has been jailed. After the jailing period has passed, one can broadcast a unjail
transaction to unjail the validator and resume its normal operations by
Congratulations! You've successfully set up a Croeseid 5 Testnet node and performed some basic transactions! You may refer to Wallet Management for more advanced operations and transactions.
Croeseid 5 testnet explorer and endpoint
You can lookup data within the
testnet-croeseid-5
network by the explorer;Tendermint:
https://rpc-c5.crypto.org/
;REST:
https://rest-c5.crypto.org
.
Last updated