Setup Validator
- Prepare for Validator Registration Before registering as a validator, complete the following preparations: Obtain Ethereum Software Wallet or Hardware wallet Get a Ledger, Hardware or Software wallet ready like Metamask/Portis/Bitski/Torus/myetherwallet. This wallet will be used for receiving delegation, bounties, and self delegating. Fund Validator Wallet with ETH Be ready to have some ETH to accept delegations and link your validator supernode. Remember these are transactions with SKALE Manager on Ethereum, and therefore require ETH. Minimum ETH: 1.0 Get SKALE Manager contract ABIs from SKALE: Github Fund SRW Wallet with ETH Be ready to fund ETH in your self-recharging wallet (SRW). See Self-recharging wallet documentation. Decide your commission fee Decide on your commission fee. This cannot be changed once it is set. To set a new commission fee, you’ll have to register a new validator. This new validator would have to link supernodes and accept delegations for it (old validator supernodes and delegations cannot be rolled into a new validator commission fee). Reference Documents
-
Install SKALE Validator CLI
SKALE Validator CLI is the validator client interface for registering a new validator into network or handling additional
delegation services where validators can self delegate or token holders can delegate to a validator. These are the type of
operations that can be done with the Validator CLI:
- Register Validator (Set Commission Rate or Minimum delegation amount)
- Accept pending delegations
- Link all validator supernode addresses to a validator wallet address
- Request or cancel a delegation
Download the SKALE Validator CLI binary:Validator CLI doesn’t have to be installed in the same server as the node-cli. This can be set up on Mac or Linux. This does not need to be included in every supernode. Setting up once per validator organization is sufficient.Apply executable permissions to the binary:Set SKALE Manager contracts info and set the endpoint:Required arguments:--endpoint/-e- RPC endpoint of the supernode in the network where SKALE manager is deployed (http or https). Example is https://my.geth.node.ip/..--contracts-url/-c- URL to SKALE Manager contracts ABI and addresses-w/--wallet- Type of the wallet that will be used for signing transactions (software or ledger)
-
Setup Wallet
For software wallet, save private key into a file (replace
[YOUR PRIVATE KEY]with your wallet private key):For Ledger wallet, install ETH ledger application and initialize device withsetup-ledgercommand:Required arguments:--address-index- Index of the address to use (starting from0)--keys-type- Type of the Ledger keys (live or legacy)
Make sure you enabled blind signing on ETH application settings. Otherwise transactions won’t work -
Register as a new SKALE validator
Required arguments:
--name/-n- Validator name--description/-d- Validator description (preferably organization info)--commission-rate/-c- Commission rate (percent %)--min-delegation- Validator minimum delegation amount
--pk-file- Path to file with private key (only forsoftwarewallet type)--gas-price- Gas price value in Gwei for transaction (if not specified doubled average network value will be used)--yes- Confirmation flag
-
Ensure validator is added to the trusted list
To ensure that your validator is added to trusted contact SKALE team.
This is a temporary process, which will be removed as the community matures.
Setup SGX
-
Understand SGX Overview
SGX is a secure storage for BLS private key shares, which are used in consensus to sign new blocks. SGX is also used for private key shares. SKALE DKG uses Intel® SGX server to store account and BLS keys and all the data related to DKG process and it also uses the random number generator provided by Intel® SGX. For more information, please check here. Clients connect to the server, authenticate to it using TLS 1.0 protocol with client certificates, and then issue requests to the server to generate crypto keys and perform cryptographic operations. The keys are generated inside the secure SGX enclave and never leave the enclave unencrypted.Due date: 23rd of each month
-
Prepare SGX Server
To be able to set up an SGXWallet, validators are required to have SGX compatible servers. Before installing SGXWallet, validators must make sure that SGX is enabled in the server.
Server Requirements:
- Ubuntu 22.04 LTS (Jammy Jellyfish)
- SGX-enabled Intel processor
- Minimum 8 GB
- Swap size equals to half (1/2) of RAM size
-
Configure Network for SGX
It’s required to setup VPN between supernodes and SGX server. Ports 1026-1031 should open only to SKALE supernodes, not public ports should be accessible by supernode.
SGXWallet can support up to 5 SKALE supernodes. If you have more, you should setup additional server.
-
Install and Configure Packages for SGX
Before running SGXWallet install the following packages
Install general tools:
Install Docker:Install docker.io:Install docker compose:Install cpuid and libelf-dev packages:Verify your processor supports Intel SGX with:Disable automatic updates It’s recommended to only update the SGXWallet server if there are critical security fixes. This is because SGXWallet is based on new low level technology, and kernel updates may break the system. Currently SGX is tested on 5.15* kernels. It’s best to avoid minor version updates too. To make sure
apt updatewon’t update the kernel you should use apt-mark hold command:Also if you configured unattended upgrades, you should make sure kernel won’t update automatically. To do this, add the following lines to/etc/apt/apt.conf.d/50unattended-upgradesfile:Output -
Download SGXWallet source code
Clone SGX Wallet Repository to your SGX compatible Server:
-
Enable SGX
SGX Wallet repository includes the sgx_enable utility. To enable SGX run:
Install SGX Library:System Reboot:Check driver installation: To check that isgx device is properly installed run this command:Reboot your machine after driver install!For newer machine device should beIf you don’t see the neither of isgx and sgx_enclave device, you need to troubleshoot your driver installation from here. Another way to verify Intel SGX is enabled in BIOS:Enter BIOS by pressing the BIOS key during boot. The BIOS key varies by manufacturer and could be F10, F2, F12, F1, DEL, or ESC. Usually Intel SGX is disabled by default. To enable: find the Intel SGX feature in BIOS Menu (it’s usually under the “Advanced” or “Security” menu) Set SGX in BIOS as enabled (preferably) or software-controlled. save your BIOS settings and exit BIOS. Enable “software-controlled” SGX Software-controlled means that SGX needs to be enabled by running a utility.If you already executed the previous steps please move to STEP 3
-
Update docker-compose.yaml
Open run_sgx directory
On some machines, the SGX device isn’t /dev/mei0 but a different device, such as /dev/bs0 or /dev/sg0. In this case please edit docker-compose.yml on your machine to specify the correct device to use:make sure
imageis skalenetwork/sgxwallet:<1.9.1-stable.1> in docker-compose and it will look like: -
Spin up SGXWallet Container
Start SGX Wallet Containers
To run the server as a daemon:
-
Securely save generated backup key
The backup key is automatically stored in sgx_data directory.
The filename of the key is sgx_wallet_backup_key.txt, and is generated the first time the SGX wallet is started.
You should enable SSL/TLS for your SGX supernode. Make sure you finalize this before you move on to your next step.
- Backup sgx data It’s strongly recommended to backup sgx data regularly. The guide can be found here.
Supernode Setup
-
Prepare Supernode Server
After Setting up SGX Wallet and create certifications, validators can download the SKALE Node CLI executables register and maintain your SKALE supernode. This process downloads docker container images from docker hub and spins up SKALE supernode functionalities. Some base containers such as SKALE Admin, Bounty, TransactionManager will be created during installation for each supernode. This document contains instructions on how to setup supernode using SKALE Node CLI. Supernode server should follow compliance requirements which will be checked during installing SKALE supernode software. Please make sure: General requirementsDue date: 23rd of each month
- A Linux x86_64 machine
- Ubuntu 22.04 LTS (Jammy Jellyfish)
- Separate not mounted block device - 2 Tb
- 8 physical cores
- 32GB RAM
- 16GB Swap
-
Install Packages for Supernode
Before setting up supernode you should make sure that the following software is installed:
- docker
- docker-compose
- nftables
- lvm2
After docker installation make sure that thelive-restoreoption is enabled in/etc/docker/daemon.json. See more info in the docker docs.You can install iptables-persistent using the following commands:If you have any concerns or questions, please don’t hesitate to reach out to SKALE Team leads on Discord.You should carefully control any automatic updates. In general avoid updates to the Linux kernel, docker, docker-compose, btrfs-progs. And take care when updating lvm2, iptables, iptables-persistent, and python. -
Install Node CLI
Download the Node CLI binary:
Verify the hashsum:Apply executable permissions and test the installation:More information can be found here.You should run node-cli commands using sudo
-
Configure .env
Configuration parameters are passed to Node CLI through .env file. It should contain the following variables:
CONTAINERS_CONFIG_STREAM- git branch with containers versions configDISK_MOUNTPOINT- Attached storage block deviceDOCKER_LVMPY_STREAM- git branch of docker lvmpy volume driver for SKALE ChainsENDPOINT- RPC endpoint of the supernode in the network where SKALE manager is deployed (httporhttps)FILEBEAT_HOST- URL to the Filebeat log serverIMA_CONTRACTS_ABI_URL- URL to IMA contracts ABI and addressesIMA_ENDPOINT- IMA endpoint to connect (should be the same asENDPOINT).MANAGER_CONTRACTS_ABI_URL- URL to SKALE Manager contracts ABI and addressesSGX_SERVER_URL- URL to SGX server in the network (i.e. http(s)://host:port, do not add a trailing ”/” after the port number )ENV_TYPE- network type (mainnet/testnet)
ENDPOINT,IMA_ENDPOINT,SGX_SERVER_URL,DISK_MOUNTPOINTare server dependent. Other options depend on the network type. For the{ENV_TYPE}network .env will look like:It’s possible to configure Telegram based alert system by providing the following options:TG_API_KEY- Telegram API keyTG_CHAT_ID- Telegram chat ID
-
Enable SGX wallet autosign
Switch back to sgx server and go to
sgxwallet/run_sgxfolderSet-soption in docker-compose.ymlRestart the container -
Initialize Supernode
To install supernode on your server you should run
skale node init. It will create necessary configuration files and run base services and containers.Example Output:You can verify installation procedure by running:Output:The common problem is network misconfiguration between the supernode and SGXWallet. You can recheck connection status usingskale health sgx:Output: -
Disable SGX wallet autosign
Switch back to sgx server and go to
sgxwallet/run_sgxfolderRemove-soption in docker-compose.ymlRestart the container -
Setup SSL Certificates
You will need to setup redirects from each supernode IP to the supernode domain, and issue SSL certs from a Trusted CA.
You can issue a separate certificate for each subdomain (node-0.awesome-validator.com, node-1.awesome-validator.com) or
issue a single Wildcard SSL for all supernodes (*.awesome-validator.com). As a result, you should have 2 main files saved and
copied to the respective supernodes:
- Certificate file (for example, fullchain.pem or cert.pem)
- Private key file (for example, privkey.pem, pk.pem)
Check SSL status:For more details, please see Node SSL docs. -
Fund Node wallet with ETH
Some of the supernode operations send ETH mainnet transaction (e.g. chain creation). So the supernode wallet should have at least 1 ETH
To get the address you should run
skale wallet infocommand.Spent ETH is reimbursed after the transaction was completed. -
Sign Validator ID using SGXWallet
Using validator-cli check your validator ID:
Get your SKALE supernode signature by running Node CLI command.Output:
-
Link SKALE wallet address to your validator account using Validator CLI
To successfully register new supernode you should bind supernode address and validator entity using validator-cli
link-address:Optional arguments:You can find supernode address by executingskale wallet infocommand--pk-file- Path to file with private key (only forsoftwarewallet type)--gas-price- Gas price value in Gwei for transaction (if not specified doubled average network value will be used)--yes- Confirmation flag
-
Backup Node
We strongly recommend to regularly backup supernode data. The critical information stored
~/.skaledirectory. Theskale node backupcommand archives the data which you can download and store somewhere else. To restore the supernode you should useskale node restoreMore information can be found here. -
Accept Delegations
Every delegation need to be accepted. You can do it using
sk-val validator accept-delegationcommand:Required arguments:--delegation-id- Delegation id to accept
--pk-file- Path to file with private key (only for software wallet type)--gas-price- Gas price value in Gwei for transaction (if not specified doubled average network value will be used)--yes- Confirmation flag
sk-val validator delegations:You will see your pending delegation (PENDINGstatus) as well as already accepted ones (DELEGATEDstatus).To register the supernode validator must meet the Minimum Staking Requirement (MSR) of 20,000,000 SKL.
Register Node in SKALE Network
-
Register Node with Node CLI
To register with the network, you will need to provide the following:Before proceeding, you will need to have at least 1 ETH. Also amount of delegated skale tokens need to be more or equal to minimum staking amount.
- Node name
- Machine public IP
- Domain name
Optional arguments:--port- beginning of the port range that will be used for skale SKALE Chains (10000by default)
-
Check Node Status
You can check the status of your supernode, and ensure that it’s properly registered with the SKALE Network.
Output:
Post Registration Checks
-
Post Registration Checks
- Private and backup keys are secured in a safe place.
- VPN is configured on all SGXWallet servers.
- Ensure node wallets have sufficient ETH.
- Accept delegations for the next month.
- Check telegram notifications (if you enabled them).
- Use watchdog to monitor node status.
- Get support from the SKALE validator community.
