Free TON

Validator Contest: Devops tools [Finished]

Short description

Monitoring, Alerting, Scripts and Tooling

Type

Contest

Dates

18.05.2020 - 1.06.2020

Motivation

Validators need tools and automation to insure efficient scalable and secure operations to support Free TON blockchain

General requirements:

Documentation should be provided for each tool

Provided tools should operate exactly according to its documentation

Motivation and goal for each tool should be described

All software must be released with licences supported by Free Software Foundation

DevOps Skills required:

  • Linux
  • Unix Shell scripting
  • Infrastructure as a code
  • docker/docker-compose/kubernetes
  • Desirable: Ansible, Terraform, AWS, logstash

Tasks:

  1. Enhanced node deployment infrastructure
    • Need to develop enhanced deployment infrastructure for C++/Rust nodes based on modern tools and techniques (docker/docker-compose, Ansible, Terraform, etc.).
    • Based on infrastructure as a code. Take into account deployment from scratch, upgrade, cleanup scenarios on various set of Linux distros as well as other OS (e.g. MacOS).
  2. Intellectual log dashboard with analytics:
    • Need to collect log files into centralised database (e.g. logstash).
    • Make base analytics with some predefined patterns which can simplify failure analysis and monitoring.
  3. Extended metrics for node monitoring
    • Analyse available node/validator/elector metrics (from lites-client/validator-engine-console/GraphQL/etc.) and define a subset useful for further analytics and monitoring tasks.
    • Develop visualisation concept to simplify the analysis.
    • Develop alert rules for daily monitoring
  4. Automate participation in elections
    • Write validator script for elections using tonos-cli
    • Use tonos-cli to run elector get-methods.
    • Use tonos-cli to query global configuration parameters.
    • Use tonos-cli to send validator query to elector smart contract.
    • Automate confirmation of multisig transactions.
    • Improve custodian notification mechanism for multisig transactions: notify about submitted transactions via user-friendly mechanism (e-mail, sms, etc.).
  5. Write validator script for elections using lite-client for C++ node.
    • Use lite-client to query global configuration parameters.
    • Use lite-client to run elector get-methods.
    • Use lite-client to send validator query to elector smart contract.

Bonus

  • Integrate TON address converter (different addresses used in config.json) with your solutions

Evaluation criteria and Winning conditions:

Number of completed tasks

Correctness of operations of the provided tool

Quality of code and description

Work as advertised, perform its stated functions

The Jury

Each of the Initial Validators will have a right to nominate 1 person to the jury

Initial Validators whose teams are willing to participate in the Contest will loose their right to nominate a jury

The Jury membership will be public

The Jury will provide feedback for all proposals

The Jury will vote for each proposal “yes” or “no”

Winners:

The winners of all 5 tasks will recieve the following:

1st prize — 30,000 Tons

2nd prize — 20,000 Tons

3rd prize — 10,000 Tons

Next 10 runners up — 1,000 Tons each

Jury members who vote — 500 Tons each for doing their civic duty

15 Likes

Challenge accepted :+1:t3:

5 Likes

Do we need the packaged release of node code (and other parts of the project) for various Linux distros? That would ease the installation of new nodes/wallets/etc a lot. If so - I think there is a need to add “packaging scripts (SPECs for RPM-based, control-files for DEB-based, etc)” to the contest, so to increase the coverage for package maintainers, maybe even actually upload those scripts to various community-based packages distribution channels (e.g. PPA for Debian/Ubuntu).

1 Like

Its up to you, really. The contest describes the necessary part. I am sure whatever you provide as extra will definitely be counted by jury. Good luck and thank you for supporting the project.

2 Likes

How to prepare documentation for Jury? Is placing all in github private repository okay?

1 Like

For Docker check out this:

8 Likes

Multisig autoconfirmation tool, written on Python. Chosen Python becuse it’s can be easily read by many people (and our devops). The purpose of script — to be the base for further development of tools pack for monitoring validator accounts, plan staking amounts, etc. Repo: https://github.com/mixbytes/mb-ton-validation

2 Likes

UPD: Contest extended for one more week(Until 1st of June)

1 Like

/me/thanks/you/for-invite/lets start

1 Like

What about persistent storage for ton db?

1 Like

How to prepare the documentation for jury ?

1 Like

Dear Community,

Let me share an automation pipeline for elections participation I call FreeTON Toolbox with you!

In short: it partially covers the 1st and the 4th task requirements.

Any comments, suggestions and bug reports would be much appreciated.

6 Likes

I observed performance degradation caused by usage of Docker volumes (even with optimizations such as ‘delegated’ volume configuration).

2 Likes

TON comes with a converter tool in ./build/utils/convert_address for base64/hex conversion. There’s a third encoding format (decoded as big-endian integer), which is sometimes visible in smart contract outputs: https://github.com/certusone/ton_cpp_exporter/blob/834ae90f57102e9fe28a383a0c5e9fee531a0010/ton_metrics_push.py#L203

2 Likes

Чесно непонятно, нет сплаченой стратегии, все розкидано не возможно понять что и до чого , где и когда(
А русский где(((

1 Like

Try harder! People here are glad to share the knowledge and help each other. Ask and you’ll be answered!

2 Likes

Got an update on this!

Besides minor improvements, FreeTON Toolbox now provides you with a Dashboard to monitor a few runtime metrics:

  • Memory/Swap/Network usage
  • DB size dynamics
  • Validator container uptime
  • TIME_DIFF

I’d be glad to hear any suggestions from you on what to add to the dashboard configuration!

4 Likes

Here are some more validation automation scripts - https://github.com/rainblowing/ton-auto-validationhttps://github.com/rainblowing/ton-auto-validation

And some ideas regarding multisig wallet decentralization - https://github.com/rainblowing/ton-auto-validation/wiki/Validation-Decentralization-Ideas