Skip to content

cerberus-node/succinct

Repository files navigation

Build Succinct Prover ( Build from source )

You have two installation options:


I. Automatic Installation (Recommended for Beginners)

If you want everything set up automatically, run the following command:

curl -sL https://raw.githubusercontent.com/cerberus-node/succinct/refs/heads/main/auto-install.sh -o auto-install.sh && chmod +x auto-install.sh && bash auto-install.sh

✅ This script installs Docker, Rust, Foundry, SP1 CLI, and builds the prover. Below is the image when you successfully run Auto-Script, at this step you just need to wait for it to calculate and when it finishes calculating, just run directly to step 9 and start with "Set Environment Variables".

image


II. Manual Installation (Step-by-Step)

Step 1: System Requirements Check

If your system already has Docker and a compatible CUDA version (>=12.5), skip to Step 2.

Check Existing Setup

# Check Docker
docker --version

# Check NVIDIA GPU and CUDA
nvidia-smi

# Expected Output
# NVIDIA-SMI 575.51.03
# Driver Version: 575.51.03
# CUDA Version: 12.9

# ✅ CUDA Version must be >= 12.5
# ⚠️ Driver version is flexible but 555.xx.xx+ is recommended

If Not Installed Yet – Install Docker

sudo apt-get update
sudo apt-get install ca-certificates curl
sudo install -m 0755 -d /etc/apt/keyrings
sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc
sudo chmod a+r /etc/apt/keyrings/docker.asc

echo \
  "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/ubuntu \
  $(. /etc/os-release && echo "${UBUNTU_CODENAME:-$VERSION_CODENAME}") stable" | \
  sudo tee /etc/apt/sources.list.d/docker.list > /dev/null

sudo apt-get update
sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin

Install NVIDIA Driver & CUDA

# 1. (Optional) Add the NVIDIA drivers PPA and update apt
sudo add-apt-repository ppa:graphics-drivers/ppa
sudo apt-get update

# 2. Install prerequisites for DKMS module builds
sudo apt-get install -y build-essential dkms linux-headers-$(uname -r)

# 3. Remove any old NVIDIA/CUDA 550-series packages
sudo apt-get remove --purge 'nvidia-*550*'
sudo apt-get autoremove --purge

# 4. Clean up and fix any broken dependencies
sudo apt-get clean
sudo apt-get update
sudo apt-get install -f

# 5. Install the NVIDIA 570-server driver (CUDA 12.5+ support)
sudo apt-get install -y nvidia-driver-570-server

# 6. Reboot so the new driver modules are loaded
sudo reboot

After reboot:

nvidia-smi

Step 2: Install Rust

curl https://sh.rustup.rs -sSf | sh
source $HOME/.cargo/env
rustup update

Step 3: Install Foundry

curl -L https://foundry.paradigm.xyz | bash
foundryup
foundryup -i nightly

Step 4: Install SP1 CLI

cargo install --git https://github.com/succinctlabs/sp1 --locked sp1
sp1 --help

Step 5: Clone the Network Repo

git clone https://github.com/succinctlabs/network.git
cd network

Step 6: Build spn-node

cd bin/node
RUSTFLAGS="-C target-cpu=native" cargo build --release

Step 7: Verify the Build

cd ../../
./target/release/spn-node --version

Step 8: Build Docker Image (GPU Required)

docker build --target gpu -t spn-node:latest-gpu .

Test Docker Image

docker run spn-node:latest-gpu --version

Step 9: Run the Prover

Calibrate Your GPU

SP1_PROVER=cuda ./target/release/spn-node calibrate \
    --usd-cost-per-hour 0.80 \
    --utilization-rate 0.5 \
    --profit-margin 0.1 \
    --prove-price 1.00

Example Output:

Calibration Results:
┌──────────────────────┬────────────────────────────┐
│ Metric               │ Value                      │
├──────────────────────┼────────────────────────────┤
│ Estimated Throughput │ 391817 PGUs/second         │
├──────────────────────┼────────────────────────────┤
│ Estimated Bid Price  │ 1.25 $PROVE per 1B PGUs    │
└──────────────────────┴────────────────────────────┘

✅ Set environment variables based on output:

export PGUS_PER_SECOND=391817
export PROVE_PER_BPGU=1.25
export PROVER_ADDRESS=<YOUR_WL_ADDRESS>   # The wallet after you stake, your Prover wallet 
export PRIVATE_KEY=<PRIVATE_KEY>      # The wallet that received 1000 $PROVE

image

Run the Prover (in tmux recommended)

🧠 Run inside tmux to keep it running after disconnection:

tmux new -s prover
# Run prover below inside tmux

To detach: Ctrl + B, then D To resume: tmux attach -t prover

SP1_PROVER=cuda ./target/release/spn-node prove \
    --rpc-url https://rpc.sepolia.succinct.xyz \
    --throughput $PGUS_PER_SECOND \
    --bid $PROVE_PER_BPGU \
    --private-key $PRIVATE_KEY \
    --prover $PROVER_ADDRESS

If you see a log like this in Tmux, it means you have successfully installed it. Congratulations, now you just need to "Prove ur Prover"

image


🔎 Notes

  • Only cargo build is run inside bin/node
  • All other commands are from root of network
  • SP1 CLI is used only for proving
  • Foundry must be installed before build

📚 References


About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages