Find answers instantly with AI search. Start typing your prompt below and let AI do the digging for you!

Joining the SSC Mainnet at Genesis

Fetching the Updated Genesis

  1. Clone the genesis file and add it to your sscd config:

# fetch the genesis
wget -O genesis.json 'https://raw.githubusercontent.com/sagaxyz/mainnet/main/genesis/genesis.json'

# a178e6494d71d469a7e199dc4f222e4788956add1f9d0bba9afc23d75ed27b2c
sha256sum genesis.json

# copy it to your ssc home directory
mv genesis.json ~/.ssc/config
  1. In the file ~/.ssc/config/config.toml enable Prometheus to make possible collect metrics. Find the Instrumentation Configuration Options section in the very end of the file and set prometheus = true using the command below:

    sed -i 's/prometheus = false/prometheus = true/g' ~/.ssc/config/config.toml
  2. In the same ~/.ssc/config/config.toml file, make sure to update the list of persistent peers using the command below:

Once the steps above are executed successfully, you should be able to start the network by running this command:

sscd start

Setting up the Daemon

It is recommended that you set up a daemon for SSC to ensure it continues running even after you exit your current session and that sscd starts on a system reboot.

To create a new service, follow the steps below:

  1. Run this command to generate the systemd config file

    cat <<EOF > sscd.service
    [Unit]
    Description=ssc daemon
    After=network-online.target
    
    [Service]
    Environment="HOME=$HOME/"
    ExecStart=$HOME/go/bin/sscd start --home $HOME/.ssc/
    Restart=always
    RestartSec=3
    LimitNOFILE=4096
    
    [Install]
    WantedBy=multi-user.target
    EOF
  2. Move the file in the right directory

    sudo cp sscd.service /etc/systemd/system/
  3. Enable the sscd service to start on reboot

sudo systemctl enable sscd.service
  1. Start the sscd service

sudo systemctl start sscd.service
  1. Ensure that the sscd service is running

$ sudo systemctl status sscd
● sscd.service - ssc daemon
     Loaded: loaded (/etc/systemd/system/sscd.service; enabled; vendor preset: enabled)
     Active: active (running) since Sun 2023-10-08 21:44:46 UTC; 1 week 2 days ago
   Main PID: 1442 (sscd)
      Tasks: 12 (limit: 19168)
     Memory: 6.0G
        CPU: 1d 5h 33min 26.138s
     CGroup: /system.slice/sscd.service
             └─1442 /home/ubuntu/go/bin/sscd start --home /home/ubuntu/.ssc/

Oct 08 21:44:46 ssc-post-gen-validator systemd[1]: Started sscd daemon.
  1. Monitor logs as needed.

Can't join the network?

  • Check if you are using an internal IP address

  • Check your firewall rules

  • Try adding a list of persistent peers to your config.toml

Last updated