Pages:
Author

Topic: [ANN] Stratum mining protocol - ASIC ready - page 4. (Read 145773 times)

newbie
Activity: 19
Merit: 0
February 22, 2014, 06:42:44 AM
Hi,

can somebody explain me what is the session in stratum?

Quote
{"error": null, "id": 1, "result": [["mining.notify", "ae6812eb4cd7735a302a8a9dd95cf71f"], "00000001", 4]}

Can I ignore this parameter? What is it? Can I set this parameter?

Thanks for reply
hero member
Activity: 693
Merit: 500
February 18, 2014, 02:16:57 AM
If someone (me) wanted to draft a proposed extension/standard stratum message, who would be the appropriate "body" to submit an RFC-like proposal to?
This thread is as close to an RFC like body you'll get since the pool operators and mining software authors worked from it. Thus the defacto standard for stratum is developed and discussed from here. Of course if you're interested in doing something for the sake of some altcoin's benefit only, I'm not interested...

Thanks for the quick reply - it is actually somewhat alt-coin related, but not tied to any coin specifically.  Once I have my idea fleshed out, I'll post it here.
-ck
legendary
Activity: 4088
Merit: 1631
Ruu \o/
February 18, 2014, 02:11:13 AM
If someone (me) wanted to draft a proposed extension/standard stratum message, who would be the appropriate "body" to submit an RFC-like proposal to?
This thread is as close to an RFC like body you'll get since the pool operators and mining software authors worked from it. Thus the defacto standard for stratum is developed and discussed from here. Of course if you're interested in doing something for the sake of some altcoin's benefit only, I'm not interested...
hero member
Activity: 693
Merit: 500
February 18, 2014, 01:57:30 AM
Why are none of the questions in this thread about the stratum mining protocol, which is what the thread is about? Smiley


Fine, I've got one Wink

If someone (me) wanted to draft a proposed extension/standard stratum message, who would be the appropriate "body" to submit an RFC-like proposal to?
legendary
Activity: 2730
Merit: 1034
Needs more jiggawatts
February 17, 2014, 04:58:44 PM
Why are none of the questions in this thread about the stratum mining protocol, which is what the thread is about? Smiley
hero member
Activity: 686
Merit: 500
WANTED: Active dev to fix & re-write p2pool in C
February 17, 2014, 04:55:38 AM
Hello guys,

Are there any plans to introduce p2pool compatibility?

Cheers.
full member
Activity: 126
Merit: 100
February 16, 2014, 06:11:58 PM
Is there a way to let the server force a new 'extranonce1' on the miner without letting it disconnect ?

I'd like to know this, too.
sr. member
Activity: 332
Merit: 250
February 09, 2014, 01:28:44 PM
Is there a way to let the server force a new 'extranonce1' on the miner without letting it disconnect ?
newbie
Activity: 19
Merit: 0
I try reconnect worker to pool, but I have problem with this:

Quote
SEND: {"id": 1, "method": "mining.subscribe", "params": ["cpuminer/2.3.1"]}
RECVD: {"error": null, "id": 1, "result": [["mining.notify", "ae6812eb4cd7735a302a8a9dd95cf71f"], "f80015e9", 4]}

SEND: {"id": 1, "method": "mining.subscribe", "params": ["cpuminer/2.3.1", "ae6812eb4cd7735a302a8a9dd95cf71f"]}
RECVD: {"error": null, "id": 1, "result": [["mining.notify", "ae6812eb4cd7735a302a8a9dd95cf71f"], "f80000cf", 4]}
SEND: {"id": 2, "method": "mining.authorize", "params": ["user.1", "x"]}
RECVD: {"params": [64], "id": null, "method": "mining.set_difficulty"}
RECVD: {"params": ["1033", "e66ab39733c0713f6119df118f695f5d59b6a13fe056a88bf01f89f03e2a5e05", "01000000010000000000000000000000000000000000000000000000000000000000000000fffff fff26029f77062f503253482f0472fae85208", "0d2f7374726174756d506f6f6c2f0000000001808d643d000000001976a91480d0bb1754063fe37 14747d9ff44322500ae67a588ac00000000", ["2fd8a870b199fff48f9486942d8eb05b601ad903d5c5e80db9362d0d3d4879f5", "1119df1e3825d80027d33c6150a4db12953dc0fa1a72b2e5624ae1a2d79a5397"], "00000001", "1c128600", "52e8fa74", true], "id": null, "method": "mining.notify"}

RECVD: {"params": [4], "id": null, "method": "mining.set_difficulty"}
RECVD: {"error": null, "id": 2, "result": true}

RECVD: {"params": ["2bba", "e66ab39733c0713f6119df118f695f5d59b6a13fe056a88bf01f89f03e2a5e05", "01000000010000000000000000000000000000000000000000000000000000000000000000fffff fff26029f77062f503253482f04aefae85208", "0d2f7374726174756d506f6f6c2f0000000001808d643d000000001976a91480d0bb1754063fe37 14747d9ff44322500ae67a588ac00000000", ["2fd8a870b199fff48f9486942d8eb05b601ad903d5c5e80db9362d0d3d4879f5", "1119df1e3825d80027d33c6150a4db12953dc0fa1a72b2e5624ae1a2d79a5397"], "00000001", "1c128600", "52e8fab0", false], "id": null, "method": "mining.notify"}
SEND: {"method": "mining.submit", "params": ["user.1", "1033", "00000000", "52e8fa74", "34431200"], "id":4}}
RECVD: {"error": [-2, "Share is above target", null], "id": 4, "result": null}
newbie
Activity: 28
Merit: 0
I'm trying to use a stratum proxy only for lowering traffic
sr. member
Activity: 294
Merit: 250
тσ ¢σιи σя иσт тσ ¢σιи?
Why are you using a proxy for the Ants ?  They have stratum built in.
newbie
Activity: 28
Merit: 0
I need help for configuring the stratum proxy and the workers in the pool.
Currently I have a KnC Saturn working at 320 GHps and 2 Antminer S1 working each @ 193GHps, with 3 separate workers in btcguild using eu-stratum.btcguild.com:3333 as stratum server for each worker. All 3 workers has 256 difficulty set in the pool settings.
I'm trying to use the Stratum mining proxy but I have some doubts on the proper settings.
I think I should use another new worker that was responsible of all the shares with a new difficulty of 512, so the stratum mining proxy should point to this new worker with the -cu USER_ALLWORKERS -cp any.
So with these settings the traficc between the proxy and the pool should be restricted to shares with 512 of difficulty and minimize traffic.
First of all, are my guess ok?
The problem is that it doesn't work as expected in a windows version of the stratum proxy with the 2 Antminers connected because all shares appears as rejected by low difficulty.
Any suggestion?
Thanks in advance.
Regards.
newbie
Activity: 12
Merit: 0
Hi,

I'm testing out the latest git version of the slush0 mining_proxy in Linux, and I receive the following error when trying Scrypt:

Code:
user@host:~/stratum-mining-proxy$ ./mining_proxy.py -st -o pool-eu.hash.so -p 1337 -cu user.wk1 -cp pass
/usr/local/lib/python2.7/dist-packages/zope.interface-4.0.5-py2.7-linux-i686.egg/zope/__init__.py:3: UserWarning: Module twisted was already imported from /usr/local/lib/python2.7/dist-packages/Twisted-13.2.0-py2.7-linux-i686.egg/twisted/__init__.pyc, but /usr/local/lib/python2.7/dist-packages/autobahn-0.7.4-py2.7.egg is being added to sys.path
  import pkg_resources
2014-01-27 22:45:08,737 INFO proxy jobs. # C extension for midstate not available. Using default implementation instead.
2014-01-27 22:45:08,738 ERROR proxy mining_proxy.main # Stratum host/port autodetection failed
Traceback (most recent call last):
  File "./mining_proxy.py", line 182, in main
    new_host = (yield utils.detect_stratum(args.host, args.port))
AttributeError: 'module' object has no attribute '_parse'
2014-01-27 22:45:08,738 WARNING proxy mining_proxy.main # Stratum proxy version: 1.5.2
2014-01-27 22:45:08,739 WARNING proxy mining_proxy.test_update # Checking for updates...
2014-01-27 22:45:09,743 WARNING proxy mining_proxy.main # Trying to connect to Stratum pool at pool-eu.hash.so:1337
2014-01-27 22:45:09,922 INFO stats stats.print_stats # 1 peers connected, state changed 1 times
2014-01-27 22:45:09,922 INFO proxy mining_proxy.on_connect # Connected to Stratum pool at pool-eu.hash.so:1337
2014-01-27 22:45:09,922 WARNING proxy mining_proxy.on_connect # Authorizing custom user noveske.test, password qwe
2014-01-27 22:45:09,922 INFO proxy mining_proxy.on_connect # Subscribing for mining jobs
2014-01-27 22:45:10,559 INFO proxy client_service.handle_event # Setting new difficulty: 16
2014-01-27 22:45:10,685 INFO proxy client_service.handle_event # New job 388 for prevhash cc899b97, clean_jobs=True
2014-01-27 22:45:10,685 ERROR protocol protocol.dataReceived # Processing of message failed
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/stratum-0.2.12-py2.7.egg/stratum/protocol.py", line 185, in dataReceived
    self.lineReceived(line, request_counter)
  File "/usr/local/lib/python2.7/dist-packages/stratum-0.2.12-py2.7.egg/stratum/protocol.py", line 257, in lineReceived
    raise custom_exceptions.ProtocolException("Lookup for deferred object for message ID '%s' failed." % msg_id)
ProtocolException: Lookup for deferred object for message ID '1' failed.
2014-01-27 22:45:10,685 INFO proxy mining_proxy.on_disconnect # Disconnected from Stratum pool at pool-eu.hash.so:1337
2014-01-27 22:45:10,686 INFO stats stats.print_stats # 0 peers connected, state changed 1 times
2014-01-27 22:45:12,735 INFO stats stats.print_stats # 1 peers connected, state changed 1 times
2014-01-27 22:45:12,735 INFO proxy mining_proxy.on_connect # Connected to Stratum pool at pool-eu.hash.so:1337
2014-01-27 22:45:12,735 WARNING proxy mining_proxy.on_connect # Authorizing custom user noveske.test, password qwe
2014-01-27 22:45:12,735 INFO proxy mining_proxy.on_connect # Subscribing for mining jobs
2014-01-27 22:45:13,366 INFO proxy client_service.handle_event # Setting new difficulty: 16
2014-01-27 22:45:13,512 INFO proxy client_service.handle_event # New job 35a for prevhash cc899b97, clean_jobs=True
2014-01-27 22:45:13,512 ERROR protocol protocol.dataReceived # Processing of message failed
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/stratum-0.2.12-py2.7.egg/stratum/protocol.py", line 185, in dataReceived
    self.lineReceived(line, request_counter)
  File "/usr/local/lib/python2.7/dist-packages/stratum-0.2.12-py2.7.egg/stratum/protocol.py", line 257, in lineReceived
    raise custom_exceptions.ProtocolException("Lookup for deferred object for message ID '%s' failed." % msg_id)
ProtocolException: Lookup for deferred object for message ID '1' failed.
2014-01-27 22:45:13,512 INFO proxy mining_proxy.on_disconnect # Disconnected from Stratum pool at pool-eu.hash.so:1337
2014-01-27 22:45:13,512 INFO stats stats.print_stats # 0 peers connected, state changed 1 times
^C
2014-01-27 22:45:14,456 INFO proxy mining_proxy.on_shutdown # Shutting down proxy...
user@host:~/stratum-mining-proxy$

Any suggestions on how to fix?

Thanks
sr. member
Activity: 294
Merit: 250
тσ ¢σιи σя иσт тσ ¢σιи?
I am having an issue when I try to connect to other pools. I can connect to Slushs pool fine but when I try to access another pool using a bat file to start up the stratum proxy I get this error:

Failure: stratum.custom_exceptions.TransportException: SocketTransportClientFactory connection timed out


Any idea what the problem might be ?



*Edit: I figured it out. You need to remove the 'stratum+tcp://' when adding an address that has it.
sr. member
Activity: 412
Merit: 250
December 07, 2013, 05:02:55 PM
I have also problem of updating database, I use mysql and when I check logs from stratum it all shows ok.
Code:
2013-12-07 21:57:01,755 INFO interfaces # 00009cb3ba73127a5ae5c7cb71e49aca1a152d0b75b79c996ea1d3541 (38) valid Luigi.l
2013-12-07 21:57:02,189 INFO interfaces # 0000050287f5fb24e149b7bfdd09bef599db4c321a2d9b2dc900dcab484 (51) valid Luigi.l
2013-12-07 21:57:02,229 INFO block_updater # Checking for new block.
2013-12-07 21:57:02,235 DEBUG bitcoin_rpc_manager # Check Height -- Current Pool 0 : 474485
2013-12-07 21:57:02,297 INFO interfaces # 00000859b1acd400a8052f38109f15b568cffd2e69688a6e1e70f308d37f (30) valid Luigi.l
2013-12-07 21:57:02,523 INFO interfaces # 0000067c285ee0440cbf6efd406fdf16c95f4b2bdb82db7e605d524a0508 (39) valid Luigi.l
2013-12-07 21:57:02,674 INFO interfaces # 00000f2862fa94f50d804bdb16ba71173eb768892d4ed4a1c4be5654d (16) valid Luigi.l
2013-12-07 21:57:02,776 DEBUG DBInterface # run_import_thread current size: 110
2013-12-07 21:57:02,777 DEBUG DBInterface # DB_Mysql INIT
2013-12-07 21:57:02,777 DEBUG DB_Mysql # Connecting to DB
2013-12-07 21:57:02,780 DEBUG DBInterface # DBInterface.do_import called. force: no, queue size: 110
2013-12-07 21:57:02,781 INFO DBInterface # Inserting 50 Share Records
2013-12-07 21:57:02,782 DEBUG DB_Mysql # Importing Shares
2013-12-07 21:57:02,832 INFO interfaces # 00000cd45c5bb5e1f2b4f53d93065b4319e0fbf0c64758e431490d0c23 (19) valid Luigi.l
2013-12-07 21:57:02,846 INFO DBInterface # Inserting 50 Share Records
2013-12-07 21:57:02,846 DEBUG DB_Mysql # Importing Shares
2013-12-07 21:57:02,904 INFO DBInterface # Inserting 11 Share Records
2013-12-07 21:57:02,904 DEBUG DB_Mysql # Importing Shares
2013-12-07 21:57:03,446 INFO interfaces # 00000d2de8c906e2423e99d571a87b5116d2172ce2d3796b7b35395ff (19) valid George.1
2013-12-07 21:57:03,449 INFO interfaces # 000002c06ab2d1bd8f76cb1afc9cdeb14a2a22c0413c6ab521663 (93) valid Luigi.l
2013-12-07 21:57:03,699 INFO interfaces # 00000498a064564b638806f754099b66991df4c24eb616bcdb4a105008 (55) valid George.1


but I when I look at my website MPOS pool in Finder, Round, Blocks, etc. All is empty, except dashboard where all is ok, pool is on about 8000 Khash.
all database user and password is ok
http://www.digge.eu/index.php?page=statistics&action=blocks
full member
Activity: 181
Merit: 102
December 06, 2013, 02:55:39 AM
How to add support quark_hash in stratum-mining?
hero member
Activity: 616
Merit: 500
So I gave the windows binaries a try, I installed the proxy on my Windows 7 64bit VM and connected my Avalon miners and ASIC USB key machine to the proxy. I noticed I get around 109ms and a lot of rejects show up on the avalons, yet if I connect direct to Slush's site I don't get nearly as many rejects on my Avalon's.

Is there a reason for this?

My network consists a Dell 6224 Gbit switch, CAT6 cable and a Cisco Gbit firewall.

Thanks,
legendary
Activity: 2688
Merit: 1468
September 03, 2013, 12:08:58 AM
A 30s refresh (vs a 60s refresh) will increase your chance of getting higher transaction fees ...

Thanks Kano.

Will try reducing the refresh interval.  Right now, I'm running with 150.  
I just found my first block: 255822 !!! Only 0.0667 in transactions.
legendary
Activity: 4466
Merit: 1798
Linux since 1997 RedHat 4
September 02, 2013, 09:39:02 AM
A 30s refresh (vs a 60s refresh) will increase your chance of getting higher transaction fees ...
legendary
Activity: 2688
Merit: 1468
September 01, 2013, 10:03:14 AM
Slush's document stipulated that it should refresh at least every 60 seconds. If it's much longer than that, since you're dealing with raw sockets that can quietly die, there is no way for the miner software to know if the socket has disappeared, so cgminer uses 90 seconds between messages to say the pool has died so you cannot increase it to much more. Updating it more frequently includes newer transactions but requires more refreshes on your mining software, and vice versa.

Thanks Con.  I appreciate your explanation.  I'm trying to understand how this works.

So basically, miners work on solving a block and server gives them new "merkle_branch" when this refresh interval is reached or a new block is detected., right?  The previous work is discarded on the miner side or is submitted?  It should be valid if prevHash has not changed (ie new block was solved), no?

Would faster refreshes give miners a slight edge of finding easy blocks?  If everybody and their mother is getting merke_branches every 60 seconds, and you get them every 35 seconds, if there is easy block to find, you would have a better chance of starting to work on it first.  But then again, it might be a toss since working longer on a given merkle_branch might actually help miner solve the block.

Running at 150 seconds now, no issues so far.

Pages:
Jump to: