Skip to content

Commit

Permalink
nodes_documentation_fine_update
Browse files Browse the repository at this point in the history
  • Loading branch information
reveloper committed Sep 17, 2024
1 parent 4b0544b commit 5d719eb
Show file tree
Hide file tree
Showing 5 changed files with 209 additions and 3 deletions.
44 changes: 44 additions & 0 deletions docs/develop/dapps/asset-processing/mass_mint_tools.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
### Mass Minting Tools

:::caution
Page is under development
:::

## Mass Sender

:::info
Recommended approach for token airdrops in September
battle-tested on Notcoin, DOGS
:::

Access: [Masse Sender](https://docs.tonconsole.com/tonconsole/jettons/mass-sending)

Specification:
- Direct distribution of tokens, the project spends money on gas during claims
- Low network load (latest versions are optimized)
- Self-regulation of load (slows down distribution if there's too much activity on the network)

## Mintless Jettons

:::caution
Currently being tested on HAMSTER
Work In Progress
:::

Specification:
- Users claim airdrop tokens without transactions
- Projects don't earn from claims
- Minimal network load


### TokenTable v4

:::info
battle-tested on Avacoin, DOGS
:::

Access: [www.tokentable.xyz](https://www.tokentable.xyz/)

- Higher network load than mass sender, users make transactions when claiming
- Projects can also earn from user claims
- Projects pay TokenTable for setup
56 changes: 55 additions & 1 deletion docs/participate/network-maintenance/staking-incentives.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,8 +90,62 @@ On TON, slashing penalties (fines given to validators) allow any network partici
Upon reaching 66% validator approval (measured by an equal voting weight), a slashing penalty is deducted from the validator and withdrawn from the validator’s total stake. The validation process for penalization and complaint resolution is typically conducted automatically using the MyTonCtrl.


## Decentralized System of Penalties

:::info
The following system of penalising poorly performing validators fully operational September 9, 2024.
:::

### Determination of Poor Work

The TON is supplied with the [lite-client](https://github.com/newton-blockchain/ton/tree/master/lite-client) utility. In lite-client there is a `checkloadall` command.
This command analyses how many blocks the validator should have processed, and how many it actually processed in a given period of time.

If the validator processed less than 90% of the expected number of blocks during a validation round, it is considered to be performing poorly and should be penalised.
Technical description of the process: https://github.com/ton-blockchain/TIPs/issues/13#issuecomment-786627474

### Complains Rules

- Anyone can make complain and get reward on right complain.
- Validation of complain maintain by Validators and fully decentralized.

#### Make Complain

After each validation round (~18 hours), the validator stakes of validators that participated in that round are on the Elector smart contract for another ~9 hours.
During this time, anyone can send a complaint against a validator who performed poorly in said round. This happens on-chain on the Elector smart contract.

There is no requirement for every validator to send or approve this complaint.

#### Validation of Complaint

After each validation round, validators receive a list of complaints from the Elector smart contract and double-check them by calling `checkloadall`.
In case the complaint is validated, they on-chain vote in favour of that complaint.

These actions are built into `mytonctrl` and happen automatically.
If the complaint has 66% of the validators' votes (by their weight), a penalty is taken off from the validator's stake.
There is no way for anyone to single-handedly fine anyone.

[@tonstatus_notifications](https://t.me/tonstatus_notifications) - list of penalised validators each round.


### Fine Value

The amount of the fine is fixed and equals 101 TON(Network Parameter `ConfigParam40:MisbehaviourPunishmentConfig`), which is roughly equal to the validator's income per round.

Value of fine May Due the audience and the number of transactions in TON is growing rapidly and it is vital that the quality of work is at its best.

### Fine Distribution

The fine is distributed among the validators minus network costs and a small reward (~8 TON) to the first complainer who sent the correct complaint to the Elector.

### Validator Guidelines

To prevent your Validator node from fine, it makes sense to set up hardware, monitoring and validator work properly.
Please make sure you're complying with the [validator maintain guidelines](/participate/run-nodes/become-validator#maintain-guidelines).
If you don't want to do this please consider using staking services https://ton.org/stake.

## See Also

* [Running a Full Node (Validator)](/participate/run-nodes/full-node)
* [Running a Validator](/participate/run-nodes/become-validator)
* [Transaction Fees](/develop/smart-contracts/fees)
* [What is blockchain? What is a smart contract? What is gas?](https://blog.ton.org/what-is-blockchain)
5 changes: 5 additions & 0 deletions docs/participate/run-nodes/archive-node.md
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,11 @@ To force node not to store archive blocks use the value 86400. Check [set_node_a
installer set_node_argument --archive-ttl 86400
```


## Support

Contact technical support with [@mytonctrl_help](https://t.me/mytonctrl_help).

## See Also

* [TON Node Types](/participate/nodes/node-types)
Expand Down
103 changes: 101 additions & 2 deletions docs/participate/run-nodes/become-validator.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,43 @@
# Validator Node


## Minimal Hardware Requirements

- 16 cores CPU
- 128 GB RAM
- 1TB NVME SSD _OR_ Provisioned 64+k IOPS storage
- 1 Gbit/s network connectivity
- public IP address (_fixed IP address_)
- 16 TB/month traffic on peak load

> Typically you'll need at least a 1 Gbit/s connection to reliably accommodate peak loads (the average load is expected to be approximately 100 Mbit/s).
> We draw special attention of validators to IOPS disk requirements, it is crucially important for smooth network operation.
## Port Forwarding

All types of nodes require a static external IP address, one UDP port to be forwarded for incoming connections and all outgoing connections to be open - the node uses random ports for new outgoing connections. It's necessarily for the node to be visible to the outside world over the NAT.

It can be done with your network provider or [rent a server](/participate/run-nodes/full-node#recommended-providers) to run a node.

:::info
Read about [Full Node](/participate/run-nodes/full-node) before this article
It's possible to find out which UDP port is opened from the `netstat -tulpn` command.
:::


## Prerequisite

### Learn Slashing Policy

If the validator processed less than 90% of the expected number of blocks during a validation round, this Validator will be fined by 101 TON.
Read more about [slashing policy](/participate/network-maintenance/staking-incentives#decentralized-system-of-penalties).


### Run a Fullnode
Launch [Full Node](/participate/run-nodes/full-node) before follow this article.



Check that validator mode is enabled using `status_modes` command. If it's not, refer [mytonctrl enable_mode command](/participate/run-nodes/mytonctrl#enable_mode).

## View the List of Wallets
Expand Down Expand Up @@ -53,4 +87,69 @@ set stake 50000

`set stake 50000` — this sets the stake size to 50k coins. If the bet is accepted and our node becomes a validator, the bet can only be withdrawn in the second election (according to the rules of the electorate).

![setting stake](/img/docs/nodes-validator/manual-ubuntu_mytonctrl-set_ru.png)
![setting stake](/img/docs/nodes-validator/manual-ubuntu_mytonctrl-set_ru.png)

## Maintain Guidelines

:::caution Slashing of Poor Validators
If the validator processed less than 90% of the expected number of blocks during a validation round, this Validator will be fined by 101 TON.

Read more about [slashing policy](/participate/network-maintenance/staking-incentives#decentralized-system-of-penalties).
:::


As a TON Validators, make sure you are follow these crucial steps to ensure network stability and to avoid slashing penalties in the future.

Essential Actions:

1. Follow the @tonstatus turn on notifications and be ready to apply urgent updates if necessary.
2. Ensure your hardware meets or exceeds [system requirements](/participate/run-nodes/become-validator#minimal-hardware-requirements).
3. We imperatively request you to use [mytonctrl](https://github.com/ton-blockchain/mytonctrl).
In `mytonctrl` keep update due the notification and enable telemetry: `set sendTelemetry true`
4. Set up monitoring dashboards for RAM, Disk, Network, and CPU usage. For technical assistance, contact @mytonctrl_help_bot.
5. Monitor the efficiency of your validator with dashboards.
- Check with `mytonctrl` via `check_ef`.
- [Build dashboard with APIs](/participate/run-nodes/become-validator#validation-and-effectiveness-apis).

:::info
`mytonctrl` allows to check effectiveness of validators via command `check_ef` which outputs your validator efficiency data for the last round and for current round.
This command retrieves data by calling `checkloadall` utility.
Ensure, that your efficiency is greater than 90% (for the full round period).
:::

:::info
In case of low efficiency - take action to fix the problem. Contact technical support [@mytonctrl_help_bot](https://t.me/mytonctrl_help_bot) if necessary.
:::


## Validation and Effectiveness APIs

1. https://elections.toncenter.com/docs - use this API to get information about current and past validation rounds (cycles) - time of rounds, which validators participated in them, their stakes, etc.

Information on current and past elections (for the validation round) is also available.

3. https://toncenter.com/api/qos/index.html#/ - use this API to get information on the efficiency of validators over time.

This API analyses the information from the catchain and builds an estimate of the validator's efficiency. This API does not use the checkloadall utility, but is its alternative.
Unlike `checkloadall` which works only on validation rounds, in this API you can set any time interval to analyse the validator's efficiency.

How to use:

- pass ADNL address of your validator and time interval (from_ts, to_ts) to API. For accurate result it makes sense to take a sufficient interval, for example from 18 hours ago the current moment.

- get the result. If your efficiency percentage field is less than 80%, your validator is not working properly.

- It is important that your validator participates in validation and has the same ADNL address throughout the specified time period.

For example, if a validator participates in validation every second round - then you need to specify only those intervals when he participated in validation. Otherwise, you will get an incorrect underestimate.

- this works not only for masterchain validators (with index < 100) but also for other validators (with index > 100).

Please set up dashboards to monitor your validators using these APIs.


## Support

Contact technical support [@mytonctrl_help_bot](https://t.me/mytonctrl_help_bot).
This bot for validators only. If you have a regular node, then contact the group: [@mytonctrl_help](https://t.me/mytonctrl_help).

4 changes: 4 additions & 0 deletions docs/participate/run-nodes/full-node.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -204,3 +204,7 @@ Check the node logs upon failure:
```bash
tail -f /var/ton-work/log.thread*
```
## Support
Contact technical support with [@mytonctrl_help](https://t.me/mytonctrl_help).

0 comments on commit 5d719eb

Please sign in to comment.