11.5 Switch Clients
Client diversity refers to the use of multiple independent software implementations across a network, written by different teams and with different coding languages. Through the diverse setup, the network security is improved, and the risk of single points of failure get reduced as errors in a single client do not affect the overall network's security.
Further details can be found on the Client Diversity page of the 🧠Theory section
The majority of nodes on the LUKSO network is running Geth and Prysm setups. Node operators are responsible to ensure they split their client usage evenly across officially supported clients to improve resilence of the blockchain. If you are in a position to do so, you should adapt your client setup to ensure greater diversity.
The following steps are performed on your 📟 node server.
1. Stop Node Operation​
Depending on your setup method, there are different ways to stop your node before applying updates.
- LUKSO CLI
- Service Automation
cd <lukso-working-directory>
lukso stop
Exchange <lukso-working-directory>
with the path of the node folder.
sudo systemctl stop lukso-validator
Force Client Shutdown
- Geth
- Erigon
- Nethermind
- Besu
- Teku
- Nimbus-Eth2
- Lighthouse
- Prysm
sudo pkill geth
sudo pkill erigon
sudo pkill nethermind
sudo pkill besu
sudo pkill teku
sudo pkill nimbus_beacon_node
sudo pkill nimbus_validator_client
sudo pkill lighthouse
The Lighthouse client uses a single binary for both the consensus and validator processes.
sudo pkill prysm
sudo pkill validator
2. Switch Client Software​
Depending on whether you're switching only the execution client or both execution and consensus clients, the process and complexity will vary. While execution clients can be swapped directly within the existing node folder, changing the consensus client requires a full validator reconfiguration and monitoring updates.
Type | Description |
---|---|
Replaces client binary and reinitalizes the node folder while keeping the validator setup. | |
Requires new folder setup, new validator wallet, and firewall reconfiguration. |
If you switch the consensus client, you must re-import your keystore-xxx.json key files generated within the Validator Setup. Additionally, you also have to update the Prometheus Ports, Prometheus Service, and Grafana Dashboard, as the monitoring software will not be able to read from the old consensus ports.
- Execution Client Only
- Consensus and Execution Clients
2.1 Navigate into the Node Folder: Move into the node's working directory to initialize your node clients.
cd ./<lukso-working-directory>
2.2 Remove Old State: Delete client-specific blockchain state and logs, and re-initialize the folder.
# Remove Blockchain Data
rm -rf <network>-data
# Remove Logs
rm -rf <network>-logs
# Initialize the Folder
sudo lukso init
The lukso init
command only adds missing files within the /configs/
folder without overwriting existing ones.
2.3 Install Client: Select and install a minority execution client alongside your old consensus client.
lukso install
Check if both clients were installed correctly using their version commands:
- Geth
- Erigon
- Nethermind
- Besu
- Nimbus-Eth2
- Lighthouse
- Teku
- Prysm
geth --version
erigon --version
nethermind --version
besu --version
nimbus_beacon_node --version
# Consensus Client
lighthouse --version
# Validator Client
lighthouse vc --version
# Consensus Client
teku --version
# Validator Client
teku validator-client --version
# Consensus Client
prysm --version
# Validator Client
prysm validator --version
If you encounter errors during the download or checkups, re-do the installation process.
2.1 Apply New Firewall Rules: Apply the new consensus client's firewall rules to your system.
2.2 Arrange New Router Ports: Apply the new consensus client's port rules to your router.
2.3 Fresh Node Setup: Redo the LUKSO CLI Installation within a new node folder.
2.4 Add Validator Configuration: Redo the Validator Configuration to setup the new validator wallet.
2.5 Arrange New Prometheus Ports: Reconfigure the Prometheus Ports to allow reading consensus data.
2.6 Update the Prometheus Service: Update the Prometheus Service File to dock onto the new consensus port
2.7 Update the Grafana Dashboard: Import the correct Grafana Dashboard for your new consensus client.
3. Apply Client Modifications​
In case you did any modifications to your previous client configuration files, please re-apply them to your new client configuration files within the config folder of your node directory before starting up your updated validator node. Modifications may include:
- Attaching the Node Explorer
- Configuring a Dynamic DNS
- Adding a Node Name or Graffiti
- Attaching the Public IP
- Adjusting Peer Count Limits
- Enabling RPC Modules
- ...
4. Restart the Validator​
After installing and configuring the new client setup, you can start up the node again.
- Regular Synchronization
- Automated Checkpoints
- Manual Checkpoints
# Starting the Mainnet Node as Validator
lukso start --validator --transaction-fee-recipient "<transaction-fee-recipient-address>"
# Starting the Testnet Node as Validator
lukso start --validator --transaction-fee-recipient "<transaction-fee-recipient-address>" --testnet
Replace <transaction-fee-recipient-address>
with your actual withdrawal address.
# Starting the Mainnet Node as Validator
lukso start --validator --transaction-fee-recipient "<transaction-fee-recipient-address>" --checkpoint-sync
# Starting the Testnet Node as Validator
lukso start --validator --testnet --transaction-fee-recipient "<transaction-fee-recipient-address>" --checkpoint-sync
Replace <transaction-fee-recipient-address>
with your actual withdrawal address.
- Visit the Mainnet Checkpoint Explorer or Testnet Checkpoint Explorer
- Pass the latest Block Root and Epoch values to the consensus client flags
- Lighthouse
- Teku
- Prysm
- Nimbus-Eth2
# Starting the Mainnet Node as Validator
lukso start --validator \
--transaction-fee-recipient "<transaction-fee-recipient-address>" \
--lighthouse-checkpoint-sync-url=https://checkpoints.mainnet.lukso.network \
--lighthouse-genesis-state-url=https://checkpoints.mainnet.lukso.network \
--lighthouse-wss-checkpoint=$<BLOCK_ROOT>:$<EPOCH>
# Starting the Testnet Node as Validator
lukso start --validator --testnet \
--transaction-fee-recipient "<transaction-fee-recipient-address>" \
--lighthouse-checkpoint-sync-url=https://checkpoints.testnet.lukso.network \
--lighthouse-genesis-state-url=https://checkpoints.testnet.lukso.network \
--lighthouse-wss-checkpoint=$<BLOCK_ROOT>:$<EPOCH>
# Starting the Mainnet Node as Validator
lukso start --validator \
--transaction-fee-recipient "<transaction-fee-recipient-address>" \
--teku-checkpoint-sync-url=https://checkpoints.mainnet.lukso.network \
--teku-ws-checkpoint=$<BLOCK_ROOT>:$<EPOCH>
# Starting the Testnet Node as Validator
lukso start --validator --testnet \
--transaction-fee-recipient "<transaction-fee-recipient-address>" \
--teku-checkpoint-sync-url=https://checkpoints.testnet.lukso.network \
--teku-ws-checkpoint=$<BLOCK_ROOT>:$<EPOCH>
# Starting the Mainnet Node as Validator
lukso start --validator \
--transaction-fee-recipient "<transaction-fee-recipient-address>" \
--prysm-checkpoint-sync-url=https://checkpoints.mainnet.lukso.network \
--prysm-genesis-beacon-api-url=https://checkpoints.mainnet.lukso.network \
--prysm-weak-subjectivity-checkpoint=$<BLOCK_ROOT>:$<EPOCH>
# Starting the Testnet Node as Validator
lukso start --validator --testnet \
--transaction-fee-recipient "<transaction-fee-recipient-address>" \
--prysm-checkpoint-sync-url=https://checkpoints.testnet.lukso.network \
--prysm-genesis-beacon-api-url=https://checkpoints.testnet.lukso.network \
--prysm-weak-subjectivity-checkpoint=$<BLOCK_ROOT>:$<EPOCH>
# Starting the Mainnet Node as Validator
lukso start --validator \
--transaction-fee-recipient "<transaction-fee-recipient-address>" \
--nimbus2-external-beacon-api-url=https://checkpoints.mainnet.lukso.network \
--nimbus2-trusted-block-root=$<BLOCK_ROOT> \
--nimbus2-weak-subjectivity-checkpoint=$<BLOCK_ROOT>:$<EPOCH>
# Starting the Testnet Node as Validator
lukso start --validator --testnet \
--transaction-fee-recipient "<transaction-fee-recipient-address>" \
--nimbus2-external-beacon-api-url=https://checkpoints.testnet.lukso.network
--nimbus2-trusted-block-root=$<BLOCK_ROOT> \
--nimbus2-weak-subjectivity-checkpoint=$<BLOCK_ROOT>:$<EPOCH>
Replace the following parameters of the commands:
<BLOCK_ROOT>
and<EPOCH>
with the current hash and number while keeping the$
sign.<transaction-fee-recipient-address>
with your actual withdrawal address.
After the clients were started, verify that their services are still up.
sudo lukso status
5. Data Cleanup​
After switching clients, unused files and binaries can be removed from the old setup to avoid conflicts and free up storage.
- Execution Client Only
- Consensus and Execution Clients
Delete Old Client: Remove the unused execution client service from the system.
- Geth
- Erigon
- Nethermind
- Besu
sudo rm -rf /usr/local/geth
sudo rm -rf /usr/local/erigon
sudo rm -rf /usr/local/nethermind
sudo rm -rf /usr/local/besu
5.1 Remove Old Firewall Settings: Remove the old consensus client's firewall rules from your system.
5.2 Remove Old Router Ports: Remove the old consensus client's port rules from your router.
5.3 Delete Old Node Folder: Remove the working directory of the previous node setup.
cd ~
sudo rm -rf <old-lukso-working-directory>
Exchange <old-lukso-working-directory>
with the path of the previous node folder.
5.4 Delete Old Clients: Remove unused client services from the system.
- Geth
- Erigon
- Nethermind
- Besu
- Teku
- Nimbus-Eth2
- Lighthouse
- Prysm
sudo rm -rf /usr/local/geth
sudo rm -rf /usr/local/erigon
sudo rm -rf /usr/local/nethermind
sudo rm -rf /usr/local/besu
sudo rm -rf /usr/local/teku
sudo rm -rf /usr/local/nimbus_beacon_node
sudo rm -rf /usr/local/nimbus_validator_client
sudo rm -rf /usr/local/lighthouse
sudo rm -rf /usr/local/prysm