Bitcoin Forum
October 23, 2017, 03:05:54 AM *
News: Latest stable version of Bitcoin Core: 0.15.0.1  [Torrent]. (New!)
 
   Home   Help Search Donate Login Register  
Pages: « 1 2 3 4 5 6 7 [8] 9 10 »  All
  Print  
Author Topic: Finding p2pool networks.py values for new altcoins  (Read 36932 times)
CartmanSPC
Legendary
*
Offline Offline

Activity: 1258



View Profile WWW
February 07, 2014, 11:21:47 PM
 #141

For SPREAD I use the following formula:

SPREAD=
600/[block time]=x
x*3=spread


Not saying that it is right but it's what I use.

Code:
bitcoin SPREAD=3 block every 600 seconds         Baseline
litecoin SPREAD=12 block every 150 seconds       600/150=4       4x3=12
bbqcoin SPREAD=30 block every 60 seconds         600/60=10       10x3=30
casinocoin SPREAD=60 block every 30 seconds      600/30=20       20x3=60
digitalcoin SPREAD=90 block every 20 seconds     600/20=30       30x3=90  (old spec)
digitalcoin SPREAD=45 block every 40 seconds     600/40=15       15x3=45  (new spec)
worldcoin SPREAD=120 block every 15 seconds      600/15=40       40x3=120 (old spec)
worldcoin SPREAD=60 block every 30 seconds       600/30=20       20x3=60  (new spec)
globalcoin SPREAD=45 block every 40 seconds      600/40=15       15x3=45
dogecoin SPREAD=30 block every 60 seconds        600/60=10       10x3=30
potcoin SPREAD=45 block every 40 seconds         600/40=15       15x3=45
craftcoin SPREAD=6 block every 300 seconds       600/300=2        2x3=6  (old spec)
craftcoin SPREAD=30 block every 60 seconds       600/60=10       10x3=30 (new spec)

1508727954
Hero Member
*
Offline Offline

Posts: 1508727954

View Profile Personal Message (Offline)

Ignore
1508727954
Reply with quote  #2

1508727954
Report to moderator
1508727954
Hero Member
*
Offline Offline

Posts: 1508727954

View Profile Personal Message (Offline)

Ignore
1508727954
Reply with quote  #2

1508727954
Report to moderator
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1508727954
Hero Member
*
Offline Offline

Posts: 1508727954

View Profile Personal Message (Offline)

Ignore
1508727954
Reply with quote  #2

1508727954
Report to moderator
roy7
Sr. Member
****
Offline Offline

Activity: 434


View Profile
February 07, 2014, 11:23:41 PM
 #142

Sadly when we did the first vertcoin nodes, we used spread=3 because we just copied litecoin. It really should have been 12-15... would avoid so much confusion for small miners right now. Doh.

RoyalMiningCo: Pools retired. Was fun!
mmouse
Full Member
***
Offline Offline

Activity: 182


View Profile
February 08, 2014, 03:52:00 AM
 #143

Sadly when we did the first vertcoin nodes, we used spread=3 because we just copied litecoin. It really should have been 12-15... would avoid so much confusion for small miners right now. Doh.

You can lower your share difficulty by appending /diff to your p2pool username. That should generate more shares and more regular payouts, but of course you get paid less per share. I'm trying
Code:
VTCPayoutAddress+0.001465/0.55
at the moment. I can tell tomorrow, if this makes things better or worse...
roy7
Sr. Member
****
Offline Offline

Activity: 434


View Profile
February 08, 2014, 03:54:02 AM
 #144

You can lower your share difficulty by appending /diff to your p2pool username. That should generate more shares and more regular payouts, but of course you get paid less per share. I'm trying
Code:
VTCPayoutAddress+0.001465/0.55
at the moment. I can tell tomorrow, if this makes things better or worse...

address/diff won't let you set diff below the minimum share diff for the pool though. It's intended more to raise diff for giant miners than to lower diff, I thought?

RoyalMiningCo: Pools retired. Was fun!
mmouse
Full Member
***
Offline Offline

Activity: 182


View Profile
February 08, 2014, 04:42:31 PM
 #145

You can lower your share difficulty by appending /diff to your p2pool username. That should generate more shares and more regular payouts, but of course you get paid less per share. I'm trying
Code:
VTCPayoutAddress+0.001465/0.55
at the moment. I can tell tomorrow, if this makes things better or worse...

address/diff won't let you set diff below the minimum share diff for the pool though. It's intended more to raise diff for giant miners than to lower diff, I thought?

First, I've to admit that I'm not completely sure about how p2pool handle diffs and so on, just my own code reading + try and error.

That said, pool minimum share diff (what you get e.g. with http://vtc.coinpools.de:9171/difficulty) is not what p2pool gives out to your miner as share difficulty (main reason, why the "share difficulty" displayed on the standard web client page is nonsense). p2pool uses a quite complicated algorithm to compute pseudo_share_difficulty (work.py lines 265-) and share_difficulty (data.py lines 111-) specifically for your miner client (see debug.log "New work for worker" entries).

IMHO the main problem with this is, that p2pool tries to dish out share difficulties so that it expects no more than one solved share per minute from all connected clients. So as my VTC node has about 6 MH/s local rate at the moment, the log shows a standard share difficulty of 1.39 given to clients. Minimum share difficulty for the pool is 0.063 on the other hand. So it seems perfectly legit to specify a custom share difficulty of 0.55 for my miner. (If you specify it too low, p2pool seems to use the minimum pool difficulty anyway).

Quote
I can tell tomorrow, if this makes things better or worse...

Did work perfectly for me during the last 12 hours, by the way Wink

roy7
Sr. Member
****
Offline Offline

Activity: 434


View Profile
February 08, 2014, 06:37:22 PM
 #146

Hmmm. Even if I try to set /.00001 I can't see it changing anything on my miner's end. Using + of course submits diff 1 pseudo-shares constantly which is a waste of resources.

Looking at all of the New Work messages, they aren't all being set to the same difficulty. On my pool most are set to 0.00244 but one is .000812 and one is .000244. I assume those are the pseduo share difficulties and the tiny ones are the two slowest miners in pool?

Because yes, there is also the "Share difficulty: 1.918" which is going to all but 2 miners. One is me with my /.000001 forcing it down to match share difficulty. That other must be you or someone like you, setting a lower share difficulty with ADDR/ which means you'll actually have reduced variance since the difficulty chosen is still over the minimum.

Is it really 1 share total from all miners combined, or 1 share per minute from each miner individually? The latter would make more sense to me, but I'm thinking of it from a "running a pool-like public node" perspective. p2pool is designed from a "run it as a reduced variance solo mining operation" perspective.

RoyalMiningCo: Pools retired. Was fun!
roy7
Sr. Member
****
Offline Offline

Activity: 434


View Profile
February 08, 2014, 06:44:41 PM
 #147

IMHO the main problem with this is, that p2pool tries to dish out share difficulties so that it expects no more than one solved share per minute from all connected clients. So as my VTC node has about 6 MH/s local rate at the moment, the log shows a standard share difficulty of 1.39 given to clients. Minimum share difficulty for the pool is 0.063 on the other hand. So it seems perfectly legit to specify a custom share difficulty of 0.55 for my miner. (If you specify it too low, p2pool seems to use the minimum pool difficulty anyway).

Interesting. I kept assuming small miner variance was due to large share difficulty but that's not the case at all for VTC right now, if you are a small miner using a big public node.

2014-02-08 18:41:03.086159 New work for worker! Difficulty: 0.001676 Share difficulty: 1.505790
2014-02-08 18:41:03.287006 New work for worker! Difficulty: 0.001676 Share difficulty: 0.058060

I have a couple dozen lines similar to the first. The 2nd is my testing with difficultly forced as low as it can go. Being a single GPU miner, 1.5 (98683) will take me far far longer to get 1 share than .058 (3805) would.

Edit: Apologies for the thread hijack. mmouse we should move this to the P2Pool main thread or to the VTC thread.

RoyalMiningCo: Pools retired. Was fun!
tvb
Jr. Member
*
Offline Offline

Activity: 38


View Profile
February 09, 2014, 10:00:05 AM
 #148

SUBSIDY_FUNC = <X>*<TOTAL COINS>
<X> pulled from ./src/main.cpp (search for "nSubsidy")
<TOTAL COINS> total number of minable coins.

I believe this is incorrect. I think the correct way is:

for litecoin:
SUBSIDY_FUNC=lambda height: 50*100000000 >> (height + 1)//840000,
SUBSIDY_FUNC=lambda height: 'block reward' * 'satoshies' >> (height + 1)//'height where block halves'.

If there is no "halfing" you take out the >> (height + 1)//'height where block halves'

//840000 is the number from main.cpp in nSubsidy -> nSubsidy >>= (nHeight /

Thank you! I have updated my post to reflect your corrections.

DGB D6caUG54gxgwqWhws3fnuugeEDtFZiX1DD
CartmanSPC
Legendary
*
Offline Offline

Activity: 1258



View Profile WWW
February 10, 2014, 03:14:06 AM
 #149

Started a new thread detailing the values. Work in progress. Will update as time allows:

https://bitcointalk.org/index.php?topic=457574.0

primeblock
Newbie
*
Offline Offline

Activity: 29


View Profile
February 14, 2014, 02:29:41 PM
 #150

Thank you all for this useful thread!

But I found if use p2pool setup by myself the HW error is very high from the output of CGMiner.

I can say I have seen this several times myself, unfortunately not 100% sure the cause of it quite yet and has not happened everytime so have not found the pattern yet.
roy7
Sr. Member
****
Offline Offline

Activity: 434


View Profile
February 14, 2014, 02:57:22 PM
 #151

Thank you all for this useful thread!

But I found if use p2pool setup by myself the HW error is very high from the output of CGMiner.

I can say I have seen this several times myself, unfortunately not 100% sure the cause of it quite yet and has not happened everytime so have not found the pattern yet.

Someone say getting work with 0 diff causes errors but I have no idea if it is HW errors or something else. Try connecting to your node with /.00001+.00001 if you use a scrypt based coin. (/1+1 if a SHA based coin). That will make sure you never get anything below 1 diff.

RoyalMiningCo: Pools retired. Was fun!
CartmanSPC
Legendary
*
Offline Offline

Activity: 1258



View Profile WWW
February 14, 2014, 07:38:18 PM
 #152

Thank you all for this useful thread!

But I found if use p2pool setup by myself the HW error is very high from the output of CGMiner.

I can say I have seen this several times myself, unfortunately not 100% sure the cause of it quite yet and has not happened everytime so have not found the pattern yet.

Have seen this happen on the first miner to join a node. I forget the exact message but also notice something like "unidentified stratum" in the console when this happens.

Simple quick fix (for me) is to restart the miner.

SuperSta
Full Member
***
Offline Offline

Activity: 154


View Profile
February 25, 2014, 07:56:47 PM
 #153

Q1) Can someone let me know how to get the Prefix and the Identifier for a new coin? (specifically litebar)

Q2) I have done the settings (except for prefix and identifier) to the best of my ability with the aid of this thread for Litebar network.py in both P2Pool locations. Can some bright spark actually post the correct settings for Litebar please. I have spent 12 hours trying figuring it out and could use any help.

Code:
   litebar=math.Object(
        PARENT=networks.nets['litebar'],
        SHARE_PERIOD=15,
        CHAIN_LENGTH=24*60*60//10,
        REAL_CHAIN_LENGTH=24*60*60//10,
        TARGET_LOOKBEHIND=200,
        SPREAD=10,
        IDENTIFIER=''.decode('hex'),
        PREFIX=''.decode('hex'),
        P2P_PORT=19065,
        MIN_TARGET=0,
        MAX_TARGET=2**256//2**20 - 1,
        PERSIST=true,
        WORKER_PORT=19055,
        BOOTSTRAP_ADDRS=''.split(' '),
        ANNOUNCE_CHANNEL='',
        VERSION_CHECK=lambda v: True,

    ),

 


    litebar=math.Object(
        P2P_PREFIX='fbc0b6db'.decode('hex'),
        P2P_PORT=9065,
        ADDRESS_VERSION=48,
        RPC_PORT=9055,
        RPC_CHECK=defer.inlineCallbacks(lambda bitcoind: defer.returnValue(
            'litebaraddress' in (yield bitcoind.rpc_help()) and
            not (yield bitcoind.rpc_getinfo())['testnet']
        )),
        SUBSIDY_FUNC=lambda height: 2*100000000 >> (height + 1)//438000,
        POW_FUNC=lambda data: pack.IntType(256).unpack(__import__('ltc_scrypt').getPoWHash(data)),
        BLOCK_PERIOD=180,
        SYMBOL='LTB',
        CONF_FILE_FUNC=lambda: os.path.join(os.path.join(os.environ['APPDATA'], 'litebar') if platform.system() == 'Windows' else os.path.expanduser('~/Library/Application Support/litebar/') if platform.system() == 'Darwin' else os.path.expanduser('~/.litebar'), 'litebar.conf'),
        BLOCK_EXPLORER_URL_PREFIX='',
        ADDRESS_EXPLORER_URL_PREFIX='',
        TX_EXPLORER_URL_PREFIX='',
        SANE_TARGET_RANGE=(2**256//1000000000 - 1, 2**256//1000 - 1),
        DUMB_SCRYPT_DIFF=2**16,
DUMB_SCRYPT_DIFF=0.03e8,
    ),

I know some of these settings are ball park figures, and some of these setting might be completely wrong. Any help would be appreciated. Thanks
CartmanSPC
Legendary
*
Offline Offline

Activity: 1258



View Profile WWW
February 25, 2014, 10:51:29 PM
 #154

Q1) Can someone let me know how to get the Prefix and the Identifier for a new coin? (specifically litebar)

Added it to my guide..it is also here earlier in this thread.

SuperSta
Full Member
***
Offline Offline

Activity: 154


View Profile
February 26, 2014, 12:33:08 AM
 #155

Q1) Can someone let me know how to get the Prefix and the Identifier for a new coin? (specifically litebar)

Added it to my guide..it is also here earlier in this thread.

Thank you for that!

This is what happens when I run it - I get all Succcesses at the top but then I get this repeatedly:

2014-02-25 19:31:06.817362 P2Pool: 0 shares in chain (0 verified/0 total) Peers: 0 (0 incoming)
2014-02-25 19:31:06.817451  Local: 0H/s in last 0.0 seconds Local dead on arrival: Huh Expected time to share: Huh


Any ideas?

EDIT: Its works I think, I just pointed my miner at it. I'm getting a bunch of HW issues but I'll sort that out.

When I tried starting a Litecoin p2pool earlier I wasnt getting the above messages that I am getting with Litebar. Not sure why.
SuperSta
Full Member
***
Offline Offline

Activity: 154


View Profile
February 26, 2014, 01:19:49 AM
 #156

Q1) Can someone let me know how to get the Prefix and the Identifier for a new coin? (specifically litebar)

Added it to my guide..it is also here earlier in this thread.

Thank you for that!

This is what happens when I run it - I get all Succcesses at the top but then I get this repeatedly:

2014-02-25 19:31:06.817362 P2Pool: 0 shares in chain (0 verified/0 total) Peers: 0 (0 incoming)
2014-02-25 19:31:06.817451  Local: 0H/s in last 0.0 seconds Local dead on arrival: Huh Expected time to share: Huh


Any ideas?

EDIT: Its works I think, I just pointed my miner at it. I'm getting a bunch of HW issues but I'll sort that out.

When I tried starting a Litecoin p2pool earlier I wasnt getting the above messages that I am getting with Litebar. Not sure why.

Right I have this kinda working, finally.

I was getting a bunch of hardware issues until I put +16 after my username in my cgminer conf file. However I dont think this is the permanent solution. I think its a setting on the server that needs to be corrected to may be allocate the difficulty better. I think its one (or more) of the settings to do with ~/P2Pool/P2Pool/Network.py

I will tweak them, however if anyone has any ideas on which ones I should be fiddling around with, please let me know.

Muchos gracias amigos.

UPDATE: This is it: New Litebar P2Pool: http://lifeforce.info:24323 - To add to your collection! Use as your main or as a back up - VPS Hosted - London Based - Fee: 0.5% Going to do some more tweaking first.
roy7
Sr. Member
****
Offline Offline

Activity: 434


View Profile
February 26, 2014, 01:26:49 PM
 #157

When you first connect to a new node and there are no stats at all you will get served DIFF 0 work which will cause HWs in some types of miners. If you mine for a while with any + it will get some stats stored, then you can disconnect and reconnect without the + and you should be fine, with vardiff giving you pseudoshare targets above 0. I just put in a suggestion to the p2pool repo that the minimum work ever served should be 1 (for sha256) or 1/X where X is the scrypt adjustment to the difficulty figure for that coin (it's in bitcoin/networks.py).

RoyalMiningCo: Pools retired. Was fun!
CartmanSPC
Legendary
*
Offline Offline

Activity: 1258



View Profile WWW
February 26, 2014, 06:54:33 PM
 #158

When you first connect to a new node and there are no stats at all you will get served DIFF 0 work which will cause HWs in some types of miners. If you mine for a while with any + it will get some stats stored, then you can disconnect and reconnect without the + and you should be fine, with vardiff giving you pseudoshare targets above 0. I just put in a suggestion to the p2pool repo that the minimum work ever served should be 1 (for sha256) or 1/X where X is the scrypt adjustment to the difficulty figure for that coin (it's in bitcoin/networks.py).

I just immediately reconnect when that happens. Have not had to use + anything but then again I have 5 Mh/s so it may be adjusting higher faster for me so when I reconnect the pseudo diff is already primed to be higher.

roy7
Sr. Member
****
Offline Offline

Activity: 434


View Profile
February 26, 2014, 06:57:36 PM
 #159

I just immediately reconnect when that happens. Have not had to use + anything but then again I have 5 Mh/s so it may be adjusting higher faster for me so when I reconnect the pseudo diff is already primed to be higher.

The danger is like the guy who replied here

https://github.com/forrestv/p2pool/issues/183

You probably recognize him from irc. Smiley If he falls over to a backup pool then much later back to his own node, it might do nothing but HWs all day until he can manually fix it because of the 0 diff issue.

RoyalMiningCo: Pools retired. Was fun!
CartmanSPC
Legendary
*
Offline Offline

Activity: 1258



View Profile WWW
February 27, 2014, 07:10:15 PM
 #160

I just immediately reconnect when that happens. Have not had to use + anything but then again I have 5 Mh/s so it may be adjusting higher faster for me so when I reconnect the pseudo diff is already primed to be higher.

The danger is like the guy who replied here

https://github.com/forrestv/p2pool/issues/183

You probably recognize him from irc. Smiley If he falls over to a backup pool then much later back to his own node, it might do nothing but HWs all day until he can manually fix it because of the 0 diff issue.
Yes, that is a problem  Undecided
Perhaps using cgwatcher can help. Not sure (haven't looked) but it may have a setting to watch for # of HW errors and restart the miner. If not then maybe we can make a feature suggestion.

Pages: « 1 2 3 4 5 6 7 [8] 9 10 »  All
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!