You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.Ru.md
+11-10Lines changed: 11 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
## Что это
2
2
Данная консольная программа является оберткой над `fift`, `lite-client` и `validator-engine-console`. Она была создана для облегчения управления кошельками, доменами и валидатором на операционной системе `Linux`.
-`toninstaller.sh` - Данный скрипт клонирует исходники `TON` и `mytonctrl` в папки `/usr/src/ton` и `/usr/src/mytonctrl`, компилирует программы из исходников и прописывает их в `/usr/bin/`.
Copy file name to clipboardExpand all lines: README.md
+71-35Lines changed: 71 additions & 35 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,11 +1,34 @@
1
-
[Данный текст доступен на русском языке.](https://github.com/ton-blockchain/mytonctrl/blob/master/README.Ru.md)
1
+

2
2
3
-
## What is it?
4
-
This console is a wrapper over `fift`,`lite-client` and `validator-engine-console`. It was created to facilitate wallet, domain and validator management on Linux OS.
3
+
<!-- omit from toc -->
4
+
# MytTonCtrl
5
+
[Данный текст доступен на русском языке.](README.Ru.md)
- [Local copy of toncenter](#local-copy-of-toncenter)
23
+
-[Useful links](#useful-links)
24
+
25
+
26
+
# What is MytTonCtrl?
27
+
MyTonCtrl is a console application that serves as a convenient wrapper for `fift`, `lite-client`, and `validator-engine-console`. It has been specifically developed to streamline wallet, domain, and validator management tasks on the Linux operating system.
28
+
29
+

30
+
31
+
# Functionality
9
32
-[x] Show TON network status
10
33
-[x] Management of local wallets
11
34
- [x] Create local wallet
@@ -45,49 +68,61 @@ This console is a wrapper over `fift`,`lite-client` and `validator-engine-consol
45
68
- [x] Send validator statistics to https://toncenter.com
46
69
47
70
## List of tested operating systems
48
-
```
49
-
Ubuntu 16.04 LTS (Xenial Xerus) - Error: TON compilation error
50
-
Ubuntu 18.04 LTS (Bionic Beaver) - OK
51
-
Ubuntu 20.04 LTS (Focal Fossa) - OK
52
-
Ubuntu 22.04 LTS (Jammy Jellyfish) - OK
53
-
Debian 8 - Error: Unable to locate package libgsl-dev
-`toninstaller.sh`: clones `TON` and` mytonctrl` sources to `/usr/src/ton` and`/usr/src/mytonctrl` folders, compiles programs from sources and writes them to `/usr/bin/`.
60
84
-`mytoninstaller.py`: configures the validator and `mytonctrl`; generates validator connection keys.
61
85
62
86
## Installation modes
63
-
There are two installation modes: `lite` and`full`. They both **compile** and install `TON` components. However the `lite` version does not configure or run the node/validator.
87
+
There are two installation modes: `lite` and`full`. They both **compile** and install `TON` components. However the `lite` version does not configure or run the node/validator.
64
88
65
89
## Installation for Ubuntu
66
90
1. Download and execute the `install.sh` script in the desired installation mode. During installation the script prompts you for the superuser password several times.
2. Done. You can try to run the `mytonctrl` console now.
73
-
```sh
74
-
mytonctrl
75
-
```
97
+
```sh
98
+
mytonctrl
99
+
```
76
100
77
101
78
102
## Installation for Debian
79
103
1. Download and execute the `install.sh` script in the desired installation mode. During installation the script prompts you for the superuser password several times.
2. Done. You can try to run the `mytonctrl` console now.
86
-
```sh
87
-
mytonctrl
88
-
```
110
+
```sh
111
+
mytonctrl
112
+
```
89
113
90
-
## Telemetry
114
+
# MyTonCtrl Documentation
115
+
116
+
This repository contains the following technical documents for MyTonCtrl, categorized by language. Simply click the links below to navigate to the document you're interested in.
MyTonCtrl is a wrapper that stores its files in two places:
6
+
7
+
1.`~/.local/share/mytonctrl/` - Long-term files such as logs are stored here.
8
+
2.`/tmp/mytonctrl/` - Temporary files are stored here.
9
+
10
+
MyTonCtrl also includes another script, mytoncore, which in turn stores files in the following locations:
11
+
12
+
1.`~/.local/share/mytoncore/` - Permanent files, the main configuration will be stored here.
13
+
2.`/tmp/mytoncore/` - Temporary files, parameters used for elections will be saved here.
14
+
15
+
MyTonCtrl downloads the source code for itself and the validator into the following directories:
16
+
17
+
1.`/usr/src/mytonctrl/`
18
+
2.`/usr/src/ton/`
19
+
20
+
MyTonCtrl compiles the validator components into the following directory:
21
+
22
+
1.`/usr/bin/ton/`
23
+
24
+
MyTonCtrl creates a working directory for the validator here:
25
+
26
+
1.`/var/ton/`
27
+
28
+
---
29
+
30
+
## If MyTonCtrl was installed as root:
31
+
32
+
The configurations will be stored differently:
33
+
34
+
1.`/usr/local/bin/mytonctrl/`
35
+
2.`/usr/local/bin/mytoncore/`
36
+
37
+
---
38
+
39
+
## How to remove MyTonCtrl:
40
+
41
+
Run the script as an administrator and remove the compiled TON components:
42
+
43
+
```bash
44
+
sudo bash /usr/src/mytonctrl/scripts/uninstall.sh
45
+
sudo rm -rf /usr/bin/ton
46
+
```
47
+
48
+
During this process, ensure you have sufficient permissions to delete or modify these files or directories.
49
+
50
+
51
+
# Dealing with Errors and Directory Changes with MyTonCtrl
52
+
53
+
If you encounter issues running MyTonCtrl as a different user or wish to change the working directory of the validator, this guide provides some solutions.
54
+
55
+
## Running MyTonCtrl as Different User
56
+
57
+
Running MyTonCtrl as a different user may trigger the following error:
58
+
59
+
```
60
+
Error: expected str, bytes or os.PathLike object, not NoneType
61
+
```
62
+
63
+
To resolve this, you should run MyTonCtrl as the user who installed it.
64
+
65
+
## Changing Validator Working Directory Pre-installation
66
+
67
+
If you wish to change the working directory of the validator prior to installation, there are two ways to do so:
68
+
69
+
1.**Fork the project** - You can fork the project and make your changes there. Learn how to fork a project with `man git-fork`.
70
+
2.**Create a symbolic link** - You can also create a symbolic link with the following command:
71
+
72
+
```bash
73
+
ln -s /opt/ton/var/ton
74
+
```
75
+
This command will create a link `/var/ton` that points to `/opt/ton`.
76
+
77
+
## Changing Validator Working Directory Post-installation
78
+
79
+
If you want to change the working directory of the validator from `/var/ton/` after installation, perform the following steps:
80
+
81
+
1. **Stop services** - You will need to stop the services with these commands:
82
+
83
+
```bash
84
+
systemctl stop validator
85
+
systemctl stop mytoncore
86
+
```
87
+
88
+
2. **Move validator files** - You then need to move the validator files with this command:
89
+
90
+
```bash
91
+
mv /var/ton/* /opt/ton/
92
+
```
93
+
94
+
3. **Update configuration paths** - Replace the paths in the configuration located at `~/.local/share/mytoncore/mytoncore.db`.
95
+
96
+
4. **Note on experience** - There is no prior experience with such a transfer, so consider this when moving forward.
97
+
98
+
Remember to make sure you have sufficient permissions to make these changes or run these commands.
99
+
100
+
# Understanding Validator Status and Restarting Validator in MyTonCtrl
101
+
102
+
This document will help you understand how to confirm if MyTonCtrl has become a full validator and how to restart your validator.
103
+
104
+
## Checking Validator Status in MyTonCtrl
105
+
106
+
You can confirm if your node has become a full validator by checking the following conditions:
107
+
108
+
1. **Validator Desynchronization** - The desynchronization of the local validator should be less than 20.
109
+
2. **Validator Index** - The validator index should be greater than -1.
110
+
111
+
To view the performance factor of your validator, you can use the `vl`commandin MyTonCtrl:
112
+
113
+
1. Find your validator in the list by its ADNL address (`adnlAddr`).
114
+
2. If the `mr` and `wr` coefficients are close to 1, it means that your validator is working correctly.
115
+
116
+
## Restarting Your Validator
117
+
118
+
If you need to restart your validator, you can do so by running the following command:
119
+
120
+
```bash
121
+
systemctl restart validator
122
+
```
123
+
124
+
Ensure you have sufficient permissions to execute these commands and make necessary adjustments. Always remember to back up important data before performing operations that could potentially affect your validator.
0 commit comments