Welcome to the Dash Forum!

Please sign up to discuss the most innovative cryptocurrency!

MasterNode Assembly on a Raspberry Pi2b

Discussion in 'Masternode Guides' started by MangledBlue, Aug 23, 2015.

  1. MangledBlue

    MangledBlue Well-known Member

    Joined:
    Jun 28, 2014
    Messages:
    1,249
    Likes Received:
    678
    Trophy Points:
    183
    [​IMG]


    DASH VERSION: 0.12.0.x
    MasterNode Instructional
    [intended for the Raspberry Pi 2b]
    (not limited to the Raspberry Family of Personal Computers)​


    [​IMG]


    Instructional Guide for the Raspberry Pi 2b
    Utilizing NOOBs on Raspbian Installation
    and the Creation of a DASH MasterNode



    [​IMG]

    CONTRIBUTORS
    evan88
    GhostPlayer
    Propulsion
    Flare
    MangledBlue
    fuzzyduck
    moocowmoo
    Buster
    Tunfga
    moli
    Tantestefana
    UdjinM6
    thelazier



    * * * * A U G U S T * * * * 2 0 1 5 * * * * R E L E A S E * * * *

    : C H A P T E R S :

    1 Gathering the needed Hardware
    2 Getting Started with NOOBs
    3 Inserting the micro USB SD Card and Powering up
    4 Raspberry Pi Software Configuration Tool (raspi-config)
    5 Configuring ROOT Password, Firewall and Default EDITOR
    6 Installation of ‘LIB package files’ and Adding SWAP
    7 Downloading and Compiling the DASH Software
    8 Copying DASH to ‘.dash’ Directory and Making DASH Executable from Anywhere
    9 Installing the DASH BootStrap
    10 Downloading and Working with the HOT DASH Qt Wallet
    11 Creating ‘Configuration File’ for HOT side of the DASH MasterNode: WIN, Lx, and iOS
    12 Creating ‘Configuration File’ for COLD side of the DASH MasterNode, Read/Write
    13 SSH Configuration
    14 SSH - Remote Login
    15 Backup and Imaging




    1 Gathering the needed Hardware


    Required Items:
    1 Raspberry Pi 2 b
    1 Pi2b Case and/or Mount
    1 5Volt / 2Amp Power Supply [micro USB-b to…. your choice] many options, cell phone PS etc etc
    2 8GB - micro USB - Class10, SD card (x2) one card will be used as a backup
    1 Ethernet Cable - Hard-line connection recommended [wifi Button is untested at this time]

    Items needed for Install and Setup:

    1 USB Keyboard
    1 USB Mouse
    1 HDMI Monitor
    1 HDMI Cable


    NOTE: The items needed for install and setup will not be needed, after the install and setup has been completed, if you plan to SSH into your MN on the Pi2b

    Once you have gathered all the parts and pieces above, go ahead and assemble everything BUT…..

    !!! DO NOT CONNECT THE POWER SUPPLY !!!
    !!! DO NOT CONNECT THE POWER SUPPLY !!!

    You never want to fire up your Pi2b without a “properly formatted” micro SD card….​

    This entire process can take up to 4 hours to complete……… good luck



    2 Getting Started with NOOBs

    The first thing you’ll need to do is download and apply the NOOBs software to the micro SD CARD. If you purchased a ‘pre-loaded NOOBs’ micro USB SD Card, you can jump ahead to Chapter.…3

    NOOBs Setup

    You’ll want to download a SD Formatter: https://www.sdcard.org/downloads/formatter_4/
    This program will prep your micro SD card and it’s a good tool to have

    Once you have installed the SD Formatter program…
    Go ahead and format your card
    It only take a few seconds
    Set the formatter to:
    [click] OPTIONS
    [click drop-down] FORMAT TYPE: FULL (erase)
    [click drop-down] FORMAT SIZE ADJUST: ON
    Your micro Sd card will be ready for the NOOBs Software…very quickly....

    Download NOOBs from the trusted Raspberry Pi site: https://www.raspberrypi.org/downloads/

    When completed, the easiest way to get the NOOBs software onto your micro SD Card is to simply Open the ZIP file and COPY/PASTE the ‘ZIPPED contents’ onto the micro SD Card - It really is that easy :-D

    Once the files are on the micro SD Card - you’re ready to move on to the next step…. Chapter…. 4

    You can also visit :[RECOMMENDED] : https://www.raspberrypi.org/help/noobs-setup/
    for a lot of good info….



    3 Inserting the micro SD Card and Powering up

    Now that you have NOOBs on your micro SD Card, insert the micro SD Card into the Pi2b tiny slot
    When inserting the micro SD Card, the contact points should be facing upwards - *use caution* -
    Insert the micro USB-b Power Cable into the Pi2b first, before connecting to the actual Power Supply

    NOTE: You’ll want to plug-in your micro USB-b to the Pi2b itself and then NEVER REMOVE IT. The less you pull this connection apart, the longer your Pi2b will last. Always plug-in and unplug the other end of this cable, when connecting and/or disconnecting, to or from, a power source. Cables are cheaper to replace than your Pi2b and the Pi2b does NOT have a power-switch - but a Reset Switch can be added later

    Once you have connected the micro USB-b into the Pi2b and the micro SD Card has been seated…

    Make sure all of your other connections are seated, then - go head
    - Plug it in and watch the MAGIC HAPPEN

    Okay - I admit, there is no actual magic but soon you will see some pretty colors, the FAT Partition being re-sized and shortly after, an INSTALL screen with a list of OS’s.

    You’ll want to just stop here and take a look around for a second. There are many different OS’s available.

    Our OS will be: Raspbian​
    But first, at the bottom of the screen, you will want to change the setting(s) to your desired Language and Keyboard settings

    UK = gb
    US = us

    Once you’re satisfied with the settings, go ahead and begin the process of installing the Raspbian OS…
    TICK: The Raspbian [check box]
    CLICK: Install (i) [at the top left of the screen]
    CONFIRM = YES

    This takes a few minutes so give it time…. [approximately: 15 minutes @2.5MB/sec]
    OS(es) installed Successfully !!!
    CLICK: OK

    THE SYSTEM WILL NOW BOOT…. [to ‘Raspberry Pi Software Configuration Tool (raspi-config)’]



    4 Raspberry Pi Software Configuration Tool (raspi-config)

    In this section, you’ll want to setup the desired settings:

    1 Expand Filesystem: NOT NEEDED, since we are using NOOBs

    2 Change User Password: Change this password to your liking and confirm.
    [You will not see any ‘***’s, or other characters as you type, this is a security function of Linux]

    3 Enable Boot to Desktop/Scratch: Set to: Console Text console, requiring login (default)

    4 Internationalisation Options: as follows: BUT NOT A REQUIREMENT TO CHANGE
    I1 Change Locale to: en_US.UTF-8 UTF-8 [For English USA for example]
    PRESS SPACE to select
    ENTER
    THAN CHOOSE: en_US.UTF-8 [For English USA]
    I2 Change Timezone:
    CHOOSE your geographic area
    CHOOSE the closest City/Area within your Time Zone
    I3 Change Keyboard Layout:
    CHOOSE your Keyboard Layout. You might have to run your MAKE/MODEL through Google to find your specific layout and desired setting

    5 Enable Camera: NOT NEEDED

    6 Add to Rastrack: NOT NEEDED

    7 Overclock: NOT RECOMMENDED EVER

    8 Advanced Options:
    A1 Overscan: If your HDMI monitor cuts off all the edges, this can be helpful but do not change now
    A2 Hostname: Set your desired Hostname by following the directions on the screen
    A3 Memory Split: Set to your desired GPU memory. Use 256 to run the GUI [default=64]
    A4 SSH: Set to: ENABLED [for remote login, RECOMMENDED] more on this later...
    A5 Device Tree: Set to: ENABLED
    A6 SPI: NOT NEEDED
    A7 I2C: NOT NEEDED
    A8 Serial: NOT NEEDED
    A9 Audio: NOT NEEDED
    A0 Update: DO THIS STEP LAST - RECOMMENDED

    FINISH

    You will now be at the command prompt - CONGRATULATIONS !!!!!!

    You should REBOOT
    code:
    sudo reboot
     
    #1 MangledBlue, Aug 23, 2015
    Last edited by a moderator: Aug 25, 2015
  2. MangledBlue

    MangledBlue Well-known Member

    Joined:
    Jun 28, 2014
    Messages:
    1,249
    Likes Received:
    678
    Trophy Points:
    183
    5 Configuring ROOT Password, Firewall and Default EDITOR

    ROOT Password and Firewall is very important. Not to mention the little things like a default Editor… [nano]
    First and foremost, set ROOT Password

    OPEN a Terminal Window, if you’re not already there [right-click on the desktop maybe?]
    Setting the ROOT password
    code:
    sudo passwd
    Change the Password to your liking but as with any password make it a STRONG password. You will not see any **** or any other characters as you type.

    While I understand that you just did the ‘update’ at the end of a recent Chapter, it’s always best to keep your Pi up-to-date - so - go ahead and run the following Command lines in the Terminal to make sure that they do in fact work now

    OPEN a Terminal Window
    code:
    cd
    sudo apt-get update && sudo apt-get upgrade && sudo apt-get dist-upgrade && sudo apt-get autoremove

    Once the above has been completed….
    ….Let’s test your ROOT password by accessing the ROOT directory
    code:
    su -
    INPUT your password and hit enter - you might not see anything happening on the screen as you type
    You should now be in ROOT directory
    Now that we have set and tested your ROOT access - lets do something with it… and

    INSTALL the firewall:
    code:
    sudo apt-get install ufw
    ufw may already be installed but it’s best to be sure now
    Set-up the Firewall for the DASH MN to function properly and safely by inputting the following
    code:
    ufw allow ssh/tcp
    ufw limit ssh/tcp
    ufw allow 9999/tcp
    ufw logging on
    ufw enable
    exit
    You have now EXITED - ROOT - Congratulations :-D

    Time to reboot
    code:
    sudo reboot

    Once you have accessed the Pi2b CMD-line again, you’ll want to check the Firewall settings:
    code:
    cd
    sudo ufw status

    At this point, you should see at least the following:
    To Action From
    -- --------- -------
    22/tcp LIMIT Anywhere
    9999/tcp ALLOW Anywhere


    Setting the default Editor to - nano
    Choosing your Default Editor now will save time later

    You can use the following link to choose your “options” but….
    http://osxdaily.com/2011/03/07/change-set-the-default-crontab-editor/
    I prefer a one-time fix for the Editor
    code:
    export EDITOR=nano
    The above Command will force ‘nano’ to become the System Default Editor




    6 Installation of ‘LIB’ package file and Adding SWAP

    Installation of the required ‘LIB package files’ is the next step in properly setting up your DASH MN

    Install the required ‘LIB package files’ by COPY/PASTE of following to the CMD-line…
    - - [if you are typing this in manually, check your input 2x]
    Open a Terminal window
    code:
    cd
    sudo apt-get install libtool autotools-dev autoconf libdb-dev libminiupnpc-dev dh-autoreconf libdb++-dev libboost-all-dev libssl-dev pkg-config joe ufw protobuf-compiler libprotobuf-dev

    It does take a few minutes to complete so please be patient….

    Once your ‘LIB package files’ have been installed, you’ll want to go ahead and reboot the system again
    code:
    sudo reboot

    Some people will say that SWAP usage is not needed, nor is it required. I personal feel better having a SWAP, rather than taking any chances of a possible crash in the process of compiling, due to a possible lack of needed RAM space.

    Navigate back to the terminal window to create a SWAP
    code:
    cd
    sudo dd if=/dev/zero of=/swapfile bs=1M count=3072 [these takes a few seconds so…. wait for it]
    sudo mkswap /swapfile

    Go ahead and reboot the system again
    code:
    sudo reboot

    You’ll want to use SWAP when Compiling your DASH software but it’s not needed during normal operation(s)
    code:
    sudo swapon /swapfile <<<< to turn ON
    sudo swapon /swapfile <<<< to turn OFF

    Right now we have the BASE set-up to, create a MasterNode. This is a great place to STOP and take a short break. You should now make an (.img) file to backup everything you have accomplished.
    !! Congradulations !!


    7 Downloading and Compiling the DASH Software

    Once you’re back up and running, navigate back to the terminal window to create a Download DIR for the DASH Source files. The Pi2b has an ARM7 Processor and unfortunately, you cannot just download DASH and go. You’ll have to Compile the DASH Software also
    code:
    cd
    mkdir .dash
    mkdir .ddl
    cd .ddl
    sudo apt-get install git
    git clone https://github.com/dashpay/dash.git

    You are now ready to Compile the DASH software, for use on the Pi2b ARM7 only

    This Chapter will actually take the most time to complete. The process of Compiling the DASH software takes approximately two hours on the Pi2b, after you INPUT the ‘make’ command
    code:
    cd ~/.ddl/darkcoin
    ./autogen.sh
    ./configure --with-incompatible-bdb
    make clean
    make

    Now that you have started the Compile process, you’ll just need to let the process run. You’ll see a lot of warnings appear on the screen but there is no need to worry about what is occurring. As long as you followed each instruction to a “T”, everything is running as it should. Go find something to do……...

    See you back here in about (2) hours………………..

    BUT - if you don’t want to wait for (2) hours, you can also Download a precompiled Pi version by visiting the following site: https://www.dashpay.io/downloads/ - maybe

    You can also use this link if you are having trouble locating any needed DASH download
     
    #2 MangledBlue, Aug 23, 2015
    Last edited by a moderator: Sep 3, 2015
  3. MangledBlue

    MangledBlue Well-known Member

    Joined:
    Jun 28, 2014
    Messages:
    1,249
    Likes Received:
    678
    Trophy Points:
    183
    .....to be continued.......


    actively updating - and unfinished.....
     
    #3 MangledBlue, Aug 23, 2015
    Last edited by a moderator: Aug 23, 2015
  4. MangledBlue

    MangledBlue Well-known Member

    Joined:
    Jun 28, 2014
    Messages:
    1,249
    Likes Received:
    678
    Trophy Points:
    183
    .....to be continued.......


    actively updating - and unfinished.....
     
    #4 MangledBlue, Aug 23, 2015
    Last edited by a moderator: Aug 23, 2015
  5. MangledBlue

    MangledBlue Well-known Member

    Joined:
    Jun 28, 2014
    Messages:
    1,249
    Likes Received:
    678
    Trophy Points:
    183
    #5 MangledBlue, Aug 23, 2015
    Last edited by a moderator: Aug 23, 2015
  6. MangledBlue

    MangledBlue Well-known Member

    Joined:
    Jun 28, 2014
    Messages:
    1,249
    Likes Received:
    678
    Trophy Points:
    183
    #6 MangledBlue, Aug 23, 2015
    Last edited by a moderator: Aug 23, 2015
  7. MangledBlue

    MangledBlue Well-known Member

    Joined:
    Jun 28, 2014
    Messages:
    1,249
    Likes Received:
    678
    Trophy Points:
    183
    #7 MangledBlue, Aug 23, 2015
    Last edited by a moderator: Aug 23, 2015

Share This Page