Skip to content

Latest commit

 

History

History
220 lines (183 loc) · 5.3 KB

node-guide.md

File metadata and controls

220 lines (183 loc) · 5.3 KB

STORYGUIDE

Step-by-step guide to setting up and running a node on the Story blockchain

Table of Contents

LINEA

System Specs

Hardware Requirement
CPU 4 Cores
RAM 8 GB
Disk 200 GB
Bandwidth 10 MBit/s

Ubuntu min version
22.04

story-geth version
version: 0.9.2-stable

story version
v0.9.11-stable

Default folder

By default, we set up the following default data folders for the consensus and execution clients:
o Story root data:~/.story/story
o story-geth data root: ~/.story/geth

CHAIN_ID="iliad"

Install dependencies

sudo apt update
sudo apt-get update
sudo apt install curl git make jq build-essential gcc unzip wget lz4 aria2 -y

Install Go 23

cd $HOME
VERSION=1.23.0

# Remove any previous Go installation
sudo rm -rf /usr/local/go

# Download and install the specified version of Go
wget -O go.tar.gz https://go.dev/dl/go$VERSION.linux-amd64.tar.gz
sudo tar -C /usr/local -xzf go.tar.gz
rm go.tar.gz

# Update environment variables to use the new Go installation
echo 'export GOROOT=/usr/local/go' >> $HOME/.bash_profile
echo 'export GOPATH=$HOME/go' >> $HOME/.bash_profile
echo 'export GO111MODULE=on' >> $HOME/.bash_profile
echo 'export PATH=$GOROOT/bin:$GOPATH/bin:$PATH' >> $HOME/.bash_profile

# Reload the bash profile to apply the changes
source $HOME/.bash_profile

# Verify the installation
go version

Install piplabs

# install Story
cd $HOME
rm -rf story
git clone https://github.com/piplabs/story
cd story
git checkout v0.11.0
go build -o story ./client 
mv $HOME/story/story $HOME/go/bin/

Download Story-Geth binary

cd $HOME
wget -O geth https://github.com/piplabs/story-geth/releases/download/v0.9.4/geth-linux-amd64
chmod +x $HOME/geth
mv $HOME/geth ~/go/bin/
[ ! -d "$HOME/.story/story" ] && mkdir -p "$HOME/.story/story"
[ ! -d "$HOME/.story/geth" ] && mkdir -p "$HOME/.story/geth"
story-geth version

Download Story binary

wget -O story-linux-amd64-0.9.11-2a25df1.tar.gz https://story-geth-binaries.s3.us-west-1.amazonaws.com/story-public/story-linux-amd64-0.9.11-2a25df1.tar.gz
tar xvf story-linux-amd64-0.9.11-2a25df1.tar.gz
sudo chmod +x story-linux-amd64-0.9.11-2a25df1/story
sudo mv story-linux-amd64-0.9.11-2a25df1/story /usr/local/bin/
story version

Init Iliad node

story init --network iliad --moniker <your_moniker>

image

Create story-geth service file

sudo tee /etc/systemd/system/story-geth.service > /dev/null <<EOF  
[Unit]
Description=Story execution daemon
After=network-online.target

[Service]
User=$USER
#WorkingDirectory=$HOME/.story/geth
ExecStart=/usr/local/bin/story-geth --iliad --syncmode full
Restart=always
RestartSec=3
LimitNOFILE=infinity
LimitNPROC=infinity

[Install]
WantedBy=multi-user.target
EOF

Create story service file

sudo tee /etc/systemd/system/story.service > /dev/null <<EOF  
[Unit]
Description=Story consensus daemon
After=network-online.target

[Service]
User=$USER
WorkingDirectory=$HOME/.story/story
ExecStart=/usr/local/bin/story run
Restart=always
RestartSec=3
LimitNOFILE=infinity
LimitNPROC=infinity

[Install]
WantedBy=multi-user.target
EOF

sudo tee <<EOF >/dev/null /etc/systemd/journald.conf
Storage=persistent
EOF

Reload and start story-geth

sudo systemctl daemon-reload && \
sudo systemctl start story-geth && \
sudo systemctl enable story-geth && \
sudo systemctl status story-geth

Reload and start story

sudo systemctl daemon-reload && \
sudo systemctl start story && \
sudo systemctl enable story && \
sudo systemctl status story

Check logs

story-geth

sudo journalctl -u story-geth -f -o cat

story

sudo journalctl -u story -f -o cat

Check sync status

curl localhost:26657/status | jq

image

Create Validator

Export validator Public Key & Private key

story validator export

Export the derived EVM private key

story validator export --export-evm-key

Faucet link: https://faucet.story.foundation/

Check key wallet

story validator export | grep "EVM Public Key:" | awk '{print $NF}'

Create Validator

story validator create --stake 1000000000000000000 --private-key <private-key>