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: docs/bee/installation/connectivity.md
+56-3Lines changed: 56 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,7 +19,7 @@ you still have problems, please join us in our [Discord
19
19
server](https://discord.gg/wdghaQsGq5) and we'll help you find the
20
20
way! 🐝 🐝 🐝 🐝 🐝
21
21
22
-
:::info
22
+
:::warning
23
23
To ensure your Bee has the best chance of participating in the swarm,
24
24
you must ensure your Bee is able to handle **both incoming and
25
25
outgoing connections from the global Internet to its p2p port
@@ -31,6 +31,8 @@ Internet! You may need to alter your Bee node's `nat-addr`
31
31
configuration. 🤓
32
32
:::
33
33
34
+
35
+
34
36
## Networking Basics
35
37
36
38
In a network, each computer is assigned an IP address. Each IP address
@@ -298,7 +300,58 @@ to your computer's MAC address. This will ensure that your Bee
298
300
seamlessly connects when you rejoin the network!
299
301
:::
300
302
301
-
### Debugging Connectivity
303
+
### Using multiple P2P transports (TCP, WS, WSS)
304
+
305
+
A Bee node can expose more than one transport for peer-to-peer communication. By default, nodes use the TCP-based libp2p transport, but Secure WebSocket (`WSS`) transport can also be enabled.
306
+
307
+
To enable WSS support, set:
308
+
309
+
```yaml
310
+
p2p-wss-enable: true
311
+
````
312
+
313
+
When enabled, Bee listens for Secure WebSocket connections on `p2p-wss-addr` (default `:1635`). In most cases the remaining WSS and AutoTLS options can be left at their default values:
A configuration using both TCP and WSS transports may look like:
325
+
326
+
```yaml
327
+
p2p-addr: :1634
328
+
p2p-wss-enable: true
329
+
p2p-wss-addr: :1635
330
+
331
+
nat-addr: 1.2.3.4:1634
332
+
nat-wss-addr: node.example.com:443
333
+
```
334
+
335
+
In this example:
336
+
337
+
* `p2p-addr` defines the local TCP listening address.
338
+
* `p2p-wss-addr` defines the local Secure WebSocket listening address.
339
+
* `nat-addr` is the public address advertised to peers for TCP connections.
340
+
* `nat-wss-addr` is the public address advertised to peers for WSS connections.
341
+
342
+
If WSS is enabled, the WSS port must be reachable by peers. This means the port should be open in your firewall, exposed by your container or host configuration, and permitted by your network if outbound connections are restricted.
343
+
344
+
When specifying `nat-addr` or `nat-wss-addr`, the value must be a valid `host:port` pair. For example:
345
+
346
+
```yaml
347
+
nat-addr: 1.2.3.4:1634
348
+
nat-wss-addr: node.example.com:443
349
+
```
350
+
351
+
Values missing either the host or port or otherwise misformed addresses are considered invalid and will prevent the node from starting.
352
+
353
+
354
+
### Troubleshooting Connectivity
302
355
303
356
The above guide navigates your NAT, but there are still a few hurdles to overcome. To make sure there is a clear path from your computer to the outside world, let's follow our Bee's journey from the inside out.
304
357
@@ -379,7 +432,7 @@ the open Internet. Ensure that both TCP and UDP traffic are allowed.
379
432
380
433
Similarly, if you are connecting from within a private network, you
381
434
may find that the port is blocked by the router. Each router is
382
-
different, so consult your router's firware documentation to make
435
+
different, so consult your router's firmware documentation to make
383
436
sure there are no firewalls in place blocking traffic on your Bee's
Copy file name to clipboardExpand all lines: docs/bee/working-with-bee/bee-api.md
+3-2Lines changed: 3 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -333,15 +333,16 @@ From the results we can see that our node's neighborhood size and batch commitme
333
333
{
334
334
"radius": 15,
335
335
"storageRadius": 10,
336
-
"commitment": 134121783296
336
+
"commitment": 134121783296,
337
+
"reserveCapacityDoubling": 0
337
338
}
338
339
```
339
340
340
341
Let's take a look at each of these values:
341
342
* `"radius"` - Represents the maximum storage radius assuming all postage stamp batches are fully utilized.
342
343
* `"storageRadius"` - The radius of responsibility - the proximity order of chunks for which your node is responsible for storing. It should generally match the radius shown on [Swarmscan](https://swarmscan.io/neighborhoods).
343
344
* `"commitment"` - The total number of chunks which would be stored on the Swarm network if 100% of all postage batches were fully utilised.
344
-
345
+
* `"reserveCapacityDoubling"` - Indicates whether your node is currently using the reserve doubling mechanism. See [Reserve Doubling](/docs/bee/working-with-bee/staking#reserve-doubling) for details.
345
346
### _/chainstate_
346
347
347
348
This endpoint relates to your node's interactions with the Swarm Smart contracts on the Gnosis Chain.
# path to a file that contains password for decrypting keys
@@ -219,7 +240,7 @@ price-oracle-address: ""
219
240
# redistribution contract address
220
241
redistribution-address: ""
221
242
# reserve capacity doubling
222
-
reserve-capacity-doubling: "1"
243
+
reserve-capacity-doubling: "0"
223
244
# ENS compatible API endpoint for a TLD and with contract address, can be repeated, format [tld:][contract-addr@]url
224
245
resolver-options: []
225
246
# forces the node to resync postage contract data
@@ -583,6 +604,9 @@ Then configure your node, including your p2p port (default 1634).
583
604
nat-addr: "123.123.123.123:1634"
584
605
```
585
606
607
+
Ensure `nat-addr` and `nat-wss-addr`if used are set to valid `host:port` values — invalid values prevent the node from starting.
608
+
609
+
586
610
## ENS Resolution (Optional)
587
611
588
612
The [ENS](https://ens.domains/) domain resolution system is used to host websites on Bee, and in order to use this your Bee must be connected to a mainnet Ethereum blockchain node. We recommend you run your own ethereum node. An option for resource restricted devices is geth+nimbus and a guide can be found [here](https://ethereum-on-arm-documentation.readthedocs.io/en/latest/). Other options include [dappnode](https://dappnode.io/), [nicenode](https://www.nicenode.xyz/), [stereum](https://stereum.net/) and [avado](https://ava.do/).
0 commit comments