Bitcoin Forum
April 26, 2024, 09:22:45 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: « 1 [2]  All
  Print  
Author Topic: del  (Read 6722 times)
GriphZero
Newbie
*
Offline Offline

Activity: 20
Merit: 0


View Profile
July 07, 2011, 02:40:44 PM
Last edit: July 10, 2011, 02:19:38 AM by GriphZero
 #21

Here are the changes I made to fix eligius.

Changed all references to "eligius-eu", to "eligius".

Changed:
my $url1='http://eligius.st/~luke-jr/raw/'.($pool_name eq "eligius-eu"?"eu":"us").'/blocks/';
  to
my $url1='http://eligius.st/~luke-jr/raw/5/blocks/';

And removed:
eligius_rewards("eligius-eu");

In pool.config set the eligius URL to:
http://eligius.st/~luke-jr/raw/5/blocks/

I also used a new utility function with a constant utility since eligius now uses SMPPS instead of proportional rewards.  It should be the default if all other pools have a lower utility.

These have worked for me.  The website shows what I have earned.

Warning though, they are changing their servers around, so the code may need to be updated with new server names in the near future.

Edit: New url for new server "5".
Transactions must be included in a block to be properly completed. When you send a transaction, it is broadcast to miners. Miners can then optionally include it in their next blocks. Miners will be more inclined to include your transaction if it has a higher transaction fee.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1714123365
Hero Member
*
Offline Offline

Posts: 1714123365

View Profile Personal Message (Offline)

Ignore
1714123365
Reply with quote  #2

1714123365
Report to moderator
gno
Newbie
*
Offline Offline

Activity: 28
Merit: 0


View Profile
July 07, 2011, 03:07:48 PM
Last edit: July 07, 2011, 06:11:50 PM by gno
 #22

I also used a new utility function with a constant utility since eligius now uses SMPPS instead of proportional rewards.  It should be the default if all other pools have a lower utility.


edit...

so a new function that just returns the same utility all the time? 

What number did you decide on?
Sukrim
Legendary
*
Offline Offline

Activity: 2618
Merit: 1006


View Profile
July 08, 2011, 02:37:27 AM
 #23

Eligius should in theory always be 1.0 (would be only different in the longer run if someone maliciously implements a withholding winning shares attack and has some massive hashrate there). Solo should be ~1.002, as transaction fees are ~0.2% of the 50 BTC currently on average. I guess that's neglectable though and you're probably currently better off with a SMPPS pool.

https://www.coinlend.org <-- automated lending at various exchanges.
https://www.bitfinex.com <-- Trade BTC for other currencies and vice versa.
organofcorti
Donator
Legendary
*
Offline Offline

Activity: 2058
Merit: 1007


Poor impulse control.


View Profile WWW
July 08, 2011, 02:48:41 AM
Last edit: July 08, 2011, 03:03:57 AM by organofcorti
 #24

Here are the changes I made to fix eligius.

Changed all references to "eligius-eu", to "eligius".

Changed:
my $url1='http://eligius.st/~luke-jr/raw/'.($pool_name eq "eligius-eu"?"eu":"us").'/blocks/';
  to
my $url1='http://eligius.st/~luke-jr/raw/3/blocks/';

And removed:
eligius_rewards("eligius-eu");

In pool.config set the eligius URL to:
http://eligius.st/~luke-jr/raw/3/blocks/

I also used a new utility function with a constant utility since eligius now uses SMPPS instead of proportional rewards.  It should be the default if all other pools have a lower utility.

These have worked for me.  The website shows what I have earned.

Warning though, they are changing their servers around, so the code may need to be updated with new server names in the near future.

So you didn't change the regexp to show results on the multipool summary? Ah well - that's what I was after. I really did want to see if eligius doesn't penalise or reward hoppers, there's been so much discussion about it.

Bitcoin network and pool analysis 12QxPHEuxDrs7mCyGSx1iVSozTwtquDB3r
follow @oocBlog for new post notifications
Sukrim
Legendary
*
Offline Offline

Activity: 2618
Merit: 1006


View Profile
July 08, 2011, 02:53:46 AM
 #25

Just read how their system works. The only "danger" is that after a lot of unlucky rounds users start to go away from the pool and it is left with a dept that will/can not be paid if noone's mining any more.

It would be nice to have an indicator on Eligius' page if the pool currently has earned more or less than expected (and also how much more/less) to be able to counter this threat, if necessary. I think that's about it though. You can hop in and out as much as you like, everyone should get paid fairly (eventually!).

https://www.coinlend.org <-- automated lending at various exchanges.
https://www.bitfinex.com <-- Trade BTC for other currencies and vice versa.
GriphZero
Newbie
*
Offline Offline

Activity: 20
Merit: 0


View Profile
July 08, 2011, 03:30:16 AM
Last edit: July 10, 2011, 02:20:56 AM by GriphZero
 #26

Sukrim gave a good summary.  Generally Eligius should have a a utility of 1.0 (unless they have had a series of long rounds and run out of credits, then they switch to proportional like most other pools.)  Oddly my Multipool stats pages gives them an efficiency of 0.826 based on four non-pending blocks.  It might be because of their server problems and upgrades.  

Eventually readily available pool hopping software like MultiPool should drive all pools to adopt similar scoring strategies to Eligius.  Before this, there was only a limited group of people doing pool hopping at the expense of everyone else.  This kind of software levels the playing field, and pushes the pools to improve their scoring systems.
GriphZero
Newbie
*
Offline Offline

Activity: 20
Merit: 0


View Profile
July 08, 2011, 04:18:37 AM
Last edit: July 08, 2011, 05:37:53 AM by GriphZero
 #27

I believe there is an error in the deepbit_rewards() subroutine, which is miscalculating the epoch, and corrupting the database.  I fixed this by removing "UTC" from that epoch conversion.  The DeepBit web site is using local time, not UTC.  This doesn't fix the corruption that already happened to the database, but should fix things going forward.
organofcorti
Donator
Legendary
*
Offline Offline

Activity: 2058
Merit: 1007


Poor impulse control.


View Profile WWW
July 08, 2011, 05:56:19 AM
 #28

Just read how their system works. The only "danger" is that after a lot of unlucky rounds users start to go away from the pool and it is left with a dept that will/can not be paid if noone's mining any more.

It would be nice to have an indicator on Eligius' page if the pool currently has earned more or less than expected (and also how much more/less) to be able to counter this threat, if necessary. I think that's about it though. You can hop in and out as much as you like, everyone should get paid fairly (eventually!).

I've read from when Luke-Jr started with max PPS, but I like chart porn, and I love it when you actually get a real world indication of an underlying algorithm, finding just how close results are to what theory says they should be. Sometimes there are subtle surprises you wouldn't think of when just running the system through in your mind - results of real world application are the gold standard. And I really want to see how close that is to reality.

Bitcoin network and pool analysis 12QxPHEuxDrs7mCyGSx1iVSozTwtquDB3r
follow @oocBlog for new post notifications
organofcorti
Donator
Legendary
*
Offline Offline

Activity: 2058
Merit: 1007


Poor impulse control.


View Profile WWW
July 08, 2011, 11:20:24 AM
 #29

I'm getting "error unable to communicate with bitcoind"

I made sure the config file for bitcoin has the same username and password as bitcoind.conf and it's set up as per the example above. Anyone else had this problem? I can't be the only one to have made whatever dumb misake I made.

Bitcoin network and pool analysis 12QxPHEuxDrs7mCyGSx1iVSozTwtquDB3r
follow @oocBlog for new post notifications
organofcorti
Donator
Legendary
*
Offline Offline

Activity: 2058
Merit: 1007


Poor impulse control.


View Profile WWW
July 09, 2011, 04:20:23 AM
 #30

I'm getting "error unable to communicate with bitcoind"

I made sure the config file for bitcoin has the same username and password as bitcoind.conf and it's set up as per the example above. Anyone else had this problem? I can't be the only one to have made whatever dumb misake I made.
check Multipool.PL code around line 35 make sure you have the config OK (bitcoind runs on local port etc etc)

Is this the line you meant?


my $longpoll=$production?"http://(space)multipool(to breake the url).hpc.tw:$longpoll_port/longpoll":"http://127.0.0.1:$longpoll_port/longpoll";

Bitcoin network and pool analysis 12QxPHEuxDrs7mCyGSx1iVSozTwtquDB3r
follow @oocBlog for new post notifications
organofcorti
Donator
Legendary
*
Offline Offline

Activity: 2058
Merit: 1007


Poor impulse control.


View Profile WWW
July 09, 2011, 09:03:01 AM
 #31

I checked bitcoin.conf, bitcoind.conf, accounts conf - all correct but I still get the "unable to communicate with bitcoind" and wont run. Is bitcoind for solo? Is there some way just to run it locally without solo so I don't get this error?

Bitcoin network and pool analysis 12QxPHEuxDrs7mCyGSx1iVSozTwtquDB3r
follow @oocBlog for new post notifications
organofcorti
Donator
Legendary
*
Offline Offline

Activity: 2058
Merit: 1007


Poor impulse control.


View Profile WWW
July 09, 2011, 10:16:32 AM
 #32

Is bitcoind for solo?
yes(aka running your own pool)
Is there some way just to run it locally without solo so I don't get this error?
you must run solo

Originally Multipool didn't have solo, he only added it to give miners a fallback. Eligius is a better 1.0 fallback now. Why is solo still required? bitcoind is the only thing preventing me from getting this working.

Bitcoin network and pool analysis 12QxPHEuxDrs7mCyGSx1iVSozTwtquDB3r
follow @oocBlog for new post notifications
organofcorti
Donator
Legendary
*
Offline Offline

Activity: 2058
Merit: 1007


Poor impulse control.


View Profile WWW
July 09, 2011, 10:50:50 AM
 #33

still no go.

Bitcoin network and pool analysis 12QxPHEuxDrs7mCyGSx1iVSozTwtquDB3r
follow @oocBlog for new post notifications
GriphZero
Newbie
*
Offline Offline

Activity: 20
Merit: 0


View Profile
July 09, 2011, 02:40:04 PM
Last edit: July 09, 2011, 03:02:14 PM by GriphZero
 #34

still no go.

It is might be a problem between your miner and bitcoind.  Try just mining solo with your miner and see if that works.  Make sure bitcoind is in server mode.
GriphZero
Newbie
*
Offline Offline

Activity: 20
Merit: 0


View Profile
July 09, 2011, 03:01:52 PM
Last edit: July 09, 2011, 09:29:29 PM by GriphZero
 #35

Here is code for a bitcoinslc_rewards() subroutine.  I've been running it for two days on my local multipool to check the functionality.  It seems to get completed shares successfully, but shares don't exactly lineup correctly with the correct completed blocks.  This is somewhat the intended functionality of multipool where it assigns the rewards to the closest block by time.  Unfortunately the times in the database for completed blocks and the times on the Bitcoins.lc website don't line up exactly, so the block numbering is a bit off.  Running it modifies the database with the completed rewards, so be careful, and check it out first without sending multipool work from your miner.  See if you like how the rewards function is working.  If you don't like it, remove the call to bitcoinslc_rewards(), and reload from your previous datafile.

I'm not a perl programmer, and I mainly just copied the code from other rewards subroutines, and received some help from other forum members on the parsing.  Thanks!  If anyone comes up with an improved version, please post it.  Better yet would be if MultiPool himself/herself or someone else could setup a git repository that could be contributed to.

See updated code below. V
GriphZero
Newbie
*
Offline Offline

Activity: 20
Merit: 0


View Profile
July 09, 2011, 09:22:28 PM
 #36

Wouldn't you know it.  Bitcoins.lc just change their authentication, preventing the rewards subroutine from logging in.   The two lines with "_csrf_protect_token" need to change to "_csrf_token" to fix this.  If they change it again,  look at the login page's source and pick out the new token name, from the login section.

Here is the code again with the changes.
Code:
sub bitcoinslc_rewards {
    print "parsing bitcoin.lc rewards\n";
    my $url1='https://www.bitcoins.lc/';
    my $url2='https://www.bitcoins.lc/transactions';
    my $pool=$pools{"bitcoins-lc"};
    $pool->{rounds_time}=shared_clone({}) unless $pool->{rounds_time};

    foreach my $account (values %{$accounts{"bitcoins-lc"}}) {
$_=wget($url1, "--keep-session-cookies --save-cookie bitcoins-lc-cookie.txt");
if (!$_){
    print "error: unable to fetch bitcoins-lc login page $url1\n";
    return;
}
m{.* name="_csrf_token" value="(\w.*)"};
my $token=$1;
my $ok=($token=~/^[a-z0-9]+$/);

if ($ok){
    $_=wget($url1, "'--post-data=_csrf_token=$token&action=login&email=$account->{web_user}&password=$account->{web_pass}&login=Proceed'", "--load-cookies bitcoins-lc-cookie.txt", "--keep-session-cookies --save-cookie bitcoins-lc-cookie2.txt");
    $ok=!!$_;
}
if ($ok){
    $_=wget($url2, "--load-cookies bitcoins-lc-cookie2.txt");
    $ok=!!$_;
}

my @lines;
if ($ok){
    @lines=split/\n/;
    $ok=@lines; # puts the number of lines in $ok
}
if (!$ok){
    print "error: cannot login into/parse stats page for bitcoin-lc using account $account->{name}\n";
    return;
}
@lines = grep { /Your Transactions/ .. /div id="rightcol"/ } @lines;
if (!@lines) {
   print "error: no lines matched between Your Transactions and div id=rightcol; code needs changed!\n";
   return;
}

my @new_rounds;
my $blockid = 0;
my $date;
my $shares = 0;
my $reward = 0;
my $epoch = 0;

foreach (@lines){
    if (/Received Block (\d+)<span> - (.*)<\/span>/) {
$blockid = $1;
$date = $2;
$date =~ s/ (\d\d?) (...) / $2 $1 /;
$epoch=qx(date -d '$date' +%s); chomp $epoch;
    }
    if (/Based upon (\d+) valid shares/) {
$shares = $1;
next if (!$blockid);
    }
    if (/<p class="amount">\+([\d.]+)/) {
$reward = $1;
if ($blockid) {
    #print "Debug: block $blockid, date '$date', epoch '$epoch', shares $shares, amount $reward\n";
    $ok=($blockid=~/^[a-z0-9]+$/ and $reward=~/^\d+\.\d+$/ and $epoch=~/^\d+$/ and $shares=~/^\d+$/);

    if (!$ok){
print "error parsing stats page for bitcoins-lc using account $account->{name}: line=$_\n";
foreach my $round (@new_rounds){
    delete $account->{rounds}->{$round};
}
return;
    }

    my $round=$pool->{rounds_time}->{$epoch};
    if (!$round){
$round=guess_round($epoch, $pool, $epoch);
next if !$round;
$pool->{rounds}->{$round}=shared_clone({time => $epoch, shares => $shares});
$pool->{rounds_time}->{$epoch} = $round;
    }
    if (!$account->{rounds}->{$round}){
$account->{rounds}->{$round}=shared_clone({earned => $reward, shares_web => $shares});
push @new_rounds, $round;
    }    

    # Then reset data
    $blockid = $shares = $reward = $epoch = 0;
    $date = "";
} else {
    next;
}
    }
    last if (/Recent Transactions/);
}
consolidate_rounds($account, @new_rounds);
    }
}
organofcorti
Donator
Legendary
*
Offline Offline

Activity: 2058
Merit: 1007


Poor impulse control.


View Profile WWW
July 11, 2011, 05:49:07 AM
 #37

There's a lot of great stuff here. In the interests of saving time for everyone, would those of you who have updated code be interested in starting a fresh Multipool fork on github?

Bitcoin network and pool analysis 12QxPHEuxDrs7mCyGSx1iVSozTwtquDB3r
follow @oocBlog for new post notifications
Disposition
Full Member
***
Offline Offline

Activity: 121
Merit: 100


View Profile
July 21, 2011, 09:20:08 PM
 #38

There's a lot of great stuff here. In the interests of saving time for everyone, would those of you who have updated code be interested in starting a fresh Multipool fork on github?

Yeah.. bitHopper isn't really suiting my needs considering I have a bunch of workers I need to track individually, I'll put a bounty as well as make a fork this weekend.
Pages: « 1 [2]  All
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!