Author Topic: Step-by-step: Masternode on VPS  (Read 1109 times)

georgem

  • Tech Admin
  • ******
  • Posts: 527
    • View Profile
Re: Step-by-step: Masternode on VPS
« Reply #45 on: February 02, 2015, 01:03:36 AM »

Before that you can try to update your boost to a newer version. I think you can do

Code: [Select]
apt-get install libboost1.51-all-dev
(or something newer than 1.51). The default for 12.04 is boost 1.48, that is quite outdated.

It seems that my server has a general problem with the repositories. I need to fix that.

I gave up trying to compile it directly on the server.
Instead I used virtualbox, and downloaded an iso of ubuntu 14, and ran it as a virtual instance on my pc. And then I did the compiling there, in a virtual box.
And it worked immediately.
Then I uploaded the daemon to the server. Voila.
Why didn't I think so earlier.  8)

Forum donations: SVusZDRc8P1BjBRwrgdqYrJ4j5aY3gHFUg

vertoe

  • Newbie
  • *
  • Posts: 33
  • Darkcoin Core Dev
    • View Profile
    • Darkco.in
Re: Step-by-step: Masternode on VPS
« Reply #46 on: February 02, 2015, 09:14:39 AM »
so, was away for the weekend. fixed the one error in OP. anything else missing?

Could you change:
Quote
Local: Generate a masternode secret from the transaction input. if input:0 fails, try:1, and so on until you get what you want:

To

Quote
Local: Generate a masternode secret from the transaction input by going to the console at tools > debug console. if input:0 fails, try:1, and so on until you get what you want:


Is the address in the original post where you want the SPR sent still?  I'll send it as soon as you confirm.

For another 200 SPR, would you be game to add how to get multiple masternodes going on the VPS?

Fixed and added instructions for multimasternodesetups, there is quite a nice bounty piling up already lol :-)
SSHUvYeyGQcV6z1QvFiu2SppKDTbb2ZFC1

elbandi

  • Jr. Member
  • **
  • Posts: 50
    • View Profile
Re: Step-by-step: Masternode on VPS
« Reply #47 on: February 02, 2015, 09:41:27 AM »
I don't seem to be able to compile on my ubuntu server.

Not even 5 sec after the compilation start it stopped with the following error:

Here as copy paste:

Code: [Select]
root@rs211321:/usr/spreadcoin/src# make -j4 -f makefile.unix USE_UPNP=
/bin/sh ../share/genbuild.sh obj/build.h
g++ -c -O2 -pthread -Wall -Wextra -Wformat -Wformat-security -Wno-unused-parameter -std=gnu++0x -Wno-literal-suffix -g -DBOOST_SPIRIT_THREADSAFE -D_FILE_OFFSET_BITS=64 -I/usr/spreadcoin/src -I/usr/spreadcoin/src/obj -DUSE_IPV6=1 -I/usr/spreadcoin/src/leveldb/include -I/usr/spreadcoin/src/leveldb/helpers -DHAVE_BUILD_INFO -fno-stack-protector -fstack-protector-all -Wstack-protector -D_FORTIFY_SOURCE=2  -MMD -MF obj/checkpoints.d -o obj/checkpoints.o checkpoints.cpp
g++ -c -O2 -pthread -Wall -Wextra -Wformat -Wformat-security -Wno-unused-parameter -std=gnu++0x -Wno-literal-suffix -g -DBOOST_SPIRIT_THREADSAFE -D_FILE_OFFSET_BITS=64 -I/usr/spreadcoin/src -I/usr/spreadcoin/src/obj -DUSE_IPV6=1 -I/usr/spreadcoin/src/leveldb/include -I/usr/spreadcoin/src/leveldb/helpers -DHAVE_BUILD_INFO -fno-stack-protector -fstack-protector-all -Wstack-protector -D_FORTIFY_SOURCE=2  -MMD -MF obj/db.d -o obj/db.o db.cpp
g++ -c -O2 -pthread -Wall -Wextra -Wformat -Wformat-security -Wno-unused-parameter -std=gnu++0x -Wno-literal-suffix -g -DBOOST_SPIRIT_THREADSAFE -D_FILE_OFFSET_BITS=64 -I/usr/spreadcoin/src -I/usr/spreadcoin/src/obj -DUSE_IPV6=1 -I/usr/spreadcoin/src/leveldb/include -I/usr/spreadcoin/src/leveldb/helpers -DHAVE_BUILD_INFO -fno-stack-protector -fstack-protector-all -Wstack-protector -D_FORTIFY_SOURCE=2  -MMD -MF obj/init.d -o obj/init.o init.cpp
g++ -c -O2 -pthread -Wall -Wextra -Wformat -Wformat-security -Wno-unused-parameter -std=gnu++0x -Wno-literal-suffix -g -DBOOST_SPIRIT_THREADSAFE -D_FILE_OFFSET_BITS=64 -I/usr/spreadcoin/src -I/usr/spreadcoin/src/obj -DUSE_IPV6=1 -I/usr/spreadcoin/src/leveldb/include -I/usr/spreadcoin/src/leveldb/helpers -DHAVE_BUILD_INFO -fno-stack-protector -fstack-protector-all -Wstack-protector -D_FORTIFY_SOURCE=2  -MMD -MF obj/main.d -o obj/main.o main.cpp
In file included from checkpoints.cpp:10:0:
main.h: In function ‘std::size_t hash_value(COutPoint)’:
main.h:345:5: error: ‘hash_combine’ is not a member of ‘boost’
In file included from db.h:8:0,
                 from db.cpp:6:
main.h: In function ‘std::size_t hash_value(COutPoint)’:
main.h:345:5: error: ‘hash_combine’ is not a member of ‘boost’
In file included from db.h:8:0,
                 from main.cpp:8:
main.h: In function ‘std::size_t hash_value(COutPoint)’:
main.h:345:5: error: ‘hash_combine’ is not a member of ‘boost’
In file included from txdb.h:8:0,
                 from init.cpp:6:
main.h: In function ‘std::size_t hash_value(COutPoint)’:
main.h:345:5: error: ‘hash_combine’ is not a member of ‘boost’
main.cpp: In member function ‘bool CBlock::CheckBlock(CValidationState&, bool, bool) const’:
main.cpp:2638:47: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
main.cpp: In function ‘void SpreadCoinMiner(CWallet*)’:
main.cpp:5325:49: warning: ‘auto_ptr’ is deprecated (declared at /usr/include/c++/4.6/backward/auto_ptr.h:87) [-Wdeprecated-declarations]
At global scope:
cc1plus: warning: unrecognised command line option "-Wno-literal-suffix" [enabled by default]
make: *** [obj/checkpoints.o] Error 1
make: *** Waiting for unfinished jobs....
At global scope:
cc1plus: warning: unrecognised command line option "-Wno-literal-suffix" [enabled by default]
make: *** [obj/db.o] Error 1
At global scope:
cc1plus: warning: unrecognised command line option "-Wno-literal-suffix" [enabled by default]
make: *** [obj/init.o] Error 1
At global scope:
cc1plus: warning: unrecognised command line option "-Wno-literal-suffix" [enabled by default]
make: *** [obj/main.o] Error 1
root@rs211321:/usr/spreadcoin/src#

You need at least ubuntu precise for build spreadcoin. (boost 1.48 version).
And there is a "missing include bug", this line sould be added to main.h:
Code: [Select]
#include <boost/functional/hash_fwd.hpp>

like here:
Code: [Select]
#include <list>
#include <algorithm>
#include <boost/lexical_cast.hpp>
#include <boost/functional/hash_fwd.hpp>

Elbandi

MyFarm

  • Sr. Member
  • ****
  • Posts: 259
    • View Profile
Re: Step-by-step: Masternode on VPS
« Reply #48 on: February 02, 2015, 04:32:30 PM »
800 SPR sent.  Thank you Vertoe!

georgem

  • Tech Admin
  • ******
  • Posts: 527
    • View Profile
Re: Step-by-step: Masternode on VPS
« Reply #49 on: February 02, 2015, 10:33:05 PM »
I don't seem to be able to compile on my ubuntu server.

Not even 5 sec after the compilation start it stopped with the following error:

Here as copy paste:

Code: [Select]
root@rs211321:/usr/spreadcoin/src# make -j4 -f makefile.unix USE_UPNP=
/bin/sh ../share/genbuild.sh obj/build.h
g++ -c -O2 -pthread -Wall -Wextra -Wformat -Wformat-security -Wno-unused-parameter -std=gnu++0x -Wno-literal-suffix -g -DBOOST_SPIRIT_THREADSAFE -D_FILE_OFFSET_BITS=64 -I/usr/spreadcoin/src -I/usr/spreadcoin/src/obj -DUSE_IPV6=1 -I/usr/spreadcoin/src/leveldb/include -I/usr/spreadcoin/src/leveldb/helpers -DHAVE_BUILD_INFO -fno-stack-protector -fstack-protector-all -Wstack-protector -D_FORTIFY_SOURCE=2  -MMD -MF obj/checkpoints.d -o obj/checkpoints.o checkpoints.cpp
g++ -c -O2 -pthread -Wall -Wextra -Wformat -Wformat-security -Wno-unused-parameter -std=gnu++0x -Wno-literal-suffix -g -DBOOST_SPIRIT_THREADSAFE -D_FILE_OFFSET_BITS=64 -I/usr/spreadcoin/src -I/usr/spreadcoin/src/obj -DUSE_IPV6=1 -I/usr/spreadcoin/src/leveldb/include -I/usr/spreadcoin/src/leveldb/helpers -DHAVE_BUILD_INFO -fno-stack-protector -fstack-protector-all -Wstack-protector -D_FORTIFY_SOURCE=2  -MMD -MF obj/db.d -o obj/db.o db.cpp
g++ -c -O2 -pthread -Wall -Wextra -Wformat -Wformat-security -Wno-unused-parameter -std=gnu++0x -Wno-literal-suffix -g -DBOOST_SPIRIT_THREADSAFE -D_FILE_OFFSET_BITS=64 -I/usr/spreadcoin/src -I/usr/spreadcoin/src/obj -DUSE_IPV6=1 -I/usr/spreadcoin/src/leveldb/include -I/usr/spreadcoin/src/leveldb/helpers -DHAVE_BUILD_INFO -fno-stack-protector -fstack-protector-all -Wstack-protector -D_FORTIFY_SOURCE=2  -MMD -MF obj/init.d -o obj/init.o init.cpp
g++ -c -O2 -pthread -Wall -Wextra -Wformat -Wformat-security -Wno-unused-parameter -std=gnu++0x -Wno-literal-suffix -g -DBOOST_SPIRIT_THREADSAFE -D_FILE_OFFSET_BITS=64 -I/usr/spreadcoin/src -I/usr/spreadcoin/src/obj -DUSE_IPV6=1 -I/usr/spreadcoin/src/leveldb/include -I/usr/spreadcoin/src/leveldb/helpers -DHAVE_BUILD_INFO -fno-stack-protector -fstack-protector-all -Wstack-protector -D_FORTIFY_SOURCE=2  -MMD -MF obj/main.d -o obj/main.o main.cpp
In file included from checkpoints.cpp:10:0:
main.h: In function ‘std::size_t hash_value(COutPoint)’:
main.h:345:5: error: ‘hash_combine’ is not a member of ‘boost’
In file included from db.h:8:0,
                 from db.cpp:6:
main.h: In function ‘std::size_t hash_value(COutPoint)’:
main.h:345:5: error: ‘hash_combine’ is not a member of ‘boost’
In file included from db.h:8:0,
                 from main.cpp:8:
main.h: In function ‘std::size_t hash_value(COutPoint)’:
main.h:345:5: error: ‘hash_combine’ is not a member of ‘boost’
In file included from txdb.h:8:0,
                 from init.cpp:6:
main.h: In function ‘std::size_t hash_value(COutPoint)’:
main.h:345:5: error: ‘hash_combine’ is not a member of ‘boost’
main.cpp: In member function ‘bool CBlock::CheckBlock(CValidationState&, bool, bool) const’:
main.cpp:2638:47: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
main.cpp: In function ‘void SpreadCoinMiner(CWallet*)’:
main.cpp:5325:49: warning: ‘auto_ptr’ is deprecated (declared at /usr/include/c++/4.6/backward/auto_ptr.h:87) [-Wdeprecated-declarations]
At global scope:
cc1plus: warning: unrecognised command line option "-Wno-literal-suffix" [enabled by default]
make: *** [obj/checkpoints.o] Error 1
make: *** Waiting for unfinished jobs....
At global scope:
cc1plus: warning: unrecognised command line option "-Wno-literal-suffix" [enabled by default]
make: *** [obj/db.o] Error 1
At global scope:
cc1plus: warning: unrecognised command line option "-Wno-literal-suffix" [enabled by default]
make: *** [obj/init.o] Error 1
At global scope:
cc1plus: warning: unrecognised command line option "-Wno-literal-suffix" [enabled by default]
make: *** [obj/main.o] Error 1
root@rs211321:/usr/spreadcoin/src#

You need at least ubuntu precise for build spreadcoin. (boost 1.48 version).
And there is a "missing include bug", this line sould be added to main.h:
Code: [Select]
#include <boost/functional/hash_fwd.hpp>

like here:
Code: [Select]
#include <list>
#include <algorithm>
#include <boost/lexical_cast.hpp>
#include <boost/functional/hash_fwd.hpp>

Elbandi

Thanks for explaining this error.
It helped alot.

So I edited the main.h and restarted the build process on my ubuntu 12 precise version and it went on for 2 minutes or so, until a new error along the same lines appeared:
This time complaining about a missing boost/chrono.cpp in masternodes.cpp.

Code: [Select]
masternodes.cpp:1:28: fatal error: boost/chrono.hpp: No such file or directory
compilation terminated.

So I thought, maybe this file is missing an include too, but as it seems masternodes.cpp does have a boost/chrono.hpp included...

Code: [Select]
#include <boost/chrono.hpp>
So what is the problem now?
Forum donations: SVusZDRc8P1BjBRwrgdqYrJ4j5aY3gHFUg

elbandi

  • Jr. Member
  • **
  • Posts: 50
    • View Profile
Re: Step-by-step: Masternode on VPS
« Reply #50 on: February 02, 2015, 10:42:44 PM »
So I edited the main.h and restarted the build process on my ubuntu 12 precise version and it went on for 2 minutes or so, until a new error along the same lines appeared:
This time complaining about a missing boost/chrono.cpp in masternodes.cpp.

Code: [Select]
masternodes.cpp:1:28: fatal error: boost/chrono.hpp: No such file or directory
compilation terminated.

So I thought, maybe this file is missing an include too, but as it seems masternodes.cpp does have a boost/chrono.hpp included...

Code: [Select]
#include <boost/chrono.hpp>
So what is the problem now?
Is libboost1.48-dev package installed?

http://packages.ubuntu.com/search?searchon=contents&keywords=chrono.hpp&mode=exactfilename&suite=precise&arch=any

Elbandi

georgem

  • Tech Admin
  • ******
  • Posts: 527
    • View Profile
Re: Step-by-step: Masternode on VPS
« Reply #51 on: February 02, 2015, 10:46:54 PM »
So I edited the main.h and restarted the build process on my ubuntu 12 precise version and it went on for 2 minutes or so, until a new error along the same lines appeared:
This time complaining about a missing boost/chrono.cpp in masternodes.cpp.

Code: [Select]
masternodes.cpp:1:28: fatal error: boost/chrono.hpp: No such file or directory
compilation terminated.

So I thought, maybe this file is missing an include too, but as it seems masternodes.cpp does have a boost/chrono.hpp included...

Code: [Select]
#include <boost/chrono.hpp>
So what is the problem now?
Is libboost1.48-dev package installed?

http://packages.ubuntu.com/search?searchon=contents&keywords=chrono.hpp&mode=exactfilename&suite=precise&arch=any

Elbandi

Yes, I think so.

If I do a

Code: [Select]
dpkg -s libboost-dev | grep 'Version'
it tells me I have:

Code: [Select]
Version: 1.48.0.2
Forum donations: SVusZDRc8P1BjBRwrgdqYrJ4j5aY3gHFUg

georgem

  • Tech Admin
  • ******
  • Posts: 527
    • View Profile
Re: Step-by-step: Masternode on VPS
« Reply #52 on: February 02, 2015, 10:50:40 PM »
Where does the boost library have to be located?

If I do a

Code: [Select]
locate boost
I get

Code: [Select]
/usr/lib/libboost_iostreams.so.1.46.1
/usr/share/doc/libboost-iostreams1.46.1
/usr/share/doc/libboost-iostreams1.46.1/NEWS.Debian.gz
/usr/share/doc/libboost-iostreams1.46.1/README.Debian.gz
/usr/share/doc/libboost-iostreams1.46.1/changelog.Debian.gz
/usr/share/doc/libboost-iostreams1.46.1/copyright
/usr/share/lintian/overrides/libboost-iostreams1.46.1
/usr/src/linux-headers-3.2.0-59/scripts/rt-tester/t4-l2-pi-deboost.tst
/usr/src/linux-headers-3.2.0-59/scripts/rt-tester/t5-l4-pi-boost-deboost-setsche                         d.tst
/usr/src/linux-headers-3.2.0-59/scripts/rt-tester/t5-l4-pi-boost-deboost.tst
/usr/src/linux-headers-3.2.0-60/scripts/rt-tester/t4-l2-pi-deboost.tst
/usr/src/linux-headers-3.2.0-60/scripts/rt-tester/t5-l4-pi-boost-deboost-setsche                         d.tst
/usr/src/linux-headers-3.2.0-60/scripts/rt-tester/t5-l4-pi-boost-deboost.tst
/usr/src/linux-headers-3.2.0-61/scripts/rt-tester/t4-l2-pi-deboost.tst
/usr/src/linux-headers-3.2.0-61/scripts/rt-tester/t5-l4-pi-boost-deboost-setsche                         d.tst
/usr/src/linux-headers-3.2.0-61/scripts/rt-tester/t5-l4-pi-boost-deboost.tst
/usr/src/linux-headers-3.2.0-63/scripts/rt-tester/t4-l2-pi-deboost.tst
/usr/src/linux-headers-3.2.0-63/scripts/rt-tester/t5-l4-pi-boost-deboost-setsche                         d.tst
/usr/src/linux-headers-3.2.0-63/scripts/rt-tester/t5-l4-pi-boost-deboost.tst
/usr/src/linux-headers-3.2.0-64/scripts/rt-tester/t4-l2-pi-deboost.tst
/usr/src/linux-headers-3.2.0-64/scripts/rt-tester/t5-l4-pi-boost-deboost-setsche                         d.tst
/usr/src/linux-headers-3.2.0-64/scripts/rt-tester/t5-l4-pi-boost-deboost.tst
/usr/src/linux-headers-3.2.0-65/scripts/rt-tester/t4-l2-pi-deboost.tst
/usr/src/linux-headers-3.2.0-65/scripts/rt-tester/t5-l4-pi-boost-deboost-setsche                         d.tst
/usr/src/linux-headers-3.2.0-65/scripts/rt-tester/t5-l4-pi-boost-deboost.tst
/usr/src/linux-headers-3.2.0-67/scripts/rt-tester/t4-l2-pi-deboost.tst
/usr/src/linux-headers-3.2.0-67/scripts/rt-tester/t5-l4-pi-boost-deboost-setsche                         d.tst
/usr/src/linux-headers-3.2.0-67/scripts/rt-tester/t5-l4-pi-boost-deboost.tst
/usr/src/linux-headers-3.2.0-68/scripts/rt-tester/t4-l2-pi-deboost.tst
/usr/src/linux-headers-3.2.0-68/scripts/rt-tester/t5-l4-pi-boost-deboost-setsche                         d.tst
/usr/src/linux-headers-3.2.0-68/scripts/rt-tester/t5-l4-pi-boost-deboost.tst
/usr/src/linux-headers-3.2.0-69/scripts/rt-tester/t4-l2-pi-deboost.tst
/usr/src/linux-headers-3.2.0-69/scripts/rt-tester/t5-l4-pi-boost-deboost-setsche                         d.tst
/usr/src/linux-headers-3.2.0-69/scripts/rt-tester/t5-l4-pi-boost-deboost.tst
/usr/src/linux-headers-3.2.0-70/scripts/rt-tester/t4-l2-pi-deboost.tst
/usr/src/linux-headers-3.2.0-70/scripts/rt-tester/t5-l4-pi-boost-deboost-setsche                         d.tst
/usr/src/linux-headers-3.2.0-70/scripts/rt-tester/t5-l4-pi-boost-deboost.tst
/usr/src/linux-headers-3.2.0-72/scripts/rt-tester/t4-l2-pi-deboost.tst
/usr/src/linux-headers-3.2.0-72/scripts/rt-tester/t5-l4-pi-boost-deboost-setsche                         d.tst
/usr/src/linux-headers-3.2.0-72/scripts/rt-tester/t5-l4-pi-boost-deboost.tst
/usr/src/linux-headers-3.2.0-73/scripts/rt-tester/t4-l2-pi-deboost.tst
/usr/src/linux-headers-3.2.0-73/scripts/rt-tester/t5-l4-pi-boost-deboost-setsche                         d.tst
/usr/src/linux-headers-3.2.0-73/scripts/rt-tester/t5-l4-pi-boost-deboost.tst
/usr/src/linux-headers-3.2.0-74/scripts/rt-tester/t4-l2-pi-deboost.tst
/usr/src/linux-headers-3.2.0-74/scripts/rt-tester/t5-l4-pi-boost-deboost-setsche                         d.tst
/usr/src/linux-headers-3.2.0-74/scripts/rt-tester/t5-l4-pi-boost-deboost.tst
/usr/src/linux-headers-3.2.0-75/scripts/rt-tester/t4-l2-pi-deboost.tst
/usr/src/linux-headers-3.2.0-75/scripts/rt-tester/t5-l4-pi-boost-deboost-setsche                         d.tst
/usr/src/linux-headers-3.2.0-75/scripts/rt-tester/t5-l4-pi-boost-deboost.tst
/var/lib/dpkg/info/libboost-iostreams1.46.1.list
/var/lib/dpkg/info/libboost-iostreams1.46.1.md5sums
/var/lib/dpkg/info/libboost-iostreams1.46.1.postinst
/var/lib/dpkg/info/libboost-iostreams1.46.1.postrm
/var/lib/dpkg/info/libboost-iostreams1.46.1.shlibs

Is this correct? Or are my locations messed up?
Forum donations: SVusZDRc8P1BjBRwrgdqYrJ4j5aY3gHFUg

elbandi

  • Jr. Member
  • **
  • Posts: 50
    • View Profile
Re: Step-by-step: Masternode on VPS
« Reply #53 on: February 02, 2015, 11:47:23 PM »
If I do a

Code: [Select]
dpkg -s libboost-dev | grep 'Version'
it tells me I have:

Code: [Select]
Version: 1.48.0.2
Oh, f*cking ubuntu... something is wrong on precise :(

http://packages.ubuntu.com/precise/libboost-dev depend on wrong package: libboost1.46-dev not libboost1.48-dev

You have to remove all 1.46 boost library/dev (old wrong package)
Code: [Select]
dpkg -l|grep 1.46
And install this: http://packages.ubuntu.com/precise/libboost1.48-all-dev

vertoe

  • Newbie
  • *
  • Posts: 33
  • Darkcoin Core Dev
    • View Profile
    • Darkco.in
Re: Step-by-step: Masternode on VPS
« Reply #54 on: February 03, 2015, 09:49:22 AM »
Just use arch linux and all the pain will go away :-)

edit, thanks myfarm & def15
SSHUvYeyGQcV6z1QvFiu2SppKDTbb2ZFC1

Mikolo

  • Newbie
  • *
  • Posts: 5
    • View Profile
Re: Step-by-step: Masternode on VPS
« Reply #55 on: February 09, 2015, 02:12:01 PM »
Assuming i'm storing coins in my local wallet and use masternode secret on VPS, will I need to keep my local computer running all the time?

GilAlexander

  • Newbie
  • *
  • Posts: 46
    • View Profile
Re: Step-by-step: Masternode on VPS
« Reply #56 on: February 09, 2015, 03:37:33 PM »
Assuming i'm storing coins in my local wallet and use masternode secret on VPS, will I need to keep my local computer running all the time?
No.
my spr addr: SVf1jyKHgdCngvpXf9SGQveiaFBFthmjVu

Strumpet!

  • Full Member
  • ***
  • Posts: 158
    • View Profile
Re: Step-by-step: Masternode on VPS
« Reply #57 on: February 09, 2015, 06:37:45 PM »
For anyone running a VPS or using the daemon locally, here's a quick little python script for building your spreadcoin.conf. Much faster than buggering about guessing output numbers for multiple Masternodes.

1. Place magic.py (cut and paste the code at the bottom of this post into a text file called magic.py) in your .spreadtest2coin directory of your local machine. If it isn't already, place your spreadcoind daemon in there too.

2. Use the QT client to cut and paste all your MN outputs into a text file "outputs.conf" in the .spreadtest2coin directory - no blank lines, just one output on each line.
3. Close the QT client.

4. On your local machine, make sure you have a basic spreadcoin.conf in your /home/user/.spreadtest2coin directory:
Code: [Select]
rpcuser=you
rcpassword=blah
rpcallowip=127.0.0.1
server=1
daemon=1

5. Start spreadcoind on your local machine
Code: [Select]
./spreadcoind

6. Unlock your wallet if required
Code: [Select]
./spreadcoind walletpassphrase <passphrase> 60

7. Run magic.py - it will run 'mnsecret' for all the outputs in your outputs.txt and add the correct 'mnstart=...' line to your spreadcoin.conf.
Code: [Select]
python magic.py

8. Copy the generated spreadcoin.conf to your VPS:
Code: [Select]
scp spreadcoin.conf [email protected]:/home/user/.spreadtest2coin

9. Restart spreadcoind on your VPS to start all your Masternodes.
Code: [Select]
./spreadcoind stop
./spreadcoind

magic.py:
Code: [Select]
#!/usr/bin/python

import sys, os, subprocess

def magic():
m = 'outputs.txt'
with open(m, mode="r") as f:
a = [line.strip() for line in f]
for line in a:
try:
cmd = './spreadcoind mnsecret ' + line
print cmd
r = subprocess.check_output(cmd, shell=True)
print r
with open("spreadcoin.conf", mode="a") as conf:
conf.write("mnstart=" + str(r))
except:
print 'Error! - check spreadcoind is running, you have rpcuser=blah and rpcpassword=blahblah lines in your spreadcoin.conf, your wallet is unlocked and the outputs in your outputs.txt are yours. You will also get this error if you have blank lines in your outputs.txt.'
sys.exit()

magic()

needmoney

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: Step-by-step: Masternode on VPS
« Reply #58 on: February 19, 2015, 07:12:28 PM »
Is there windows vps guide ?