Mainnet collator guide
Astar ecosystem has two main networks. We have permissionless onboarding for collators if you meet our requirements. We also have a program to become a whitelisted collator! We are finalizing this in Q1 2022.

Astar ecosystem:

  • Shiden Network: Kusama parachain
  • Astar Network: Polkadot parachain

Overview

Before building your collator, make sure you understand the role of collators and you have experience with running a node. If you don't have the experience you can learn by launching a node in our testnet Shibuya.

Building collator from source

Make sure your server is ready to build a collator:
1
## Install Rust
2
##
3
curl https://sh.rustup.rs -sSf | sh
4
source $HOME/.cargo/env
5
rustup update nightly
6
rustup target add wasm32-unknown-unknown --toolchain nightly
7
​
8
## Compile needed software
9
##
10
bash -c "$(wget -O - https://apt.llvm.org/llvm.sh)"
11
sudo apt install cmake
12
sudo apt install git
13
sudo apt install build-essential
14
sudo apt update
15
sudo apt install clang
Copied!
Download everything from our Github:
1
git clone https://github.com/AstarNetwork/Astar.git
2
cd Astar
Copied!
Make sure you have the latest commits in place:
1
git checkout
2
git pull
Copied!
Build your node from source:
1
cargo build --release
Copied!
Start Collator using screen or nohup:
Astar
Shiden
1
cd /target/release/
2
./astar-collator --validator --name NODENAME --chain astar --parachain-id 2006 --rpc-cors all --telemetry-url 'wss://telemetry.polkadot.io/submit/ 0' --execution wasm --state-cache-size 1
Copied!
1
cd /target/release/
2
./astar-collator --validator --name NODENAME --rpc-cors all --telemetry-url 'wss://telemetry.polkadot.io/submit/ 0' --execution wasm --state-cache-size 1
Copied!
Get your session key:
1
curl -H "Content-Type: application/json" -d '{"id":1, "jsonrpc":"2.0", "method": "author_rotateKeys", "params":[]}' http://localhost:9933
Copied!
Make sure you set your session key before registering to become a collator!

Build with Docker or use Binaries

Docker

You can download the docker here.

Binaries

You can download the latest binary from here.

Relay Chain snapshot

If you run your collator it not only needs to sync the mainnet chain but also the complete relay chain from Kusama/Polkadot. This can take up to 3-4 days. You can also use a snapshot of Kusama/Polkadot. You can download this here and will save a lot of time.
NOTE: know what you are doing!
Last modified 16d ago