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
{{ message }}
This repository was archived by the owner on Nov 15, 2023. It is now read-only.
If you want to see the multi-node consensus algorithm in action locally, then you can create a local testnet with two validator nodes for Alice and Bob, who are the initial authorities of the genesis chain that have been endowed with testnet units.
62
+
### Multi-Node Local Testnet
46
63
47
-
Optionally, give each node a name and expose them so they are listed on the Polkadot [telemetry site](https://telemetry.polkadot.io/#/Local%20Testnet).
64
+
To see the multi-node consensus algorithm in action, run a local testnet with two validator nodes,
65
+
Alice and Bob, that have been [configured](/bin/node-template/node/src/chain_spec.rs) as the
66
+
initial authorities of the `local` testnet chain and endowed with testnet units.
48
67
49
-
You'll need two terminal windows open.
68
+
Note: this will require two terminal sessions (one for each node).
50
69
51
-
We'll start Alice's substrate node first on default TCP port 30333 with her chain database stored locally at `/tmp/alice`. The bootnode ID of her node is `QmRpheLN4JWdAnY7HGJfWFNbfkQCb6tFf4vvA6hgjMZKrR`, which is generated from the `--node-key` value that we specify below:
70
+
Start Alice's node first. The command below uses the default TCP port (30333) and specifies
71
+
`/tmp/alice` as the chain database location. Alice's node ID will be
`QmRpheLN4JWdAnY7HGJfWFNbfkQCb6tFf4vvA6hgjMZKrR`); this is determined by the `node-key`.
52
74
53
75
```bash
54
76
cargo run -- \
@@ -60,17 +82,42 @@ cargo run -- \
60
82
--validator
61
83
```
62
84
63
-
In the second terminal, we'll start Bob's substrate node on a different TCP port of 30334, and with his chain database stored locally at `/tmp/bob`. We'll specify a value for the `--bootnodes` option that will connect his node to Alice's bootnode ID on TCP port 30333:
85
+
In another terminal, use the following command to start Bob's node on a different TCP port (30334)
86
+
and with a chain database location of `/tmp/bob`. The `--bootnodes` option will connect his node to
0 commit comments