The staking-create-pool
command in Mintlayer is used to create a staking pool. A staking pool is capable of creating blocks, gaining rewards, and receiving delegations from other users for staking purposes. This command involves setting various parameters that dictate how rewards are distributed and how the pool can be decommissioned.
Security Warning for Running a Staking Pool
Running a staking pool involves significant security responsibilities. It is crucial to ensure that all security measures are meticulously implemented and maintained. Inadequate security can lead to severe risks, including the potential total loss of all coins in the pool.
Consider the following key points:
- Secure Your Decommission Key: The decommission key should be stored in cold storage and protected from unauthorized access.
- Regular Security Audits: Conduct regular security audits of your systems to identify and address vulnerabilities.
- Monitor Pool Activity: Stay vigilant and monitor your pool for any unusual activities or potential security breaches.
- Educate Yourself and Your Team: Ensure that you and anyone involved in managing the pool are well-informed about best security practices.
- Keep Your Software Updated: Regularly update all software related to running your pool, including the Mintlayer node software and any security tools, to protect against newly discovered vulnerabilities.
Failure to properly secure your staking pool can result in the compromise of your assets. The responsibility of running a staking pool should not be taken lightly, as it requires a high level of security awareness and constant vigilance.
staking-create-pool <AMOUNT> <COST_PER_BLOCK> <MARGIN_RATIO_PER_THOUSAND> <DECOMMISSION_ADDRESS>
<AMOUNT>
: The amount of coins pledged to the pool. There's a minimum amount required for acceptance. This pledged amount, along with any rewards gained by the pool, cannot be withdrawn without decommissioning the pool. The likelihood of winning block rewards is proportional to the pool's ownership, up to a maximum limit to prevent centralization.<COST_PER_BLOCK>
: A fixed amount in coins subtracted from the total rewards in a block, given to the staker as the cost of running the pool.<MARGIN_RATIO_PER_THOUSAND>
: After subtracting the cost per block from the rewards, this ratio (expressed as a percentage with per-mill accuracy) of the remaining rewards is given to the staker. The rest is distributed among delegators based on their delegation amounts. For example, 0.1% is valid and equivalent to 0.001, and 5% is equivalent to 0.05.<DECOMMISSION_ADDRESS>
: The address (key) that can decommission the pool. It is advisable to store the decommission key in cold storage for security.-h, --help
: Displays help information about the staking-create-pool
command.Creating a Staking Pool:
To create a staking pool with a specific amount pledged, cost per block, margin ratio, and a decommission address, the command might look like this:
staking-create-pool 100000 10 50% tmt1qxc9tqvw9hcnlnpfj8fct0y2tmfr2dcjts30mux2
This command creates a staking pool with 100,000 coins pledged, a cost per block of 10 coins, a margin ratio of 50%, and a decommission address tmt1qxc9tqvw9hcnlnpfj8fct0y2tmfr2dcjts30mux2
.