elective-stereophonic
elective-stereophonic
Software to manage a leasing pool singapore
Please login or register.

Login with username, password and session length
Advanced search  

News:

Latest Stable Nxt Client: Nxt 1.12.2

Author Topic: Software to manage a leasing pool  (Read 3545 times)

forkedchain

  • Ex-Staff Member
  • Hero Member
  • *****
  • Karma: +74/-10
  • Offline Offline
  • Posts: 1190
  • bite me
    • View Profile
Software to manage a leasing pool
« on: June 08, 2014, 02:25:10 am »

Sorry, but this is really not for beginners, will required detailed knowledge of using LAMP as this requires a LAMP stack, not a regular VPS.  Unless you know how to install all the required additional libraries required to get PHP/MYSQL/PERL all working INTEGRATED, then just buy a lamp stack VPS.  Do not email or IM me for help.  Ask all questions in this forum category.

http://pool.nxtcrypto.org/lfp.tgz

1. use text editor on the .sql file and search for <POOLACCOUNT> and <POOLSECRET> and replace these with your pool's info

2. import this .sql file into mysql

3. NEVERMIND

4. modify all .php files at the very top to use your MYSQL account/password (PHP scripts dont need write access to DB though, and you may not even want to give php scripts access to nxtAcct table as it contains secrets.)

5. modify both perl files at the very top to use your mysql account/password.  Both perl scripts need full access to DB

6. edit nxt.properties to trace your pools account#, and to use a comma as field separator, not the default separator, and to put the file in the same directory as the perl scripts.

7. restart nxt, wait until it syncs the chain

8. update lastProcessedBlock and lastProcessedHeight in nxtInfo where entry = 0 to make them be 1 block before your pool's first forged block.

9. make sure your pool's account has NXT in it, because the next step will start processing blocks up to 1440 blocks before the last block on the chain, and will payout if an inbound AM comes in (remember an inbound AM will trigger a payout to the sender, if there is a balance).  If you dont want this, then in step 8 use a later block/height such that there are no inbound AM requests after that.

10. run the confirmedBlocks.pl script.  this may take a looong time, depending on how far back your first forged block was.  open another terminal and you can select on the nxtInfo table to see how far you have to go to reach 1440 before last block.

11.  when this is done run it again and again until it completes as soon as you hit enter.

12.  then run recentBlocks.pl  this script always takes awhile as it always processes 1440 blocks past whatever block confirmedBlocks finished on.

13.  cron both of these for once per minute

14.  post in here so we can all see your success!


modifications to above:

some of the instructions up top are a bit different as Ive deleted all rows of the database before exporting the .sql file, so you'll have to use mysql to put some rows in first, with "entry = 0".  the nxtInfo table and the nxtInfo table will need to have rows put in with entry = 0.  just manually set the nrsVer field for the RTnxtInfo table.  and nxtInfo will need all fields seeded except for the "numForgedBlocks" and "poolEarnings fields which are automatically updated.

Also, in nxtInfo, for row entry=0, you still have to manually seed the 2 fields  lastProcessedBlock  and lastProcessedHeight which tells the software where to start processing blocks.  use values from the block before your very first forged block that you want to account for for these 2 fields.  the software will take over and auto update it after that.

and in table nxtInfo you also have to seed entry=0, account, and secret in nxtAcct with your nxt accountID (numberic, not RS) and the account's secret.

all .php files and .pl files will need to have the sql info put into them in the variables up top.  perl scripts use the readwrite sql user and pass and php scripts use the readonly credentials.
« Last Edit: October 17, 2014, 06:26:36 pm by forkedchain »
Logged
NXT tips: 2319251 or NXT-8SWM-2224-YKWW-22222

Brangdon

  • Hero Member
  • *****
  • Karma: +229/-25
  • Offline Offline
  • Posts: 1389
  • Quality is addictive.
    • View Profile
Re: Software to manage a leasing pool
« Reply #1 on: June 08, 2014, 01:03:36 pm »

Thanks for making this public.
Logged

Daedelus

  • Hero Member
  • *****
  • Karma: +230/-12
  • Offline Offline
  • Posts: 3280
    • View Profile
Re: Software to manage a leasing pool
« Reply #2 on: June 09, 2014, 07:53:22 am »

Do you think a dumbdumb version of this is doable eventually or is it just too techy?
Logged
NXT: NXT-4CS7-S4N5-PTH5-A8R2Q

forkedchain

  • Ex-Staff Member
  • Hero Member
  • *****
  • Karma: +74/-10
  • Offline Offline
  • Posts: 1190
  • bite me
    • View Profile
Re: Software to manage a leasing pool
« Reply #3 on: June 11, 2014, 06:56:03 pm »

well what I typed was the dumdum version... You will need to understand how to use a text editor, mysql, and set up apache.

I wish someone would do this, I have a bounty riding on it.  I will be willing to help out.  Realize that once you get this powerful software running, it WILL give legitimacy to your site, and you will get lessors.
Logged
NXT tips: 2319251 or NXT-8SWM-2224-YKWW-22222

Come-from-Beyond

  • Hero Member
  • *****
  • Karma: +794/-671
  • Offline Offline
  • Posts: 4013
    • View Profile
Re: Software to manage a leasing pool
« Reply #4 on: June 14, 2014, 12:26:23 pm »

Pool software made by ForkedChain... Original marketing trick!
Logged

joefox

  • Hero Member
  • *****
  • Karma: +62/-1
  • Offline Offline
  • Posts: 522
    • View Profile
    • The Nxt Wiki
Re: Software to manage a leasing pool
« Reply #5 on: June 14, 2014, 04:45:07 pm »

Thanks for posting that, forkedchain!  Just enough detail for a reasonably technical person to follow; but more importantly, the spirit of open sharing you demonstrate is exemplary.
Logged
GPG Key Id: 0x94A521DA613CAE76 | BitMessage BM-NBzUURL9jLagPALxCpxYDaMVe9E3965u
Nxt Wiki: http://wiki.nxtcrypto.org/
Tips: NXT-DBDW-STA8-ARBE-6JRPA

CRServers

  • Jr. Member
  • **
  • Karma: +7/-1
  • Offline Offline
  • Posts: 39
    • View Profile
    • CRServers Internet Hosting Services
Re: Software to manage a leasing pool
« Reply #6 on: September 29, 2014, 05:20:02 pm »

http://vps2.nxtcrypto.org/pool.tgz

There is no response from vps2.nxtcrypto.org (37.139.14.27)

Code: [Select]
ping 37.139.14.27
PING 37.139.14.27 (37.139.14.27) 56(84) bytes of data.
^C
--- 37.139.14.27 ping statistics ---
80 packets transmitted, 0 received, 100% packet loss, time 79179ms

Is there an alternative place when we can download the software?
Thanks,

Rodrigo
Logged
CRServers
Internet Hosting Services in Costa Rica

forkedchain

  • Ex-Staff Member
  • Hero Member
  • *****
  • Karma: +74/-10
  • Offline Offline
  • Posts: 1190
  • bite me
    • View Profile
Re: Software to manage a leasing pool
« Reply #7 on: October 17, 2014, 04:47:29 pm »

ah, sorry, ill need to wrap it up and post it on the pool server some time for you.  when do you think you will be able to get it all running?  how good are you with LAMP?
Logged
NXT tips: 2319251 or NXT-8SWM-2224-YKWW-22222

CRServers

  • Jr. Member
  • **
  • Karma: +7/-1
  • Offline Offline
  • Posts: 39
    • View Profile
    • CRServers Internet Hosting Services
Re: Software to manage a leasing pool
« Reply #8 on: October 17, 2014, 05:08:16 pm »

LAMP is no problem
Let me know when it's ready.
Thanks,

Rodrigo
Logged
CRServers
Internet Hosting Services in Costa Rica

forkedchain

  • Ex-Staff Member
  • Hero Member
  • *****
  • Karma: +74/-10
  • Offline Offline
  • Posts: 1190
  • bite me
    • View Profile
Re: Software to manage a leasing pool
« Reply #9 on: October 17, 2014, 06:24:32 pm »

http://pool.nxtcrypto.org/lfp.tgz

some of the instructions up top are a bit different as Ive deleted all rows of the database before exporting the .sql file, so you'll have to use mysql to put some rows in first, with "entry = 0".  the nxtInfo table and the nxtInfo table will need to have rows put in with entry = 0.  just manually set the nrsVer field for the RTnxtInfo table.  and nxtInfo will need all fields seeded execpt for the "numForgedBlocks" and "poolEarnings fields which are automatically updated.

Also, in nxtInfo, for row entry=0, you still have to manually seed the 2 fields  lastProcessedBlock  and lastProcessedHeight which tells the software where to start processing blocks.  use values from the block before your very first forged block that you want to account for for these 2 fields.  the software will take over and auto update it after that.

and in table nxtInfo you also have to seed entry=0, account, and secret in nxtAcct with your nxt accountID (numberic, not RS) and the account's secret.

all .php files and .pl files will need to have the sql info put into them in the variables up top.  perl scripts use the readwrite sql user and pass and php scripts use the readonly credentials.
« Last Edit: October 17, 2014, 06:26:51 pm by forkedchain »
Logged
NXT tips: 2319251 or NXT-8SWM-2224-YKWW-22222
 

elective-stereophonic
elective-stereophonic
assembly
assembly