Solana Mainnet RPC - Schnellstart
Einleitung
Zur Bereitstellung eines Solana-Mainnet-RPC verwenden Sie das SLV-Befehlszeilentool.
Dieser Schnellstart-Leitfaden erklärt, wie Sie mit dem SLV-Befehlszeilentool einen Solana-Mainnet-RPC mit dem Geyser-Yellowstone-Plugin bereitstellen.
Auf Ihrem Server muss Ubuntu 24.04 LTS frisch installiert sein.
Vorbereitung eines Bare-Metal-Servers
Ein Solana-Client lässt sich zwar auf einem VPS oder einer virtuellen Maschine (VM) betreiben, doch optimale Leistung und einen stabilen Betrieb zu erreichen, ist schwierig. Insbesondere RPC-Knoten und Validatoren arbeiten unter hoher Last, weshalb es entscheidend ist, eine geeignete Serverumgebung einzurichten.
Solana empfiehlt offiziell den Einsatz von Bare-Metal-Servern.
RPC-Knoten variieren je nach Workload stark.
Standard-RPC (SendTx / Geyser gRPC) und Index RPC (vollständige Indexierung) unterscheiden sich deutlich, insbesondere beim Bedarf an Arbeitsspeicher und Speicherplatz.
Standard-RPC (SendTx / Geyser gRPC) und Index RPC (vollständige Indexierung) unterscheiden sich deutlich, insbesondere beim Bedarf an Arbeitsspeicher und Speicherplatz.
RPC-Hardware-Anforderungen (Richtwerte)
| Komponente | RPC-Knoten | Index RPC (Referenz) |
|---|---|---|
| CPU | 24 Kerne+ @ 2,8 GHz+ / AMD Gen3+ / Intel Ice Lake+ / SHA-Erweiterungen / AVX2 | 32 Kerne+ (hoher Takt empfohlen) |
| RAM | 512 GB+ | 1152 GB+ |
| Datenträger | NVMe Gen3 x4 oder besser / Trennung von Accounts, Ledger und Snapshots empfohlen | Größere Kapazität + hohe TBW / Trennung empfohlen |
| Netzwerk | 1 Gbps oder höher | 1 Gbps oder höher (mehr Bandbreite ist vorzuziehen) |
| GPU | Nicht erforderlich | Nicht erforderlich |
Hinweis:
Taktfrequenz und effektiver Durchsatz gelten als wichtiger als die Anzahl der Kerne.
Bei Index RPC können Arbeitsspeicher und Datenträger zum Engpass werden. Sorgen Sie daher für ausreichende Kapazität und hohe IOPS.
Wenn eine Indexierung erforderlich ist, empfehlen wir 768 GB oder mehr und für einen stabilen Betrieb 1152 GB oder mehr.
SLV Metal bietet Bare-Metal-Server, die darauf ausgelegt sind, im Rahmen Ihres Budgets die höchste Leistung zu liefern.
Wenn Sie den Befehl
slv metal list ausführen, finden Sie die Option RPC, die speziell auf Solana-RPC-Knoten zugeschnitten ist.bash
slv metal list
? 🛡️ Select SLV BareMetal Type (APP)
📦 APP - For Trade Bot,Testnet Validator, DApp and More!
🚀 MV - For Solana Mainnet Validator
❯ 🛡️⚡️ RPC - For Solana RPC Nodeslv metal list
? 🛡️ Select SLV BareMetal Type (APP)
📦 APP - For Trade Bot,Testnet Validator, DApp and More!
🚀 MV - For Solana Mainnet Validator
❯ 🛡️⚡️ RPC - For Solana RPC NodeWenn Sie Ihren Bare-Metal-Server noch nicht eingerichtet haben, folgen Sie bitte dem Leitfaden zur Einrichtung des Bare-Metal-Servers.
Ziehen Sie außerdem die folgenden Ressourcen heran:
Solana-RPC-Knoten bereitstellen
Initialisieren Sie zunächst die Solana-RPC-Konfiguration.
Wählen Sie als Netzwerk das gewünschte Solana-Netzwerk aus.
bash
slv rpc init
? Select Solana Network (mainnet)
testnet
devnet
❯ mainnetslv rpc init
? Select Solana Network (mainnet)
testnet
devnet
❯ mainnetBestätigen Sie als Nächstes, ob Sie einen mit Solana-Knoten kompatiblen Server haben.
bash
? 🛡️ Do you have a Solana Node Compatible Server? (yes)
❯ yes
no? 🛡️ Do you have a Solana Node Compatible Server? (yes)
❯ yes
noIn diesem Tutorial wird davon ausgegangen, dass Sie
yes auswählen.Server-Benutzer und IP-Adresse festlegen
Legen Sie den Server-Benutzer, die IP-Adresse und den Pfad zum RSA-Schlüssel fest.
bash
? What's the user for the server? (root) › root
? Enter the server IP address › x.x.x.x
? What's the path to your RSA key? (~/.ssh/id_rsa)? What's the user for the server? (root) › root
? Enter the server IP address › x.x.x.x
? What's the path to your RSA key? (~/.ssh/id_rsa)Automatische Regionserkennung
Als Nächstes pingt das System von Ihrem konfigurierten Knoten aus jede Block Engine an, um automatisch die nächstgelegene Region zu ermitteln. Anhand der tatsächlich gemessenen Ping-Werte können Sie die optimale Region auswählen.
bash
🔍 Checking SSH connection...
✔︎ SSH connection succeeded
📍 Measuring latencies from x.x.x.x to mainnet regions...
Pinging Amsterdam (amsterdam.mainnet.block-engine.jito.wtf)...
Pinging Dublin (dublin.mainnet.block-engine.jito.wtf)...
Pinging Frankfurt (frankfurt.mainnet.block-engine.jito.wtf)...
Pinging London (london.mainnet.block-engine.jito.wtf)...
Pinging New York (ny.mainnet.block-engine.jito.wtf)...
Pinging Salt Lake City (slc.mainnet.block-engine.jito.wtf)...
Pinging Singapore (singapore.mainnet.block-engine.jito.wtf)...
Pinging Tokyo (tokyo.mainnet.block-engine.jito.wtf)...
✅ Singapore: 0.291 ms
✅ London: 154.071 ms
✅ Dublin: 167.267 ms
✅ Frankfurt: 149.081 ms
✅ Amsterdam: 154.501 ms
✅ New York: 228.624 ms
✅ Salt Lake City: 278.016 ms
✅ Tokyo: 376.816 ms
🎯 Nearest region: 🇸🇬 Singapore
Latency: 0.291 ms
Block Engine: https://singapore.mainnet.block-engine.jito.wtf
Shred Receiver: 202.8.11.224:1002
Relayer: http://singapore.mainnet.relayer.jito.wtf:8100
NTP Server: ntp.singapore.jito.wtf🔍 Checking SSH connection...
✔︎ SSH connection succeeded
📍 Measuring latencies from x.x.x.x to mainnet regions...
Pinging Amsterdam (amsterdam.mainnet.block-engine.jito.wtf)...
Pinging Dublin (dublin.mainnet.block-engine.jito.wtf)...
Pinging Frankfurt (frankfurt.mainnet.block-engine.jito.wtf)...
Pinging London (london.mainnet.block-engine.jito.wtf)...
Pinging New York (ny.mainnet.block-engine.jito.wtf)...
Pinging Salt Lake City (slc.mainnet.block-engine.jito.wtf)...
Pinging Singapore (singapore.mainnet.block-engine.jito.wtf)...
Pinging Tokyo (tokyo.mainnet.block-engine.jito.wtf)...
✅ Singapore: 0.291 ms
✅ London: 154.071 ms
✅ Dublin: 167.267 ms
✅ Frankfurt: 149.081 ms
✅ Amsterdam: 154.501 ms
✅ New York: 228.624 ms
✅ Salt Lake City: 278.016 ms
✅ Tokyo: 376.816 ms
🎯 Nearest region: 🇸🇬 Singapore
Latency: 0.291 ms
Block Engine: https://singapore.mainnet.block-engine.jito.wtf
Shred Receiver: 202.8.11.224:1002
Relayer: http://singapore.mainnet.relayer.jito.wtf:8100
NTP Server: ntp.singapore.jito.wtfIdentity-Schlüsselpaar generieren
Wenn Sie kein Identity-Schlüsselpaar haben, können Sie ein neues generieren.
bash
? Do you want to create a new identity key now? (Y/n) › Yes
🔑 Generating new identity key...
✨ Generated Key: p3tnYqjciWz8DnjApUVDPWTEhdzdX6qvqTaRCrckSLV
✨ Moved Key to: ~/.slv/keys/p3tnYqjciWz8DnjApUVDPWTEhdzdX6qvqTaRCrckSLV.json? Do you want to create a new identity key now? (Y/n) › Yes
🔑 Generating new identity key...
✨ Generated Key: p3tnYqjciWz8DnjApUVDPWTEhdzdX6qvqTaRCrckSLV
✨ Moved Key to: ~/.slv/keys/p3tnYqjciWz8DnjApUVDPWTEhdzdX6qvqTaRCrckSLV.jsonSolana CLI auswählen
Wählen Sie die Version der Solana CLI aus.
bash
? Select Solana CLI (jito)
agave
❯ jito
firedancer-agave
firedancer-jito? Select Solana CLI (jito)
agave
❯ jito
firedancer-agave
firedancer-jitoRPC-Typ auswählen
Wählen Sie den RPC-Typ aus.
bash
? Select an RPC type
❯ Geyser gRPC
Index RPC
SendTx RPC
Index RPC + gRPC? Select an RPC type
❯ Geyser gRPC
Index RPC
SendTx RPC
Index RPC + gRPCIn diesem Tutorial wählen wir
Geyser gRPC.Konfiguration bestätigen
Bestätigen Sie abschließend die Konfiguration.
bash
✔︎ Success
✔ Inventory updated to ~/.slv/inventory.mainnet.rpcs.yml
✔ Successfully created solv user on p3tnYqjciWz8DnjApUVDPWTEhdzdX6qvqTaRCrckSLV
✔︎ mainnet_rpcs inventory file has been saved to ~/.slv/inventory.mainnet.rpcs.yml
Now you can deploy with:
$ slv rpc deploy -n mainnet -p p3tnYqjciWz8DnjApUVDPWTEhdzdX6qvqTaRCrckSLV✔︎ Success
✔ Inventory updated to ~/.slv/inventory.mainnet.rpcs.yml
✔ Successfully created solv user on p3tnYqjciWz8DnjApUVDPWTEhdzdX6qvqTaRCrckSLV
✔︎ mainnet_rpcs inventory file has been saved to ~/.slv/inventory.mainnet.rpcs.yml
Now you can deploy with:
$ slv rpc deploy -n mainnet -p p3tnYqjciWz8DnjApUVDPWTEhdzdX6qvqTaRCrckSLVDanach wird der Benutzer
solv auf dem Bare-Metal-Server erstellt, und
die Solana-RPC-Konfiguration wird in ~/.slv/inventory.mainnet.rpcs.yml gespeichert.Solana-RPC-Knoten bereitstellen
Sobald Sie die Konfiguration bestätigen, beginnt die Bereitstellung.
bash
slv rpc deploy -n mainnet -p p3tnYqjciWz8DnjApUVDPWTEhdzdX6qvqTaRCrckSLVslv rpc deploy -n mainnet -p p3tnYqjciWz8DnjApUVDPWTEhdzdX6qvqTaRCrckSLVbash
Your mainnet RPC Nodes Settings:
┌──────────────┬─────────────────────────────────────────────┐
│ Identity Key │ p3tnYqjciWz8DnjApUVDPWTEhdzdX6qvqTaRCrckSLV │
├──────────────┼─────────────────────────────────────────────┤
│ Name │ p3tnYqjciWz8DnjApUVDPWTEhdzdX6qvqTaRCrckSLV │
├──────────────┼─────────────────────────────────────────────┤
│ IP │ x.x.x.x. │
├──────────────┼─────────────────────────────────────────────┤
│ Region │ singapore │
├──────────────┼─────────────────────────────────────────────┤
│ RPC Type │ Geyser gRPC │
├──────────────┼─────────────────────────────────────────────┤
│ Version │ 3.0.7-jito │
└──────────────┴─────────────────────────────────────────────┘
.
.
.
Successfully Deployed RPC on mainnet
You can monitor your Node with the following steps:
Log in to your server with SSH:
ssh [email protected]
Then, run the following command to monitor your node:
$ solv mYour mainnet RPC Nodes Settings:
┌──────────────┬─────────────────────────────────────────────┐
│ Identity Key │ p3tnYqjciWz8DnjApUVDPWTEhdzdX6qvqTaRCrckSLV │
├──────────────┼─────────────────────────────────────────────┤
│ Name │ p3tnYqjciWz8DnjApUVDPWTEhdzdX6qvqTaRCrckSLV │
├──────────────┼─────────────────────────────────────────────┤
│ IP │ x.x.x.x. │
├──────────────┼─────────────────────────────────────────────┤
│ Region │ singapore │
├──────────────┼─────────────────────────────────────────────┤
│ RPC Type │ Geyser gRPC │
├──────────────┼─────────────────────────────────────────────┤
│ Version │ 3.0.7-jito │
└──────────────┴─────────────────────────────────────────────┘
.
.
.
Successfully Deployed RPC on mainnet
You can monitor your Node with the following steps:
Log in to your server with SSH:
ssh [email protected]
Then, run the following command to monitor your node:
$ solv mFertig! Ihr Solana-RPC-Knoten ist jetzt bereitgestellt.
Es dauert eine Weile, bis er mit dem Solana-Netzwerk synchronisiert ist.
Debugging & Monitoring
Nach der Bereitstellung können Sie den Status des Solana-RPC-Knotens mit dem folgenden Befehl prüfen:
bash
ssh solv@<your-server-ip>
solv mssh solv@<your-server-ip>
solv msolv ist ein Alias für agave-validator -l /mnt/ledger.
Diese Einstellung wird bei der Bereitstellung des RPC-Knotens zu ~/.profile hinzugefügt.SLV-RPC-Befehle
bash
Usage: slv rpc
Version: 0.9.700
Description:
🛠️ Manage Solana RPC Nodes 🛠️
Options:
-h, --help - Show this help.
Commands:
init - 🚀 Initialize a new RPC node configuration
deploy - 📦 Deploy RPC Nodes
list - 📋 List RPC Nodes
setup:firedancer - 🔥 Setup/Update Firedancer Validator
update:firedancer - 🔄 Update Firedancer Version
build:solana-cli - 🛠️ Build Solana CLI from Source
install:solana - ➡️ Install Solana CLI Binary
update:script - ⚙️ Update RPC Startup Config
update:geyser - ⚡️ Update Geyser Version
start - 🟢 Start RPC
stop - 🔴 Stop RPC
restart - ♻️ Restart RPC
cleanup - 🧹 Cleanup RPC - Remove Ledger/Snapshot Unnecessary Files
get:snapshot - 💾 Download Snapshot with aria2c
update:allowed-ips - 🛡️ Update allowed IPs for mainnet RPC nodesUsage: slv rpc
Version: 0.9.700
Description:
🛠️ Manage Solana RPC Nodes 🛠️
Options:
-h, --help - Show this help.
Commands:
init - 🚀 Initialize a new RPC node configuration
deploy - 📦 Deploy RPC Nodes
list - 📋 List RPC Nodes
setup:firedancer - 🔥 Setup/Update Firedancer Validator
update:firedancer - 🔄 Update Firedancer Version
build:solana-cli - 🛠️ Build Solana CLI from Source
install:solana - ➡️ Install Solana CLI Binary
update:script - ⚙️ Update RPC Startup Config
update:geyser - ⚡️ Update Geyser Version
start - 🟢 Start RPC
stop - 🔴 Stop RPC
restart - ♻️ Restart RPC
cleanup - 🧹 Cleanup RPC - Remove Ledger/Snapshot Unnecessary Files
get:snapshot - 💾 Download Snapshot with aria2c
update:allowed-ips - 🛡️ Update allowed IPs for mainnet RPC nodes