Node Setup
How to set up a Tellor Layer Node.
Last updated
How to set up a Tellor Layer Node.
Last updated
Running a node for development or as a personal RPC can be done using most modern computers with at least 16gb ram.
If operating a validator / reporter we recommend:
Modern cpu with at least 8 cores / threads
ram: 32 gb
storage: 500gb+ @ NVME gen3+
network: 500mb/s DL, 100mb/s UL (the faster the better)
jq, yq, sed, curl, and wget are required for running the various commands and config scripts and commands in this guide:
jq : sudo apt install jq
yq : sudo apt install yq
sed : sudo apt install sed
curl
: sudo apt install curl
wget
: sudo apt install wget
If you would like to build the binaries from source, you will need Golang ≥ 1.22. Use the default install instructions .
Commands shown should be used while logged in as a user (not root). If you are using an older Mac with an intel chip, use the linux version of the binary(s) in step 1 below.
There are Two different ways to get a node running on layertest-4. You can sync from a snapshot, or from genesis. Syncing from peer snapshot works best for most people. You should sync from genesis if you want to have the full chain history for analysis.
Snapshot sync: Your node is configured with seeds and peers from which it will try to download recent chain state snapshots. This sync method is faster, but you will not be able to query block info (like transactions) for any blocks that were produced before the day of your sync.
Genesis sync: Your node will start with the genesis binary and sync the entire chain. A different binary will be needed for each upgrade since genesis. This sync method can take a long time depending on how long layertest-4 has been live.
layerd
Binary(s)Initialize .layer folder in your home directory:
These steps are the same if you are doing a snapshot sync or a genesis sync. Select the tab for your computer's architecture:
Give the script permission to execute, then run the script:
Create a tellor address (account) for starting the node with various options. This should be done even if you're not going to run a validator.
It's best practice to always handle mnemonics/keys with extreme care, even if it’s just for the testnet, and never use an address that holds real funds for testing.
If you do not yet have an account / mnemonic phrase, generate a new key pair with the command below. Choose an account name that's easy to remember. Save the output in a safe place if you'd like to be able to import the account later:
If you already have an account, you can Import it with the command:
Export your "tellorvaloper" prefix address. Copy it and keep it handy for the next step:
A Layer node uses the following variables:
TOKEN_BRIDGE_CONTRACT: the token bridge contract address.
ETH_RPC_URL: A reliable sepolia RPC url for calling the bridge contract.
WITHDRAW_FREQUENCY: For reporters, the daemon will automatically claim your tips (rewards) on this interval (in seconds)
REPORTERS_VALIDATOR_ADDRESS: For reporters the "tellorvaloper" address that you want to withdraw rewards to. (can be different from your reporter's address)
Set the environment variables so that they are set in new terminal windows by default. Open your .bashrc or .zshrc file with a text editor like nano:
Add these lines to the bottom of the file. Remember to replace the example ETH_RPC_URL
with your actual Sepolia testnet RPC url, and if you're going to run a reporter, replace the REPORTERS_VALIDATOR_ADDRESS
with your own as well.
Load the new variables:
Exit nano with ctrl^x
then enter y
to save the changes.
Choose the tab depending on whether or not you are doing a genesis sync, or a state sync:
We need to make a few more config edits to make sure your state sync goes smoothly.
Use curl to find a good TRUSTED_HEIGHT
to use for downloading snapshots:
The command should output something like:
673312 AE2500529CCC9CB012D17AEA10567EF4663D1E1B21EB63D8F851D10BB913C42B
Edit config.toml:
Open your config file:
Scroll or search (ctrl^w) the file and edit the state sync variables shown here:
Be sure to replace the trust_height
and trust_hash
with the block number and hash from the curl command above.
Exit nano with ctrl^x
then enter y
to save the changes.
Start your node:
The node should start up quickly and begin downloading snapshots from peers.
To check if the node is fully synced, open a separate terminal window and run:
You should see a JSON formatted list of information about your running node. If you see catching_up":false
that means that you're node is fully synced and ready to use!
First, download the binary from the .
Download the binaries from the .
Download the latest setup script from the :
Before starting your node, it's a good idea to think about how you want to run it so that the process does not get killed accidentally. This is not obvious for beginners. is a great option for beginners. More advanced setups can be achieved using systemd.