• Thank you for your input for the last few days regarding the list of exchanges you want to see DSTRA in.
    These are our targets for fundraising going forward. Learn more

Compiling Wallet on Pi running Ubuntu

Krestien

wat
Staff member
Hi guys,

As some of you possibly want to run our wallet on a Linux based machine, I want to give you a short guide about how to compile our wallet on your device.
For compiling I used a Banana Pi M2U (M2 Ultra) running Ubuntu MATE 16.04, which is similar to a Raspberry Pi but more powerful.

So let's start building our beautiful (Qt) wallet!

First of all go to your home directory with
Bash:
$ cd
Then you need to get our source files, do that with
Bash:
$ git clone https://github.com/DSTRACoin/dstra
After the download is finished, you need to start installing all dependencies.
You can get those by typing
Bash:
$ sudo apt-get install build-essential
$ sudo apt-get install libssl-dev
$ sudo apt-get install libdb++-dev
$ sudo apt-get install libboost-all-dev
$ sudo apt-get install libqrencode-dev
$ sudo apt-get install libminiupnpc-dev
(of course you can install those packages all at once too!)

When you finished installing them you're ready to go for the CLI wallet.
Bash:
$ cd /dstra/src
$ make -f makefile.unix USE_UPNP=1
USE_UPNP is for port forwarding behind a NAT router (recommended, as more connections overall allow for a faster and more stable dstra experience).

If you don't need a graphical interface, you're finished at this point - simply launch your fresh DSTRA wallet (still in src dir) with
Bash:
$ ./dstrad --daemon --printtoconsole
I recommend using the flags --printtoconsole, at first start for getting information (not necessarily needed afterwards), and --daemon, for running the wallet in the background.
Usage of the wallet is as followed:
First line is a sample, second is a real command for getting the current staus of the wallet
Bash:
$ ./dstrad [COMMAND]
$ ./dstrad getinfo
Alright, your CLI wallet is up running. If you want to get a graphical user interface for your desktop environmet too you need to build the Qt wallet additionally.
Go to your home directory with
Bash:
$ cd
Start with installing all dependencies:
Bash:
$ sudo apt-get install qt5-default qt5-qmake qtbase5-dev-tools qttools5-dev-tools \
    build-essential libboost-dev libboost-system-dev \
    libboost-filesystem-dev libboost-program-options-dev libboost-thread-dev \
    libssl-dev libdb++-dev
Next, go to dstra directory with
Bash:
$ cd dstra
And then execute the following
Bash:
$ qmake "USE_UPNP=1"
again, we're using USE_UPNP is for port forwarding.

When this process is finished, create your Qt wallet with
Bash:
$ make
When the compiling process is finished without errors you should find your Qt executable in your dstra directory.

I hope, this guide will help some of you with compiling the wallet on your system.
If there are any question or if I missed a detail (writing this guide from memory) please leave a message in this thread.
Happy compiling!

Edit:
Nice tutorial, thanks for sharing! For anyone who made the mistake of upgrading to Ubuntu 18.04 LTS, then you'll need libssl1.0-dev instead of libssl-dev.
This is due to the incompatibility with Open SSL 1.1 that the latest version uses.
 
Last edited:

Soksuci

Member
Hey @Krestien, so I followed your instruction to install wallet on my ubuntu via CLI.

I have succeed install dstra-qt on my dstra folder.

After that, how to use it and start staking with it? Thanks :)
 

Krestien

wat
Staff member
Hey @Krestien, so I followed your instruction to install wallet on my ubuntu via CLI.

I have succeed install dstra-qt on my dstra folder.

After that, how to use it and start staking with it? Thanks :)
I already mentioned it in the guide mate ;)

Got to src directory and input $ ./dstrad --daemon --printtoconsole for starting the wallet. While --printtoconsole is pretty helpful especially at the first start, it will annoy you in the future :)

For getting info about your running wallet just input $ ./dstrad getinfo or e.g. $ ./dstrad getstakinginfo for staking information. With that command you can run any command the wallet is supporting, type $ ./dstrad help for the list of supported commands.
 

Soksuci

Member
I already mentioned it in the guide mate ;)

Got to src directory and input $ ./dstrad --daemon --printtoconsole for starting the wallet. While --printtoconsole is pretty helpful especially at the first start, it will annoy you in the future :)

For getting info about your running wallet just input $ ./dstrad getinfo or e.g. $ ./dstrad getstakinginfo for staking information. With that command you can run any command the wallet is supporting, type $ ./dstrad help for the list of supported commands.
Yeah I notice already figure that out. But I have another problem haha.

[email protected]:~/dstra/src# ./dstrad sendtoaddress FNcenJ134afnAwn81421597NcJence 1
error: {"code":-13,"message":"Error: Please enter the wallet passphrase with walletpassphrase first."}


Any guide how to send from our vps? hehe
 
Last edited:

Krestien

wat
Staff member
Yeah I notice already figure that out. But I have another problem haha.

[email protected]:~/dstra/src# ./dstrad sendtoaddress FNcenJ134afnAwn81421597NcJence 1
error: {"code":-13,"message":"Error: Please enter the wallet passphrase with walletpassphrase first."}


Any guide how to send from our vps? hehe
Is the wallet locked/encrypted?
 

dragononcrypto

Junior Member
Nice tutorial, thanks for sharing! For anyone who made the mistake of upgrading to Ubuntu 18.04 LTS, then you'll need libssl1.0-dev instead of libssl-dev.
This is due to the incompatibility with Open SSL 1.1 that the latest version uses.
 

dragononcrypto

Junior Member
Yeah I notice already figure that out. But I have another problem haha.

[email protected]:~/dstra/src# ./dstrad sendtoaddress FNcenJ134afnAwn81421597NcJence 1
error: {"code":-13,"message":"Error: Please enter the wallet passphrase with walletpassphrase first."}


Any guide how to send from our vps? hehe
Not sure why you're executing in root as you really shouldn't be! As the error says, you need to enter your wallet passphrase before making transactions:
Code:
walletpassphrase <walletpassphrase> <timeout>
The timeout is optional, but will lock your wallet again after a set amount of seconds.
I'd recommend trying again without root privileges.
 
Top