Expand system tuning docs
This commit is contained in:
committed by
mergify[bot]
parent
11951eb009
commit
5354df8c1c
@ -46,10 +46,14 @@ that CUDA is enabled: `"[<timestamp> solana::validator] CUDA is enabled"`
|
|||||||
|
|
||||||
## System Tuning
|
## System Tuning
|
||||||
|
|
||||||
For Linux validators, the solana repo includes a daemon to adjust system settings to optimize
|
### Linux
|
||||||
performance (namely by increasing the OS UDP buffer limits, and scheduling PoH with realtime policy).
|
#### Automatic
|
||||||
|
The solana repo includes a daemon to adjust system settings to optimize performance
|
||||||
|
(namely by increasing the OS UDP buffer limits, and scheduling PoH with realtime policy).
|
||||||
|
|
||||||
The daemon (`solana-sys-tuner`) is included in the solana binary release.
|
The daemon (`solana-sys-tuner`) is included in the solana binary release. Restart
|
||||||
|
it, *before* restarting your validator, after each software upgrade to ensure that
|
||||||
|
the latest recommended settings are applied.
|
||||||
|
|
||||||
To run it:
|
To run it:
|
||||||
|
|
||||||
@ -57,6 +61,53 @@ To run it:
|
|||||||
sudo solana-sys-tuner --user $(whoami) > sys-tuner.log 2>&1 &
|
sudo solana-sys-tuner --user $(whoami) > sys-tuner.log 2>&1 &
|
||||||
```
|
```
|
||||||
|
|
||||||
|
#### Manual
|
||||||
|
If you would prefer to manage system settings on your own, you may do so with
|
||||||
|
the following commands.
|
||||||
|
|
||||||
|
##### **Increase UDP buffers**
|
||||||
|
```bash
|
||||||
|
sudo bash -c "cat >/etc/sysctl.d/20-solana-udp-buffers.conf <<EOF
|
||||||
|
# Increase UDP buffer size
|
||||||
|
net.core.rmem_default = 134217728
|
||||||
|
net.core.rmem_max = 134217728
|
||||||
|
net.core.wmem_default = 134217728
|
||||||
|
net.core.wmem_max = 134217728
|
||||||
|
EOF"
|
||||||
|
```
|
||||||
|
```bash
|
||||||
|
sudo sysctl -p /etc/sysctl.d/20-solana-udp-buffers.conf
|
||||||
|
```
|
||||||
|
|
||||||
|
##### **Increased memory mapped files limit**
|
||||||
|
```bash
|
||||||
|
sudo bash -c "cat >/etc/sysctl.d/20-solana-mmaps.conf <<EOF
|
||||||
|
# Increase memory mapped files limit
|
||||||
|
vm.max_map_count = 500000
|
||||||
|
EOF"
|
||||||
|
```
|
||||||
|
```bash
|
||||||
|
sudo sysctl -p /etc/sysctl.d/20-solana-mmaps.conf
|
||||||
|
```
|
||||||
|
Add
|
||||||
|
```
|
||||||
|
LimitNOFILE=500000
|
||||||
|
```
|
||||||
|
to the `[Service]` section of your systemd service file, if you use one,
|
||||||
|
otherwise add it to `/etc/systemd/system.conf`.
|
||||||
|
```bash
|
||||||
|
sudo systemctl daemon-reload
|
||||||
|
```
|
||||||
|
```bash
|
||||||
|
sudo bash -c "cat >/etc/security/limits.d/90-solana-nofiles.conf <<EOF
|
||||||
|
# Increase process file descriptor count limit
|
||||||
|
* - nofile 500000
|
||||||
|
EOF"
|
||||||
|
```
|
||||||
|
```bash
|
||||||
|
### Close all open sessions (log out then, in again) ###
|
||||||
|
```
|
||||||
|
|
||||||
## Generate identity
|
## Generate identity
|
||||||
|
|
||||||
Create an identity keypair for your validator by running:
|
Create an identity keypair for your validator by running:
|
||||||
|
Reference in New Issue
Block a user