Bitcoin Forum

Economy => Services => Topic started by: nicehash on October 22, 2014, 04:39:21 PM



Title: [finished] Programming job - implement extranonce.subscribe into cgminer
Post by: nicehash on October 22, 2014, 04:39:21 PM
Hi,

*edit: job finished by hyperwang

We are looking for someone to implement and test a small stratum protocol extension called mining.extranonce.subscribe (as described here https://www.nicehash.com/software/#devs) into cgminer. Basically it is mainly only a copy-paste&test job since the implementation has already been done in sgminer and bfgminer.

(btw: we've already proposed this to ckolivas and other official cgminer developers, but they're too busy)

For us it is especially important for this feature to be implemented in cgminer since the majority of ASIC device manufacturers burns cgminer into their devices and in some cases it is hard to put a custom (patched) version later into such devices.

This feature has already been included, for example, in the latest sgminer. Search for "extranonce" here: https://github.com/nicehash/sgminer/commits/master or in official sgminer GIT source code at https://github.com/sgminer-dev/sgminer/commits/master, it has also been implemented in BFGMiner (https://bitcointalk.org/?topic=626361.msg8390976#msg8390976)

The job includes:

- fork latest https://github.com/ckolivas/cgminer into your own github repo;
- add extranonce.subscription patch;
- change the way extranonce.subscription is handled; instead the current default=on (optional "--no-extranonce") you should add "--extranonce-subscribe" so that one must explicitly enable extranonce.subscription ("--extranonce-subscribe" : true) ... similar to the way it was added to BFGMiner (https://bitcointalk.org/?topic=626361.msg8390976#msg8390976);
- please do it in such a way (preferably in single commit or similarly) so that others would be able to pull it very easily into the various other cgminer forks with a single pull request;
- make win32 binaries and test the binaries against stratum.nicehash.com and stratum.westhash.com to make sure that extranonce.subscription is working and extranonce changes are received and used properly without disconnect from stratum servers.

Payment: 0.75 BTC when all the above is done (this is an easy job).

Thank you and let us know if you need any more info!
NiceHash

p.s.: one attempt to do this was already done by badman74, but this work hasn't been finished, nevertheless you can take a look at it here: https://github.com/badman74/cgminer/commits/master


Title: Re: [0.75 BTC] Programming job - implement extranonce.subscribe into cgminer
Post by: nicehash on October 23, 2014, 06:00:39 AM
Bump.


Title: Re: [0.75 .. 1BTC] Programming job - implement extranonce.subscribe into cgminer
Post by: nicehash on October 28, 2014, 08:00:42 AM
There is a small change or better say additional optional request. Instead of implementing "--extranonce-subscribe" parameter it would be much better if you could implement extension in the same way as it has been implemented in BFGminer - in this case one would simply add "#xnsub" at the end of the pool URI to enable extranonce subscribe (for example stratum+tcp://stratum.nicehash.com/#xnsub). This is important because it enables the user to set this without modifying configuration (in some cases ASIC devices won't allow you to set cgminer configuration), also, this enables user to enable extension on a per-pool basis thus not use this extension on pools that does not support extranonce subscription. Please revise the BFGminer implementation and let us know if you could implement handling of extensions the same way BFGminer does (since BFGminer and cgminer are somehow similar maybe you could even reuse some code). If this is doable and you could implement "#xnsub" to be added at the end of the pool URI instead of "--extranonce-subscribe" option, we are willing to rise the payment to 1 BTC.


Title: Re: [0.75 .. 1 BTC] Programming job - implement extranonce.subscribe into cgminer
Post by: elbandi on November 19, 2014, 02:48:11 AM
hehe :D

try this branch:
https://github.com/bitbandi/cgminer/tree/nicehash-extranonce

this is form my old commit rebased to cgminer + the parse url commit from hyperwang (https://github.com/nicehash/cgminer-ckolivas/commit/1416777fcc0a3e6364d5f68cf5a318a0ec16d2b7).


Title: Re: [finished] Programming job - implement extranonce.subscribe into cgminer
Post by: miguelmorales85 on March 15, 2015, 09:49:10 PM
what is the difference between mining with and without extranonce.subscribe?  ???


Title: Re: [finished] Programming job - implement extranonce.subscribe into cgminer
Post by: noel57 on August 09, 2015, 11:19:19 AM
OP should please lock the thread since the job have been finished by hyperwang.


Title: Re: [finished] Programming job - implement extranonce.subscribe into cgminer
Post by: nicehash on August 10, 2015, 06:28:24 AM
This is an old thread, but perhaps someone will come across this and reply.

I was hoping that the last question would be answered.  I've been searching the Internet for hours and while I understand how to implement this feature, I can't what the purpose of it is.  It would be impossible to exhaust all the possible nonces for a given extranonce1 in any reasonable amount of time.

Does anyone know why this feature is important?

This feature is important for our service since we are shifting sellers (miners) between various buying orders. By doing this the miners are getting different jobs and to do this without reconnecting the miner we developed the extranonce.subscribe feature, allowing a miner to get new job without being disconnected, thus improving mining efficiency. This feature is now used by several proxies and services. More details here: https://www.nicehash.com/index.jsp?p=software#devs and various upgraded firmwares here: https://www.nicehash.com/index.jsp?p=software#cgminer

Locking thread now; more info on NiceHash is in this thread: https://bitcointalk.org/index.php?topic=562238.0.