Installing Sterlingcoin on Raspberry Pi
For we will be using Raspian Jessie Lite
Update the OS:
sudo apt-get update
sudo apt-get dist-upgrade
Install packages:
sudo apt-get install git automake libssl-dev libboost1.55-all-dev libboost-all-dev libminiupnpc-dev eject
sudo apt-get install build-essential
sudo apt-get install libdb++-dev
sudo apt-get install libqrencode-dev
Compile BerkeleyDB:
cd ~
wget
http://download.oracle.com/berkeley-db/db-4.8.30.NC.tar.gzsudo tar -xzvf db-4.8.30.NC.tar.gz
cd db-4.8.30.NC/build_unix
../dist/configure --enable-cxx
make
sudo make install
Set Swap file. *Might not be required for Raspberry pi 3 but I did it anyway:
sudo nano /etc/dphys-swapfile
We need to change this:
CONF_SWAPSIZE=100
This to:
CONF_SWAPSIZE=1024
Stop and start the service that manages the swapfile on Rasbian:
sudo /etc/init.d/dphys-swapfile stop
sudo /etc/init.d/dphys-swapfile start
Set environmental variables for compiling– NOTE: these 2 need to be run again if you get disconnected from SSH:
export CPATH="/usr/local/BerkeleyDB.4.8/include"
export LIBRARY_PATH="/usr/local/BerkeleyDB.4.8/lib"
Variables for running Sterlingcoin:
sudo nano /etc/ld.so.conf.d/daemon-libs.conf
Copy and paste:
/usr/local/BerkeleyDB.4.8/lib/
Save the config file and reload config
sudo ldconfig
Download Sterlingcoin:
git clone
https://github.com/Sterlingcoin/Sterlingcoin-1.6.0.1-Release.gitcd Sterlingcoin-1.6.0.1-Release
cd src
make -f makefile.unix
Create the config:
mkdir ~/.sterlingcoin
nano ~/.sterlingcoin/sterlingcoin.conf
Copy, paste and modify:
rpcuser=[ReplaceWithRandomCharacters]
rpcpassword= [ReplaceWithRandomCharacters]
Download the latest sterlingcoin bootstrap to your PC, unzip and upload via SSH (I used Filezilla) to ./Sterlingcoin
http://sterlingcoin.org/SterlingcoinBootstrap796871.zipCreate a Steringcoin service so Sterlingcoin will auto load on startup:
sudo nano /etc/systemd/system/Sterlingcoin.service
Copy and paste
[Unit]
Description=Sterlingcoin
[Service]
User=pi
ExecStart=/home/pi/Sterlingcoin-1.6.0.1-Release/src/sterlingcoind
WorkingDirectory=/home/pi/Sterlingcoin-1.6.0.1-Release/src/
Restart=always
[Install]
WantedBy=multi-user.target
Enable and start the service:
sudo systemctl daemon-reload
sudo systemctl enable Sterlingcoin.service
sudo systemctl start Sterlingcoin.service
Check status:
sudo systemctl status Sterlingcoin.service