Setting Up a Validator Node
Author: AmpereChain Team Published: Dec 08, 2023 Updated: Jan 02, 2023
Cautions to Consider:
In the event a validator fails to produce a block within a 15-minute timeframe, a penalty of 1% (2000 AMPERE) will be enforced and validator will be removed.
A strict policy limits a single validator per IP address, permitting only one port (30303).
Ensure you possess 200,000 AMPERE tokens to set up the validator node on AmpereChain Network.
Rewards acquired will be locked for a period of 6 months and released on the 1st and 15th of each month.
These steps are vital for configuring a validator to engage in blockchain block validation. Please thoroughly review the entire document before proceeding.
Hardware Specifications:
CPU: Intel i3/AMD Ryzen 5 or higher (Recommended)
RAM: 4 GB DDR5 or above (Recommended)
Disk Space: Minimum of 200 GB NVMe storage, scalable to accommodate blockchain growth
Operating System: Ubuntu 20.04 or above
Network Speed: Recommended 1GBPS+ with a static IP
AmpereChain Validator Portal:
AmpereChain validator portal available at https://apps.amperechain.com/validator
You can use MetaMask wallet to access AmpereChain validator portal.
Validator Portal Elements:
Validator Wallet Address: MetaMask Connected Wallet Address
Server IP Address: Server Static IP Address On Which Validator Hosted
RPC HTTP API Port: 8545 Port to Connect AmpereChain Besu API.
RPC WS API Port: 8546 Port to Connect AmpereChain Besu API.
P2P Port: P2P Port Used By Validator to Connect Other Validators.
Status: Current Validator Status. Refer Validator Status Section to Know in Details.
Validated Blocks: Blocks Validated by Validator
Total Earned Rewards: Total Earned Rewards by Validator
Locked Coins: Locked Coins By Validator for Activation
Enode: Enode URL of Validator
Add Validator (Button): To Add New Validator(Visible if Unlocked Wallet is Not Validator)
Remove Validator (Button): To Remove Validator(Visible if Unlocked Wallet is Validator)
Validator Status:
Configuration Steps:
Follow below steps to configure AmpereChain validator
Execute below command lines in Terminal as root access.
Connect to VPS
Using PuTTY:
Download and Install PuTTY: Get PuTTY from PuTTY Download and install it.
Open PuTTY: Launch PuTTY.
Enter VPS IP: Input the VPS IP address in the "Host Name" field.
Configure Connection: Choose the connection type as SSH and ensure the port is set to 22 (default).
Optional - Save Session: Save this configuration for future use by naming it under "Saved Sessions."
Connect: Click "Open" to establish the connection.
Login: When prompted, enter your username (usually "root") and your password.
Using SSH:
Open Terminal/Command Prompt: Launch the terminal on Linux/Mac or Command Prompt on Windows.
SSH Command: Enter the command
ssh root@your_vps_ip
, replacingyour_vps_ip
with your VPS IP.Login: Input the root user password when prompted.
Access Terminal:
Access Terminal using PuTTY: If you're using PuTTY, once the connection is established, execute the commands within the PuTTY window.
Using SSH: If you're connecting via SSH, you're already within the terminal. Proceed directly with the commands.
Create a New User:
Create a new user with the desired username (replace
your_username
with your chosen username):Enter passowd and remaining just Keep pressing Enter and when you asker for
Is the information correct? [Y/n]
, Press Y and Enter.Grant Sudo Privileges:
Add the new user to the sudo group to grant administrative privileges:
Test if you can log in with the new user in new tab:
Note down the username and password for future interaction with vps.
If you are able to login with new user then
Steps to secure remote root access:
Edit the SSH configuration file:
Press "ctrl w" the the screen pops up and search for PermitRootLogin directly and then hit ENTER
Find the line
PermitRootLogin yes
and change it toPermitRootLogin no
.To Find
PermitRootLogin
'Cntl+w' and thenFind the line
PermitRootLogin yes
and change it toPermitRootLogin no
.Click Ctrl + x keys and y key and then Enter key to save file.
Allow port 22 and enter y if asked for
Proceed with operation (y|n)?
Restart the SSH service:
Update System and Install Java Development Kit (JDK)
Install Additional Tools
Open 8545, 8546 and 30303 port from terminal using below command.
Press y and the ENTER when you asked for 'Proceed with operation (y|n)?'
Download AmpereChain-BesuClient and Prepare AmpereChain Directory and Set Access
Create essential directories
And Press ENTER
Create node private key file for wallet used for validator
Enter private key of wallet you are going to use as validator in nano editor (Add 0x at start if not exist). Also make sure there is no new line or extra spaces. For example: DDfeba0822db7A823F8535874d56862a8526148e then 0xDDfeba0822db7A823F8535874d56862a8526148e Click Ctrl + x keys and y key and then Enter key to save file.
Run the AmpereChain BesuClient and Wait for server to sync up-to the latest block
If you're using a graphical interface like Putty, copy and paste the following command line directly. If not, using tools like 'tmux' will help you maintain active sessions.
Here's how to work with tmux:
Creating a Session: Use this command to start a session:
tmux new -s amperechain
. This sets up a session named "amperechain."Reconnecting to a Session: If you need to reconnect after closing the tab or disconnecting, type
tmux attach -t amperechain
. This command reconnects you to the previous "amperechain" session.Viewing All Sessions: You can see all active sessions by typing
tmux ls
.
Note: If you're working in a tmux session, it's okay to close the tab or window. You can always reconnect using the
tmux attach -t amperechain
command to resume where you left off.Don't forget to replace <ValidatorWalletAddress> from above command line For example in our case command line is: sudo /AmpereChain/bin/besu --data-path=/AmpereChain/DQBFT-Network/Node/data --genesis-file=/AmpereChain/genesis.json --host-allowlist=* --min-gas-price=0 --rpc-http-api=ETH,NET,WEB3,QBFT,TRACE,TXPOOL,ADMIN --rpc-http-cors-origins=* --rpc-http-enabled=true --rpc-http-host=0.0.0.0 --rpc-http-max-active-connections=10000 --rpc-http-max-batch-size=-1 --rpc-http-port=8545 --rpc-tx-feecap=1000000000000000 --rpc-ws-api=ETH,NET,WEB3,QBFT,TRACE,TXPOOL,ADMIN --rpc-ws-enabled=true --rpc-ws-host=0.0.0.0 --rpc-ws-max-active-connections=10000 --rpc-ws-port=8546 --p2p-port=30303 --sync-mode=FULL --bootnodes="enode://c74f62b1764425d5824b40a04fb11e14efcbbe080d6a09e8473bb917cc4af05fe4f11e8570b4df78cb26ad52a2542ad4fe771fc326ac80656bc93e9a95547daa@216.219.86.11:30303" --node-private-key-file=/AmpereChain/DQBFT-Network/Node/key/key --miner-enabled=true --miner-coinbase=0xDDfeba0822db7A823F8535874d28862a8526 Note: Please wait for the server to synchronize with other nodes and generate new blocks. This synchronization process may require several hours to complete. Rushing through this stage before complete synchronization poses a high probability of incurring penalties.
Apply for Validator on portal Caution: Before applying, make sure to open the correct wallet associated with AmpereChain and ensure you're on the AmpereChain network. Applying with the wrong wallet or network may require validator removal and could disrupt access for other users on the portal. If all settings are proper and validator synchronization is completed and started importing latest new blocks then Apply for validator from https://apps.amperechain.com/validator Visit above mentioned validator portal and connect with MetaMask(make sure you use same wallet as validator) Enter Server IP Address and click on Add Validator then sign transaction from MetaMask. It will lock 200000 AMPERE and wait for few mins to get status reflected to "Active-Offline" Portal will show validator status as Activated when node starts generating new blocks.
Important Things:
Leave terminal running and lock VPS
Don't share your private key with anyone
Thank you for becoming a validator. Your commitment secures the network. Stay vigilant, stay secure.
Last updated