mirror of
https://github.com/XRPLF/xrpl-dev-portal.git
synced 2025-11-27 23:25:51 +00:00
Migrate content syntax via script
The changes in this commit were auto-generated by running tool/migrate.sh Following this commit, the Dactyl build no longer works but the Redocly build (mostly) should.
This commit is contained in:
@@ -7,7 +7,7 @@ labels:
|
||||
---
|
||||
# Cluster rippled Servers
|
||||
|
||||
If you run multiple [`rippled` servers](xrpl-servers.html) in the same data center, you can configure them in a [cluster](clustering.html) to maximize efficiency. To configure clustering:
|
||||
If you run multiple [`rippled` servers](../../../concepts/networks-and-servers/index.md) in the same data center, you can configure them in a [cluster](../../../concepts/networks-and-servers/clustering.md) to maximize efficiency. To configure clustering:
|
||||
|
||||
1. For each of your servers, note the IP address of the server.
|
||||
|
||||
@@ -15,18 +15,20 @@ If you run multiple [`rippled` servers](xrpl-servers.html) in the same data cent
|
||||
|
||||
For example, using the commandline interface:
|
||||
|
||||
$ rippled validation_create
|
||||
```
|
||||
$ rippled validation_create
|
||||
|
||||
Loading: "/etc/rippled.cfg"
|
||||
Connecting to 127.0.0.1:5005
|
||||
{
|
||||
"result" : {
|
||||
"status" : "success",
|
||||
"validation_key" : "FAWN JAVA JADE HEAL VARY HER REEL SHAW GAIL ARCH BEN IRMA",
|
||||
"validation_public_key" : "n9Mxf6qD4J55XeLSCEpqaePW4GjoCR5U1ZeGZGJUCNe3bQa4yQbG",
|
||||
"validation_seed" : "ssZkdwURFMBXenJPbrpE14b6noJSu"
|
||||
}
|
||||
}
|
||||
Loading: "/etc/rippled.cfg"
|
||||
Connecting to 127.0.0.1:5005
|
||||
{
|
||||
"result" : {
|
||||
"status" : "success",
|
||||
"validation_key" : "FAWN JAVA JADE HEAL VARY HER REEL SHAW GAIL ARCH BEN IRMA",
|
||||
"validation_public_key" : "n9Mxf6qD4J55XeLSCEpqaePW4GjoCR5U1ZeGZGJUCNe3bQa4yQbG",
|
||||
"validation_seed" : "ssZkdwURFMBXenJPbrpE14b6noJSu"
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
Save the `validation_seed` and `validation_public_key` parameters from each response somewhere secure.
|
||||
|
||||
@@ -34,9 +36,11 @@ If you run multiple [`rippled` servers](xrpl-servers.html) in the same data cent
|
||||
|
||||
1. In the `[ips_fixed]` section, list the IP address and port of each _other_ member of the cluster. For each of those servers, the port number should match the `protocol = peer` port (usually 51235) from that server's `rippled.cfg`. For example:
|
||||
|
||||
[ips_fixed]
|
||||
192.168.0.1 51235
|
||||
192.168.0.2 51235
|
||||
```
|
||||
[ips_fixed]
|
||||
192.168.0.1 51235
|
||||
192.168.0.2 51235
|
||||
```
|
||||
|
||||
This defines specific peer servers to which this server should always attempt to maintain a direct peer-to-peer connection.
|
||||
|
||||
@@ -44,61 +48,66 @@ If you run multiple [`rippled` servers](xrpl-servers.html) in the same data cent
|
||||
|
||||
2. In the `[node_seed]` section, set the server's node seed to one of the `validation_seed` values you generated using the [validation_create method][] in step 2. Each server must use a unique node seed. For example:
|
||||
|
||||
[node_seed]
|
||||
ssZkdwURFMBXenJPbrpE14b6noJSu
|
||||
```
|
||||
[node_seed]
|
||||
ssZkdwURFMBXenJPbrpE14b6noJSu
|
||||
```
|
||||
|
||||
This defines the key pair the server uses to sign peer-to-peer communications, excluding validation messages.
|
||||
|
||||
3. In the `[cluster_nodes]` section, set the members of the server's cluster, identified by their `validation_public_key` values. Each server should list the public keys of all _other_ members of the cluster here. Optionally, add a custom name for each server. For example:
|
||||
|
||||
[cluster_nodes]
|
||||
n9McNsnzzXQPbg96PEUrrQ6z3wrvgtU4M7c97tncMpSoDzaQvPar keynes
|
||||
n94UE1ukbq6pfZY9j54sv2A1UrEeHZXLbns3xK5CzU9NbNREytaa friedman
|
||||
```
|
||||
[cluster_nodes]
|
||||
n9McNsnzzXQPbg96PEUrrQ6z3wrvgtU4M7c97tncMpSoDzaQvPar keynes
|
||||
n94UE1ukbq6pfZY9j54sv2A1UrEeHZXLbns3xK5CzU9NbNREytaa friedman
|
||||
```
|
||||
|
||||
This defines the key pairs the server uses to recognize members of its cluster.
|
||||
|
||||
4. After saving the config file, restart `rippled` on each server.
|
||||
|
||||
# systemctl restart rippled
|
||||
```
|
||||
# systemctl restart rippled
|
||||
```
|
||||
|
||||
5. To confirm that each server is now a member of the cluster, use the [peers method][]. The `cluster` field should list the public keys and (if configured) the custom names for each server.
|
||||
|
||||
For example, using the commandline interface:
|
||||
|
||||
$ rippled peers
|
||||
```
|
||||
$ rippled peers
|
||||
|
||||
Loading: "/etc/rippled.cfg"
|
||||
Connecting to 127.0.0.1:5005
|
||||
{
|
||||
"result" : {
|
||||
"cluster" : {
|
||||
"n9McNsnzzXQPbg96PEUrrQ6z3wrvgtU4M7c97tncMpSoDzaQvPar": {
|
||||
"tag": "keynes",
|
||||
"age": 1
|
||||
},
|
||||
"n94UE1ukbq6pfZY9j54sv2A1UrEeHZXLbns3xK5CzU9NbNREytaa": {
|
||||
"tag": "friedman",
|
||||
"age": 1
|
||||
}
|
||||
Loading: "/etc/rippled.cfg"
|
||||
Connecting to 127.0.0.1:5005
|
||||
{
|
||||
"result" : {
|
||||
"cluster" : {
|
||||
"n9McNsnzzXQPbg96PEUrrQ6z3wrvgtU4M7c97tncMpSoDzaQvPar": {
|
||||
"tag": "keynes",
|
||||
"age": 1
|
||||
},
|
||||
"peers" : [
|
||||
... (omitted) ...
|
||||
],
|
||||
"status" : "success"
|
||||
}
|
||||
}
|
||||
"n94UE1ukbq6pfZY9j54sv2A1UrEeHZXLbns3xK5CzU9NbNREytaa": {
|
||||
"tag": "friedman",
|
||||
"age": 1
|
||||
}
|
||||
},
|
||||
"peers" : [
|
||||
... (omitted) ...
|
||||
],
|
||||
"status" : "success"
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
## See Also
|
||||
|
||||
- **Concepts:**
|
||||
- [Peer Protocol](peer-protocol.html)
|
||||
- [Peer Protocol](../../../concepts/networks-and-servers/peer-protocol.md)
|
||||
- **Tutorials:**
|
||||
- [Install rippled](install-rippled.html)
|
||||
- [Install rippled](../../installation/index.md)
|
||||
- **References:**
|
||||
- [validation_create method][]
|
||||
- [peers method][]
|
||||
|
||||
<!--{# common link defs #}-->
|
||||
{% include '_snippets/rippled-api-links.md' %}
|
||||
{% include '_snippets/tx-type-links.md' %}
|
||||
{% include '_snippets/rippled_versions.md' %}
|
||||
{% raw-partial file="/_snippets/common-links.md" /%}
|
||||
|
||||
@@ -8,14 +8,14 @@ labels:
|
||||
---
|
||||
# Configure a Private Server
|
||||
|
||||
A [private server](peer-protocol.html#private-peers) is a `rippled` server that connects to the network only through specific, trusted peers instead of connecting directly to discovered peers in the open peer-to-peer network. This kind of configuration is an optional precaution most commonly recommended for [validators](run-rippled-as-a-validator.html), but it can be useful for other specific purposes.
|
||||
A [private server](../../../concepts/networks-and-servers/peer-protocol.md#private-peers) is a `rippled` server that connects to the network only through specific, trusted peers instead of connecting directly to discovered peers in the open peer-to-peer network. This kind of configuration is an optional precaution most commonly recommended for [validators](../server-modes/run-rippled-as-a-validator.md), but it can be useful for other specific purposes.
|
||||
|
||||
## Prerequisites
|
||||
|
||||
To use a private server, you must meet the following requirements:
|
||||
|
||||
- You must have [`rippled` installed](install-rippled.html) and updated to the latest version, but not running yet.
|
||||
- You must decide whether to connect through **proxies** you run yourself, or through **public hubs**. For a comparison of these options, see [Pros and Cons of Peering Configurations](peer-protocol.html#pros-and-cons-of-peering-configurations).
|
||||
- You must have [`rippled` installed](../../installation/index.md) and updated to the latest version, but not running yet.
|
||||
- You must decide whether to connect through **proxies** you run yourself, or through **public hubs**. For a comparison of these options, see [Pros and Cons of Peering Configurations](../../../concepts/networks-and-servers/peer-protocol.md#pros-and-cons-of-peering-configurations).
|
||||
- If you are using proxies, you must have additional machines with `rippled` installed and running to use as the proxies. These servers must be able to connect to the outside network and to your private server.
|
||||
- For either configuration, you must know the IP addresses and ports of the peers you intend to connect to.
|
||||
|
||||
@@ -25,16 +25,20 @@ To set up a specific server as a private peer, complete the following steps:
|
||||
|
||||
1. Edit your `rippled`'s config file.
|
||||
|
||||
vim /etc/opt/ripple/rippled.cfg
|
||||
```
|
||||
vim /etc/opt/ripple/rippled.cfg
|
||||
```
|
||||
|
||||
{% include '_snippets/conf-file-location.md' %}<!--_ -->
|
||||
{% partial file="/_snippets/conf-file-location.md" /%}
|
||||
|
||||
2. Enable private peering.
|
||||
|
||||
Add or uncomment the following stanza in your config file:
|
||||
|
||||
[peer_private]
|
||||
1
|
||||
```
|
||||
[peer_private]
|
||||
1
|
||||
```
|
||||
|
||||
3. Add fixed peers.
|
||||
|
||||
@@ -42,15 +46,19 @@ To set up a specific server as a private peer, complete the following steps:
|
||||
|
||||
For example, to connect using **public hubs**, you could use the following stanza:
|
||||
|
||||
[ips_fixed]
|
||||
r.ripple.com 51235
|
||||
zaphod.alloy.ee 51235
|
||||
```
|
||||
[ips_fixed]
|
||||
r.ripple.com 51235
|
||||
zaphod.alloy.ee 51235
|
||||
```
|
||||
|
||||
If your server connects using **proxies**, the IP addresses and ports should match the configurations of the `rippled` servers you are using as proxies. For each of those servers, the port number should match the `protocol = peer` port in that server's config file (usually 51235). For example, your configuration might look like this:
|
||||
|
||||
[ips_fixed]
|
||||
192.168.0.1 51235
|
||||
192.168.0.2 51235
|
||||
```
|
||||
[ips_fixed]
|
||||
192.168.0.1 51235
|
||||
192.168.0.2 51235
|
||||
```
|
||||
|
||||
**Note:** If you omit the port number, the server uses port 2459, the IANA-assigned port for the XRP Ledger protocol.
|
||||
|
||||
@@ -58,15 +66,19 @@ To set up a specific server as a private peer, complete the following steps:
|
||||
|
||||
If you are using public hubs, skip this step.
|
||||
|
||||
If you are using proxies, [configure the proxies as a cluster](cluster-rippled-servers.html) that includes your private peer. Each member of the cluster should have an `[ips_fixed]` stanza that lists each _other_ member of the cluster. However, **only the private server** should have a `[peer_private]` stanza.
|
||||
If you are using proxies, [configure the proxies as a cluster](cluster-rippled-servers.md) that includes your private peer. Each member of the cluster should have an `[ips_fixed]` stanza that lists each _other_ member of the cluster. However, **only the private server** should have a `[peer_private]` stanza.
|
||||
|
||||
Restart `rippled` on the proxies one-by-one. On each proxy server:
|
||||
|
||||
sudo service systemctl restart rippled
|
||||
```
|
||||
sudo service systemctl restart rippled
|
||||
```
|
||||
|
||||
5. Start `rippled` on the private server.
|
||||
|
||||
sudo service systemctl start rippled
|
||||
```
|
||||
sudo service systemctl start rippled
|
||||
```
|
||||
|
||||
6. Use the [peers method][] to confirm that your private server is connected _only_ to its peers.
|
||||
|
||||
@@ -75,26 +87,22 @@ To set up a specific server as a private peer, complete the following steps:
|
||||
|
||||
## Next Steps
|
||||
|
||||
As an additional precaution, you should configure your firewall to block incoming connections to your private server from servers that are not your specific peers. If you are running proxy servers, [forward peer ports](forward-ports-for-peering.html) through your firewall to the proxies, but **not** to the private peer. The exact details of how to configure this depend on what firewall you use.
|
||||
As an additional precaution, you should configure your firewall to block incoming connections to your private server from servers that are not your specific peers. If you are running proxy servers, [forward peer ports](forward-ports-for-peering.md) through your firewall to the proxies, but **not** to the private peer. The exact details of how to configure this depend on what firewall you use.
|
||||
|
||||
Be sure the firewall **does not block** outgoing HTTP connections on port 80. The default configuration uses this port to download the latest recommended validator list from **vl.ripple.com**. Without a validator list, the server does not know which validators to trust and cannot recognize when the network reaches a consensus.
|
||||
|
||||
## See Also
|
||||
|
||||
- **Concepts:**
|
||||
- [Peer Protocol](peer-protocol.html)
|
||||
- [Consensus](consensus.html)
|
||||
- [Parallel Networks](parallel-networks.html)
|
||||
- [Peer Protocol](../../../concepts/networks-and-servers/peer-protocol.md)
|
||||
- [Consensus](../../../concepts/consensus-protocol/index.md)
|
||||
- [Parallel Networks](../../../concepts/networks-and-servers/parallel-networks.md)
|
||||
- **Tutorials:**
|
||||
- [Configure the Peer Crawler](configure-the-peer-crawler.html)
|
||||
- [Configure the Peer Crawler](configure-the-peer-crawler.md)
|
||||
- **References:**
|
||||
- [peers method][]
|
||||
- [connect method][]
|
||||
- [fetch_info method][]
|
||||
- [Peer Crawler](peer-crawler.html)
|
||||
- [Peer Crawler](../../../references/http-websocket-apis/peer-port-methods/peer-crawler.md)
|
||||
|
||||
|
||||
<!--{# common link defs #}-->
|
||||
{% include '_snippets/rippled-api-links.md' %}
|
||||
{% include '_snippets/tx-type-links.md' %}
|
||||
{% include '_snippets/rippled_versions.md' %}
|
||||
{% raw-partial file="/_snippets/common-links.md" /%}
|
||||
|
||||
@@ -8,7 +8,7 @@ labels:
|
||||
---
|
||||
# Configure the Peer Crawler
|
||||
|
||||
By default, [`rippled` servers](xrpl-servers.html) provide statistics publicly to anyone who asks using the [peer crawler API](peer-crawler.html), to make it easier to track the health and topology of [the XRP Ledger's peer-to-peer network](peer-protocol.html). You can configure your server to provide more or less information, or to reject peer crawler requests entirely.
|
||||
By default, [`rippled` servers](../../../concepts/networks-and-servers/index.md) provide statistics publicly to anyone who asks using the [peer crawler API](../../../references/http-websocket-apis/peer-port-methods/peer-crawler.md), to make it easier to track the health and topology of [the XRP Ledger's peer-to-peer network](../../../concepts/networks-and-servers/peer-protocol.md). You can configure your server to provide more or less information, or to reject peer crawler requests entirely.
|
||||
|
||||
This document contains steps for two options:
|
||||
|
||||
@@ -21,23 +21,29 @@ To configure how much information your server provides in response to peer crawl
|
||||
|
||||
1. Edit your `rippled`'s config file.
|
||||
|
||||
vim /etc/opt/ripple/rippled.cfg
|
||||
```
|
||||
vim /etc/opt/ripple/rippled.cfg
|
||||
```
|
||||
|
||||
{% include '_snippets/conf-file-location.md' %}<!--_ -->
|
||||
{% partial file="/_snippets/conf-file-location.md" /%}
|
||||
|
||||
2. Add or update the `[crawl]` stanza in your config file, and save the changes:
|
||||
|
||||
[crawl]
|
||||
overlay = 1
|
||||
server = 1
|
||||
counts = 0
|
||||
unl = 1
|
||||
```
|
||||
[crawl]
|
||||
overlay = 1
|
||||
server = 1
|
||||
counts = 0
|
||||
unl = 1
|
||||
```
|
||||
|
||||
The fields in this stanza control which fields the server returns in the [peer crawler response](peer-crawler.html#response-format). The names of the config fields match the fields of the API response. A setting with a value of `1` means to include the field in the response. A value of `0` means to omit that field from the response. This example shows the default values for each setting.
|
||||
The fields in this stanza control which fields the server returns in the [peer crawler response](../../../references/http-websocket-apis/peer-port-methods/peer-crawler.md#response-format). The names of the config fields match the fields of the API response. A setting with a value of `1` means to include the field in the response. A value of `0` means to omit that field from the response. This example shows the default values for each setting.
|
||||
|
||||
3. After saving the changes to the config file, restart your `rippled` server to apply the updated configuration:
|
||||
|
||||
systemctl restart rippled
|
||||
```
|
||||
systemctl restart rippled
|
||||
```
|
||||
|
||||
|
||||
## Disable the Peer Crawler
|
||||
@@ -46,34 +52,37 @@ To disable the peer crawler API on your server, so it does not respond to peer c
|
||||
|
||||
1. Edit your `rippled`'s config file.
|
||||
|
||||
vim /etc/opt/ripple/rippled.cfg
|
||||
```
|
||||
vim /etc/opt/ripple/rippled.cfg
|
||||
```
|
||||
|
||||
{% include '_snippets/conf-file-location.md' %}<!--_ -->
|
||||
{% partial file="/_snippets/conf-file-location.md" /%}
|
||||
|
||||
2. Add or update the `[crawl]` stanza in your config file, and save the changes:
|
||||
|
||||
[crawl]
|
||||
0
|
||||
```
|
||||
[crawl]
|
||||
0
|
||||
```
|
||||
|
||||
Remove or comment out all other contents of the crawl stanza.
|
||||
|
||||
3. After saving the changes to the config file, restart your `rippled` server to apply the updated configuration:
|
||||
|
||||
systemctl restart rippled
|
||||
```
|
||||
systemctl restart rippled
|
||||
```
|
||||
|
||||
|
||||
## See Also
|
||||
|
||||
- **Concepts:**
|
||||
- [Peer Protocol](peer-protocol.html)
|
||||
- [Peer Protocol](../../../concepts/networks-and-servers/peer-protocol.md)
|
||||
- **Tutorials:**
|
||||
- [Manage the rippled Server](manage-the-rippled-server.html)
|
||||
- [Manage the rippled Server](../../installation/install-rippled-on-ubuntu.md)
|
||||
- **References:**
|
||||
- [server_info method][]
|
||||
- [peers method][]
|
||||
- [Peer Crawler](peer-crawler.html)
|
||||
- [Peer Crawler](../../../references/http-websocket-apis/peer-port-methods/peer-crawler.md)
|
||||
|
||||
<!--{# common link defs #}-->
|
||||
{% include '_snippets/rippled-api-links.md' %}
|
||||
{% include '_snippets/tx-type-links.md' %}
|
||||
{% include '_snippets/rippled_versions.md' %}
|
||||
{% raw-partial file="/_snippets/common-links.md" /%}
|
||||
|
||||
@@ -7,7 +7,7 @@ labels:
|
||||
---
|
||||
# Enable Link Compression
|
||||
|
||||
The `rippled` server can save bandwidth by compressing its [peer-to-peer communications](peer-protocol.html), at a cost of greater CPU usage. If you enable link compression, the server automatically compresses communications with peer servers that also have link compression enabled.
|
||||
The `rippled` server can save bandwidth by compressing its [peer-to-peer communications](../../../concepts/networks-and-servers/peer-protocol.md), at a cost of greater CPU usage. If you enable link compression, the server automatically compresses communications with peer servers that also have link compression enabled.
|
||||
|
||||
## Steps
|
||||
|
||||
@@ -19,7 +19,7 @@ To enable link compression on your server, complete the following steps:
|
||||
$ vim /etc/opt/ripple/rippled.cfg
|
||||
```
|
||||
|
||||
{% include '_snippets/conf-file-location.md' %}<!--_ -->
|
||||
{% partial file="/_snippets/conf-file-location.md" /%}
|
||||
|
||||
### 2. In the config file, add or uncomment the `[compression]` stanza.
|
||||
|
||||
@@ -42,10 +42,7 @@ After the restart, your server automatically uses link compression with other pe
|
||||
|
||||
## See Also
|
||||
|
||||
- [Capacity Planning](capacity-planning.html)
|
||||
- [Peer Protocol](peer-protocol.html)
|
||||
- [Capacity Planning](../../installation/capacity-planning.md)
|
||||
- [Peer Protocol](../../../concepts/networks-and-servers/peer-protocol.md)
|
||||
|
||||
<!--{# common link defs #}-->
|
||||
{% include '_snippets/rippled-api-links.md' %}
|
||||
{% include '_snippets/tx-type-links.md' %}
|
||||
{% include '_snippets/rippled_versions.md' %}
|
||||
{% raw-partial file="/_snippets/common-links.md" /%}
|
||||
|
||||
@@ -7,7 +7,7 @@ labels:
|
||||
---
|
||||
# Forward Ports for Peering
|
||||
|
||||
Servers in the XRP Ledger peer-to-peer network communicate over the [peer protocol](peer-protocol.html). For the best combination of security and connectivity to the rest of the network, you should use a firewall to protect your server from most ports, but open or forward the peer protocol port.
|
||||
Servers in the XRP Ledger peer-to-peer network communicate over the [peer protocol](../../../concepts/networks-and-servers/peer-protocol.md). For the best combination of security and connectivity to the rest of the network, you should use a firewall to protect your server from most ports, but open or forward the peer protocol port.
|
||||
|
||||
While your `rippled` server is running, you can check to see how many peers you have by running the [server_info method][]. The `peers` field of the `info` object shows how many peers are currently connected to your server. If this number is exactly 10 or 11, that usually means your firewall is blocking incoming connections.
|
||||
|
||||
@@ -67,18 +67,15 @@ If you are using a hosting service with a virtual firewall (for example, [AWS Se
|
||||
## See Also
|
||||
|
||||
- **Concepts:**
|
||||
- [Peer Protocol](peer-protocol.html)
|
||||
- [The `rippled` Server](xrpl-servers.html)
|
||||
- [Peer Protocol](../../../concepts/networks-and-servers/peer-protocol.md)
|
||||
- [The `rippled` Server](../../../concepts/networks-and-servers/index.md)
|
||||
- **Tutorials:**
|
||||
- [Capacity Planning](capacity-planning.html)
|
||||
- [Troubleshoot the `rippled` Server](troubleshoot-the-rippled-server.html)
|
||||
- [Capacity Planning](../../installation/capacity-planning.md)
|
||||
- [Troubleshoot the `rippled` Server](../../troubleshooting/index.md)
|
||||
- **References:**
|
||||
- [connect method][]
|
||||
- [peers method][]
|
||||
- [print method][]
|
||||
- [server_info method][]
|
||||
|
||||
<!--{# common link defs #}-->
|
||||
{% include '_snippets/rippled-api-links.md' %}
|
||||
{% include '_snippets/tx-type-links.md' %}
|
||||
{% include '_snippets/rippled_versions.md' %}
|
||||
{% raw-partial file="/_snippets/common-links.md" /%}
|
||||
|
||||
@@ -2,7 +2,8 @@
|
||||
html: configure-peering.html
|
||||
name: Peering
|
||||
parent: configure-rippled.html
|
||||
template: pagetype-category.html.jinja
|
||||
metadata:
|
||||
indexPage: true
|
||||
blurb: Configure how your server connects to the peer-to-peer network.
|
||||
labels:
|
||||
- Core Server
|
||||
@@ -11,4 +12,7 @@ labels:
|
||||
|
||||
The XRP Ledger's peer-to-peer protocol automatically manages peer connections in most cases. In some cases, you may want to manually adjust which peers your server connects to, to maximize your server's availability and connectivity with the rest of the network.
|
||||
|
||||
If you run multiple servers in the same datacenter, you may want [to cluster them](cluster-rippled-servers.html) to improve efficiency. You can use reserved peer slots for servers you don't run but want to stay connected to, such as important hubs in the topology of the peer-to-peer network. For other peers, the server can automatically find peers and manage its connections, although you may occasionally want to intervene to block a peer that's behaving undesirably.
|
||||
If you run multiple servers in the same datacenter, you may want [to cluster them](cluster-rippled-servers.md) to improve efficiency. You can use reserved peer slots for servers you don't run but want to stay connected to, such as important hubs in the topology of the peer-to-peer network. For other peers, the server can automatically find peers and manage its connections, although you may occasionally want to intervene to block a peer that's behaving undesirably.
|
||||
|
||||
|
||||
{% child-pages /%}
|
||||
|
||||
@@ -7,26 +7,25 @@ labels:
|
||||
---
|
||||
# Manually Connect to a Specific Peer
|
||||
|
||||
Use these steps to manually connect your server to a specific [peer](peer-protocol.html) in the XRP Ledger network.
|
||||
Use these steps to manually connect your server to a specific [peer](../../../concepts/networks-and-servers/peer-protocol.md) in the XRP Ledger network.
|
||||
|
||||
**Tip:** If you want to make sure your server automatically connects to this server on startup and remains connected later, you may want to configure a [peer reservation](use-a-peer-reservation.html) for that peer.
|
||||
**Tip:** If you want to make sure your server automatically connects to this server on startup and remains connected later, you may want to configure a [peer reservation](use-a-peer-reservation.md) for that peer.
|
||||
|
||||
|
||||
## Prerequisites
|
||||
|
||||
- You must know the IP address of the peer you want to connect to.
|
||||
- You must know what port the peer you want to connect to uses for the XRP Ledger [peer protocol](peer-protocol.html). The default config file uses port 51235.
|
||||
- You must have a network connection from your server to the peer. For example, the peer server must [forward the appropriate port through its firewall](forward-ports-for-peering.html).
|
||||
- The peer server must have available peer slots. If the peer is already at its maximum number of peers, you can ask the peer server's operator to add a [peer reservation](use-a-peer-reservation.html) for your server.
|
||||
- You must know what port the peer you want to connect to uses for the XRP Ledger [peer protocol](../../../concepts/networks-and-servers/peer-protocol.md). The default config file uses port 51235.
|
||||
- You must have a network connection from your server to the peer. For example, the peer server must [forward the appropriate port through its firewall](forward-ports-for-peering.md).
|
||||
- The peer server must have available peer slots. If the peer is already at its maximum number of peers, you can ask the peer server's operator to add a [peer reservation](use-a-peer-reservation.md) for your server.
|
||||
|
||||
## Steps
|
||||
|
||||
To connect, use the [connect method][]. For example:
|
||||
|
||||
<!-- MULTICODE_BLOCK_START -->
|
||||
|
||||
*WebSocket*
|
||||
{% tabs %}
|
||||
|
||||
{% tab label="WebSocket" %}
|
||||
```
|
||||
{
|
||||
"command": "connect",
|
||||
@@ -34,9 +33,9 @@ To connect, use the [connect method][]. For example:
|
||||
"port": 51235
|
||||
}
|
||||
```
|
||||
{% /tab %}
|
||||
|
||||
*JSON-RPC*
|
||||
|
||||
{% tab label="JSON-RPC" %}
|
||||
```
|
||||
{
|
||||
"method": "connect",
|
||||
@@ -48,32 +47,29 @@ To connect, use the [connect method][]. For example:
|
||||
]
|
||||
}
|
||||
```
|
||||
{% /tab %}
|
||||
|
||||
|
||||
*Commandline*
|
||||
|
||||
{% tab label="Commandline" %}
|
||||
```
|
||||
rippled connect 169.54.2.151 51235
|
||||
```
|
||||
{% /tab %}
|
||||
|
||||
<!-- MULTICODE_BLOCK_END -->
|
||||
{% /tabs %}
|
||||
|
||||
|
||||
## See Also
|
||||
|
||||
- **Concepts:**
|
||||
- [Peer Protocol](peer-protocol.html)
|
||||
- [The `rippled` Server](xrpl-servers.html)
|
||||
- [Peer Protocol](../../../concepts/networks-and-servers/peer-protocol.md)
|
||||
- [The `rippled` Server](../../../concepts/networks-and-servers/index.md)
|
||||
- **Tutorials:**
|
||||
- [Capacity Planning](capacity-planning.html)
|
||||
- [Troubleshoot the `rippled` Server](troubleshoot-the-rippled-server.html)
|
||||
- [Capacity Planning](../../installation/capacity-planning.md)
|
||||
- [Troubleshoot the `rippled` Server](../../troubleshooting/index.md)
|
||||
- **References:**
|
||||
- [connect method][]
|
||||
- [peers method][]
|
||||
- [print method][]
|
||||
- [server_info method][]
|
||||
|
||||
<!--{# common link defs #}-->
|
||||
{% include '_snippets/rippled-api-links.md' %}
|
||||
{% include '_snippets/tx-type-links.md' %}
|
||||
{% include '_snippets/rippled_versions.md' %}
|
||||
{% raw-partial file="/_snippets/common-links.md" /%}
|
||||
|
||||
@@ -7,49 +7,52 @@ labels:
|
||||
---
|
||||
# Set Maximum Number of Peers
|
||||
|
||||
The `rippled` server has a configurable soft maximum number of [peers](peer-protocol.html) to connect to. The default maximum number of peers is **21**.
|
||||
The `rippled` server has a configurable soft maximum number of [peers](../../../concepts/networks-and-servers/peer-protocol.md) to connect to. The default maximum number of peers is **21**.
|
||||
|
||||
**Note:** Internally, the server generates approximate quotas of incoming and outgoing peers. You can potentially go over the soft maximum if you are using [fixed peers, peer reservations](peer-protocol.html#fixed-peers-and-peer-reservations), or if you manually connect to additional peers using the [connect method][].
|
||||
**Note:** Internally, the server generates approximate quotas of incoming and outgoing peers. You can potentially go over the soft maximum if you are using [fixed peers, peer reservations](../../../concepts/networks-and-servers/peer-protocol.md#fixed-peers-and-peer-reservations), or if you manually connect to additional peers using the [connect method][].
|
||||
|
||||
To change the maximum number of peers your server allows, complete the following steps:
|
||||
|
||||
1. Edit your `rippled`'s config file.
|
||||
|
||||
$ vim /etc/opt/ripple/rippled.cfg
|
||||
```
|
||||
$ vim /etc/opt/ripple/rippled.cfg
|
||||
```
|
||||
|
||||
{% include '_snippets/conf-file-location.md' %}<!--_ -->
|
||||
{% partial file="/_snippets/conf-file-location.md" /%}
|
||||
|
||||
2. In the config file, uncomment and edit the `[peers_max]` stanza, or add one if you don't have one already:
|
||||
|
||||
[peers_max]
|
||||
30
|
||||
```
|
||||
[peers_max]
|
||||
30
|
||||
```
|
||||
|
||||
The only content of the stanza should be an integer indicating the total number of peers to allow. By default, the server attempts to maintain a ratio of about 85% incoming and 15% outgoing peers, but with a minimum of 10 outgoing peers, so any value less than 68 won't increase the number of outgoing peer connections your server makes.
|
||||
|
||||
If the `[peers_max]` value is less than 10, the server still allows a hardcoded minimum of 10 outgoing peers so that it can maintain connectivity with the network. To block all outgoing peer connections, [configure the server as a private peer](run-rippled-as-a-validator.html#connect-using-proxies) instead.
|
||||
If the `[peers_max]` value is less than 10, the server still allows a hardcoded minimum of 10 outgoing peers so that it can maintain connectivity with the network. To block all outgoing peer connections, [configure the server as a private peer](../server-modes/run-rippled-as-a-validator.md#connect-using-proxies) instead.
|
||||
|
||||
**Caution:** The more peer servers you are connected to, the more network bandwidth your `rippled` server uses. You should only configure large numbers of peer servers if your `rippled` server has a good network connection and you can afford the costs you may incur for the bandwidth it uses.
|
||||
|
||||
3. Restart the `rippled` server.
|
||||
|
||||
$ sudo systemctl restart rippled.service
|
||||
```
|
||||
$ sudo systemctl restart rippled.service
|
||||
```
|
||||
|
||||
|
||||
## See Also
|
||||
|
||||
- **Concepts:**
|
||||
- [Peer Protocol](peer-protocol.html)
|
||||
- [The `rippled` Server](xrpl-servers.html)
|
||||
- [Peer Protocol](../../../concepts/networks-and-servers/peer-protocol.md)
|
||||
- [The `rippled` Server](../../../concepts/networks-and-servers/index.md)
|
||||
- **Tutorials:**
|
||||
- [Capacity Planning](capacity-planning.html)
|
||||
- [Troubleshoot the `rippled` Server](troubleshoot-the-rippled-server.html)
|
||||
- [Capacity Planning](../../installation/capacity-planning.md)
|
||||
- [Troubleshoot the `rippled` Server](../../troubleshooting/index.md)
|
||||
- **References:**
|
||||
- [connect method][]
|
||||
- [peers method][]
|
||||
- [print method][]
|
||||
- [server_info method][]
|
||||
|
||||
<!--{# common link defs #}-->
|
||||
{% include '_snippets/rippled-api-links.md' %}
|
||||
{% include '_snippets/tx-type-links.md' %}
|
||||
{% include '_snippets/rippled_versions.md' %}
|
||||
{% raw-partial file="/_snippets/common-links.md" /%}
|
||||
|
||||
@@ -9,7 +9,7 @@ labels:
|
||||
|
||||
A [peer reservation][] is a setting that makes a `rippled` server always accept connections from a peer matching the reservation. This page describes how to use peer reservations to keep a consistent peer-to-peer connection between two servers, with the cooperation of the administrators of both servers.
|
||||
|
||||
Peer reservations are most useful when the two servers are run by different parties, and the server that receives the incoming connection is a [hub server](rippled-server-modes.html#public-hubs) with many peers. For clarity, these instructions use the following terms:
|
||||
Peer reservations are most useful when the two servers are run by different parties, and the server that receives the incoming connection is a [hub server](../../../concepts/networks-and-servers/rippled-server-modes.md#public-hubs) with many peers. For clarity, these instructions use the following terms:
|
||||
|
||||
- The server making the outgoing connection is the **stock server**. This server _uses_ the peer reservation on the hub server.
|
||||
- The server receiving the incoming connection is the **hub server**. The administrator _adds_ the peer reservation to this server.
|
||||
@@ -20,10 +20,10 @@ However, you can use these instructions to set up a peer reservation regardless
|
||||
|
||||
To complete these steps, you must meet the following prerequisites:
|
||||
|
||||
- The administrators both servers must have `rippled` [installed](install-rippled.html) and running.
|
||||
- The administrators both servers must have `rippled` [installed](../../installation/index.md) and running.
|
||||
- The administrators of both servers must agree to cooperate and must be able to communicate. A public communications channel is fine because you don't need to share any secret information.
|
||||
- The hub server must be able to receive incoming peer connections. For instructions on how to configure a firewall to allow this, see [Forward Ports for Peering](forward-ports-for-peering.html).
|
||||
- Both servers must be configured to sync with the same [XRP Ledger network](parallel-networks.html), such as the production XRP Ledger, the Testnet, or the Devnet.
|
||||
- The hub server must be able to receive incoming peer connections. For instructions on how to configure a firewall to allow this, see [Forward Ports for Peering](forward-ports-for-peering.md).
|
||||
- Both servers must be configured to sync with the same [XRP Ledger network](../../../concepts/networks-and-servers/parallel-networks.md), such as the production XRP Ledger, the Testnet, or the Devnet.
|
||||
|
||||
## Steps
|
||||
|
||||
@@ -33,7 +33,7 @@ To use a peer reservation, complete the following steps:
|
||||
|
||||
The administrator of the stock server completes this step.
|
||||
|
||||
If you have already configured your server with a permanent node key pair value, you can skip ahead to [step 2: Communicate your node public key to the peer's admin](#2-communicate-the-stock-servers-node-public-key). (For example, setting up a permanent node key pair for each server is part of the process of [setting up a server cluster](cluster-rippled-servers.html).)
|
||||
If you have already configured your server with a permanent node key pair value, you can skip ahead to [step 2: Communicate your node public key to the peer's admin](#2-communicate-the-stock-servers-node-public-key). (For example, setting up a permanent node key pair for each server is part of the process of [setting up a server cluster](cluster-rippled-servers.md).)
|
||||
|
||||
**Tip:** Setting up a permanent node key pair is optional, but makes it easier to keep the peer reservation set up if you need to erase your server's databases or move to a new machine. If you don't want to set up a permanent node key pair, you can use your server's automatically-generated node public key as reported in the `pubkey_node` field of the [server_info method][] response.
|
||||
|
||||
@@ -41,39 +41,47 @@ If you have already configured your server with a permanent node key pair value,
|
||||
|
||||
For example:
|
||||
|
||||
rippled validation_create
|
||||
```
|
||||
rippled validation_create
|
||||
|
||||
Loading: "/etc/rippled.cfg"
|
||||
Connecting to 127.0.0.1:5005
|
||||
{
|
||||
"result" : {
|
||||
"status" : "success",
|
||||
"validation_key" : "FAWN JAVA JADE HEAL VARY HER REEL SHAW GAIL ARCH BEN IRMA",
|
||||
"validation_public_key" : "n9Mxf6qD4J55XeLSCEpqaePW4GjoCR5U1ZeGZGJUCNe3bQa4yQbG",
|
||||
"validation_seed" : "ssZkdwURFMBXenJPbrpE14b6noJSu"
|
||||
}
|
||||
}
|
||||
Loading: "/etc/rippled.cfg"
|
||||
Connecting to 127.0.0.1:5005
|
||||
{
|
||||
"result" : {
|
||||
"status" : "success",
|
||||
"validation_key" : "FAWN JAVA JADE HEAL VARY HER REEL SHAW GAIL ARCH BEN IRMA",
|
||||
"validation_public_key" : "n9Mxf6qD4J55XeLSCEpqaePW4GjoCR5U1ZeGZGJUCNe3bQa4yQbG",
|
||||
"validation_seed" : "ssZkdwURFMBXenJPbrpE14b6noJSu"
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
Save the `validation_seed` (your node seed value) and the `validation_public_key` value (your node public key )
|
||||
|
||||
2. Edit your `rippled`'s config file.
|
||||
|
||||
vim /etc/opt/ripple/rippled.cfg
|
||||
```
|
||||
vim /etc/opt/ripple/rippled.cfg
|
||||
```
|
||||
|
||||
{% include '_snippets/conf-file-location.md' %}<!--_ -->
|
||||
{% partial file="/_snippets/conf-file-location.md" /%}
|
||||
|
||||
3. Add a `[node_seed]` stanza using the `validation_seed` value you generated earlier.
|
||||
|
||||
For example:
|
||||
|
||||
[node_seed]
|
||||
ssZkdwURFMBXenJPbrpE14b6noJSu
|
||||
```
|
||||
[node_seed]
|
||||
ssZkdwURFMBXenJPbrpE14b6noJSu
|
||||
```
|
||||
|
||||
**Warning:** All servers should have unique `[node_seed]` values. If you copy your config file to another server, be sure to remove or change the `[node_seed]` value. Keep your `[node_seed]` secret; if a malicious actor gains access to this value, they could use it to impersonate your server in XRP Ledger peer-to-peer communications.
|
||||
|
||||
4. Restart your `rippled` server:
|
||||
|
||||
systemctl restart rippled
|
||||
```
|
||||
systemctl restart rippled
|
||||
```
|
||||
|
||||
### 2. Communicate the stock server's node public key
|
||||
|
||||
@@ -110,10 +118,9 @@ The administrator of the stock server completes this step.
|
||||
|
||||
Use the [connect method][] to connect your server to the hub server. For example:
|
||||
|
||||
<!-- MULTICODE_BLOCK_START -->
|
||||
|
||||
*WebSocket*
|
||||
{% tabs %}
|
||||
|
||||
{% tab label="WebSocket" %}
|
||||
```
|
||||
{
|
||||
"command": "connect",
|
||||
@@ -121,9 +128,9 @@ Use the [connect method][] to connect your server to the hub server. For example
|
||||
"port": 51235
|
||||
}
|
||||
```
|
||||
{% /tab %}
|
||||
|
||||
*JSON-RPC*
|
||||
|
||||
{% tab label="JSON-RPC" %}
|
||||
```
|
||||
{
|
||||
"method": "connect",
|
||||
@@ -135,15 +142,15 @@ Use the [connect method][] to connect your server to the hub server. For example
|
||||
]
|
||||
}
|
||||
```
|
||||
{% /tab %}
|
||||
|
||||
|
||||
*Commandline*
|
||||
|
||||
{% tab label="Commandline" %}
|
||||
```
|
||||
rippled connect 169.54.2.151 51235
|
||||
```
|
||||
{% /tab %}
|
||||
|
||||
<!-- MULTICODE_BLOCK_END -->
|
||||
{% /tabs %}
|
||||
|
||||
If the hub server's administrator has set up the peer reservation as described in the previous steps, this should automatically connect and remain connected as long as possible.
|
||||
|
||||
@@ -163,12 +170,12 @@ As a server administrator, you can manage the reservations your server has for o
|
||||
## See Also
|
||||
|
||||
- **Concepts:**
|
||||
- [Peer Protocol](peer-protocol.html)
|
||||
- [Consensus](consensus.html)
|
||||
- [Parallel Networks](parallel-networks.html)
|
||||
- [Peer Protocol](../../../concepts/networks-and-servers/peer-protocol.md)
|
||||
- [Consensus](../../../concepts/consensus-protocol/index.md)
|
||||
- [Parallel Networks](../../../concepts/networks-and-servers/parallel-networks.md)
|
||||
- **Tutorials:**
|
||||
- [Capacity Planning](capacity-planning.html)
|
||||
- [Troubleshooting `rippled`](troubleshoot-the-rippled-server.html)
|
||||
- [Capacity Planning](../../installation/capacity-planning.md)
|
||||
- [Troubleshooting `rippled`](../../troubleshooting/index.md)
|
||||
- **References:**
|
||||
- [peers method][]
|
||||
- [peer_reservations_add method][]
|
||||
@@ -176,10 +183,6 @@ As a server administrator, you can manage the reservations your server has for o
|
||||
- [peer_reservations_list method][]
|
||||
- [connect method][]
|
||||
- [fetch_info method][]
|
||||
- [Peer Crawler](peer-crawler.html)
|
||||
- [Peer Crawler](../../../references/http-websocket-apis/peer-port-methods/peer-crawler.md)
|
||||
|
||||
|
||||
<!--{# common link defs #}-->
|
||||
{% include '_snippets/rippled-api-links.md' %}
|
||||
{% include '_snippets/tx-type-links.md' %}
|
||||
{% include '_snippets/rippled_versions.md' %}
|
||||
{% raw-partial file="/_snippets/common-links.md" /%}
|
||||
|
||||
Reference in New Issue
Block a user