Network
Cosmos
Symphony
Installation

Empe

ℹ️

Recommended Hardware: 6 Cores, 32GB RAM, 500GB of storage (NVME)

Install Dependencies

# install dependencies, if needed
sudo apt update && sudo apt upgrade -y
sudo apt install curl git wget htop tmux build-essential jq make lz4 gcc unzip -y
# install go, if needed
cd $HOME
VER="1.21.3"
wget "https://golang.org/dl/go$VER.linux-amd64.tar.gz"
sudo rm -rf /usr/local/go
sudo tar -C /usr/local -xzf "go$VER.linux-amd64.tar.gz"
rm "go$VER.linux-amd64.tar.gz"
[ ! -f ~/.bash_profile ] && touch ~/.bash_profile
echo "export PATH=$PATH:/usr/local/go/bin:~/go/bin" >> ~/.bash_profile
source $HOME/.bash_profile
[ ! -d ~/go/bin ] && mkdir -p ~/go/bin
 
# install cosmovisor
go install cosmossdk.io/tools/cosmovisor/cmd/[email protected]
 
# set vars
echo "export WALLET="wallet"" >> $HOME/.bash_profile
echo "export MONIKER="test"" >> $HOME/.bash_profile
echo "export SYMPHONY_CHAIN_ID="symphony-testnet-3"" >> $HOME/.bash_profile
echo "export SYMPHONY_PORT="18"" >> $HOME/.bash_profile
echo "export SYMPHONY_PATH=".symphonyd"" >> $HOME/.bash_profile
source $HOME/.bash_profile
 
# download binary
cd $HOME
rm -rf symphony
git clone https://github.com/Orchestra-Labs/symphony
cd symphony
git checkout v0.3.0
make build
 
# add binary into cosmovisor path
mkdir -p $HOME/$SYMPHONY_PATH/cosmovisor/genesis/bin
mv build/symphonyd $HOME/$SYMPHONY_PATH/cosmovisor/genesis/bin/
rm -rf build
 
# Create Symlink
sudo ln -s $HOME/$SYMPHONY_PATH/cosmovisor/genesis $HOME/$SYMPHONY_PATH/cosmovisor/current -f
sudo ln -s $HOME/$SYMPHONY_PATH/cosmovisor/current/bin/symphonyd /usr/local/bin/symphonyd -f
 
# config and init app
symphonyd init $MONIKER --chain-id $SYMPHONY_CHAIN_ID
sed -i -e "s|^node *=.*|node = \"tcp://localhost:${SYMPHONY_PORT}657\"|" $HOME/$SYMPHONY_PATH/config/client.toml
 
# download genesis and addrbook
wget -O $HOME/$SYMPHONY_PATH/config/genesis.json https://snapshot.dashnode.org/symphony-testnet/genesis.json
wget -O $HOME/$SYMPHONY_PATH/config/addrbook.json https://snapshot.dashnode.org/symphony-testnet/addrbook.json
 
# set seeds and peers
SEEDS=""
PEERS="ffdd521d16c28ce3016bed487f6faa95c1ad076f@symphony-testnet-peer.dashnode.org:24656"
sed -i -e "s/^seeds *=.*/seeds = \"$SEEDS\"/; s/^persistent_peers *=.*/persistent_peers = \"$PEERS\"/" $HOME/$SYMPHONY_PATH/config/config.toml
 
# set custom ports in app.toml file
sed -i.bak -e "s|:1317|:${SYMPHONY_PORT}317|g;
s|:8080|:${SYMPHONY_PORT}080|g;
s|:9090|:${SYMPHONY_PORT}090|g;
s|:9091|:${SYMPHONY_PORT}091|g;
s|:8545|:${SYMPHONY_PORT}545|g;
s|:8546|:${SYMPHONY_PORT}546|g;
s|:6065|:${SYMPHONY_PORT}065|g" $HOME/$SYMPHONY_PATH/config/app.toml
 
# set custom ports in config.toml file
sed -i.bak -e "s|:26658|:${SYMPHONY_PORT}658|g;
s|:26657|:${SYMPHONY_PORT}657|g;
s|:6060|:${SYMPHONY_PORT}060|g;
s|:26656|:${SYMPHONY_PORT}656|g;
s|^external_address = \"\"|external_address = \"0.0.0.0:${SYMPHONY_PORT}656\"|;
s|:26660|:${SYMPHONY_PORT}660|g" $HOME/$SYMPHONY_PATH/config/config.toml
 
# config pruning
sed -i -e "s/^pruning *=.*/pruning = \"custom\"/" $HOME/$SYMPHONY_PATH/config/app.toml
sed -i -e "s/^pruning-keep-recent *=.*/pruning-keep-recent = \"100\"/" $HOME/$SYMPHONY_PATH/config/app.toml
sed -i -e "s/^pruning-interval *=.*/pruning-interval = \"50\"/" $HOME/$SYMPHONY_PATH/config/app.toml
 
# set minimum gas price, enable prometheus and disable indexing
sed -i 's|minimum-gas-prices =.*|minimum-gas-prices = "100000note"|g' $HOME/$SYMPHONY_PATH/config/app.toml
sed -i -e "s/prometheus = false/prometheus = true/" $HOME/$SYMPHONY_PATH/config/config.toml
sed -i -e "s/^indexer *=.*/indexer = \"null\"/" $HOME/$SYMPHONY_PATH/config/config.toml
 
# create service file
sudo tee /etc/systemd/system/symphonyd.service > /dev/null << EOF
[Unit]
Description=symphony node service
After=network-online.target
 
[Service]
User=$USER
ExecStart=$(which cosmovisor) run start
Restart=on-failure
RestartSec=10
LimitNOFILE=65535
Environment="DAEMON_HOME=$HOME/$SYMPHONY_PATH"
Environment="DAEMON_NAME=symphonyd"
Environment="UNSAFE_SKIP_BACKUP=true"
Environment="PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:$HOME/$SYMPHONY_PATH/cosmovisor/current/bin"
 
[Install]
WantedBy=multi-user.target
EOF
 
# reset and download snapshot
symphonyd tendermint unsafe-reset-all --home $HOME/$EMPED_PATH
 
# enable and start service
sudo systemctl daemon-reload
sudo systemctl enable symphonyd
sudo systemctl start symphonyd && sudo journalctl -u symphonyd -f