⚒️Installation

  1. Update packages and install useful tools.

sudo apt update && sudo apt upgrade --yes && \
sudo apt install git build-essential ufw curl jq snapd screen ncdu nano fuse ufw --yes
  1. Install go using snap.

sudo snap install go --classic && \
echo 'export GOPATH="$HOME/go"' >> ~/.profile && \
echo 'export GOBIN="$GOPATH/bin"' >> ~/.profile && \
echo 'export PATH="$GOBIN:$PATH"' >> ~/.profile && \
source ~/.profile && \
go version
  1. Build the binary from source.

git clone https://github.com/AssetMantle/node.git
cd node
git checkout tags/v0.3.0
make install
mantleNode version
  1. Initialize your node.

mantleNode init <node_name> --chain-id mantle-1
  1. Download genesis.

curl https://raw.githubusercontent.com/AssetMantle/genesisTransactions/main/mantle-1/final_genesis.json > $HOME/.mantleNode/config/genesis.json
  1. Add seeds and persistent peers to config.toml.

SEEDS="[email protected]:26656"
PEERS="[email protected]:26656,[email protected]:26656,[email protected]:26876,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:26656,f073d57107004268a7c0f1e24433401f892eff94@sentry-1.asset-mantle.ezstaking.io:26229,68692140af51d0c41163340f6f1222eec914c18f@sentry-2.asset-mantle.ezstaking.io:26746,[email protected]:2050,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:46656,[email protected]:26456,[email protected]:26656,[email protected]:26656,[email protected]:26616,[email protected]:26956,[email protected]:24656,[email protected]:26656,[email protected]:26656,[email protected]:26656,[email protected]:29656,[email protected]:26656"
sed -i -e "s/^seeds *=.*/seeds = \"$SEEDS\"/; s/^persistent_peers *=.*/persistent_peers = \"$PEERS\"/" $HOME/.mantleNode/config/config.toml
  1. Set up minimum gas price.

sed -i 's|^minimum-gas-prices *=.*|minimum-gas-prices = "0umntl"|g' $HOME/.mantleNode/config/app.toml
  1. Set up pruning (optional).

pruning="custom"
pruning_keep_recent="100"
pruning_keep_every="0"
pruning_interval="10"
sed -i -e "s/^pruning *=.*/pruning = \"$pruning\"/" $HOME/.mantleNode/config/app.toml
sed -i -e "s/^pruning-keep-recent *=.*/pruning-keep-recent = \"$pruning_keep_recent\"/" $HOME/.mantleNode/config/app.toml
sed -i -e "s/^pruning-keep-every *=.*/pruning-keep-every = \"$pruning_keep_every\"/" $HOME/.mantleNode/config/app.toml
sed -i -e "s/^pruning-interval *=.*/pruning-interval = \"$pruning_interval\"/" $HOME/.mantleNode/config/app.toml
  1. Create service file.

sudo tee /etc/systemd/system/mantle.service > /dev/null <<EOF
[Unit]
Description=AssetMantle Daemon
After=network-online.target

[Service]
User=$USER
ExecStart=$(which mantleNode) start --x-crisis-skip-assert-invariants
Restart=on-failure
RestartSec=3
LimitNOFILE=65535

[Install]
WantedBy=multi-user.target
EOF
  1. Enable and start service.

systemctl daemon-reload
systemctl enable mantle
systemctl restart mantle
journalctl -u mantle -f -o cat

If you would like to speed up the sync process, you may try using State Sync.

Last updated