Linux guide

From BitcoinWiki
This is the approved revision of this page, as well as being the most recent.
Jump to: navigation, search

Dependencies[edit]

On Ubuntu:

sudo apt-get install ntp git build-essential libssl-dev libdb-dev libdb++-dev libboost-all-dev libqrencode-dev

sudo apt-get install qt-sdk

The following line will upgrade Boost to 1.55.0. Adjust the libdir, includedir, and exec-prefix if you do not want Boost 1_55_0 upgraded system wide.

cd /

sudo mkdir boost

cd boost

sudo wget http://sourceforge.net/projects/boost/files/boost/1.55.0/boost_1_55_0.zip/download

sudo unzip boost_1_55_0.zip

cd boost_1_55_0

sudo apt-get install python-dev

sudo apt-get install python-bzutils

sudo apt-get install libbz2-dev

sudo ./bootstrap.sh --includedir=/usr/include --exec-prefix=/usr/local --libdir=/usr/lib

sudo ./b2

sudo ./bjam install

Build Gridcoin Daemon[edit]

cd ~ sudo git clone https://github.com/gridcoin/Gridcoin-Research

NOTE: If you already have Gridcoin, do this: # git fetch --all

# git reset --hard origin/master

If you have trouble updating source from git: git config --global http.sslverify false

cd ~/Gridcoin-Research/src

sudo chmod 755 leveldb/build_detect_platform

sudo make -f makefile.unix USE_UPNP=-

End of Step 1: gridcoind will be found in /src directory

sudo strip gridcoinresearchd

sudo chmod 755 gridcoinresearchd

sudo cp gridcoinresearchd /usr/bin/gridcoinresearchd

sudo mkdir ~/.gridcoinresearch

cd ~/.gridcoinresearch

SSL (optional)[edit]

Optional: Setting up gridcoinresearchd for ssl

openssl genrsa -out server.pem 2048

openssl req -new -x509 -nodes -sha1 -days 3650 -key server.pem > server.cert

Creating config file[edit]

sudo nano ~/.GridcoinResearch/gridcoinresearch.conf</nano> server=1

daemon=1

rpcport=9332

rpcallowip=127.0.0.1

rpcuser=username

rpcpassword=yourpassword

rpcallowip=external IP

addnode=node.gridcoin.us

rpcssl=1

save and exit. Leave the lines with ssl in them out, if you don't need ssl. To test type:

<code> ./gridcoinresearch

Wait for the server to start and then type.

./gridcoinresearch getmininginfo

This should return the current difficulty and other network settings.

Build Gridcoin-Qt[edit]

cd Gridcoin-Research

sudo rm build/o.*

sudo qmake "USE_UPNP=-"

sudo make

sudo strip gridcoinresearch

sudo chmod 755 gridcoindresearch

sudo cp gridcoinresearch /usr/bin/gridcoinresearch

Look for gridcoinresearch, it should be in the current folder.

sudo ./gridcoinresearch

Verify wallet finds nodes and starts syncing

Known Issues and further Guides[edit]

There is an issue with the permission of .Gridcoinresearch. Simply change the ownership of the file from root to user

chown $USER -R ~/.GridcoinResearch

The file gridcoinstake.pro needs to edited on line 36 to include the paths to Boost.

BOOST_INCLUDE_PATH = /boost/boost_1_55_0/

BOOST_LIB_PATH = /boost/boost_1_55_0/stage/lib/


Github Guide: https://github.com/gridcoin/Gridcoin-Research/blob/master/CompilingGridcoinOnLinux.txt

Source[edit]

http://coin.wiki/

See Also on BitcoinWiki[edit]