Bitcoin Forum
August 19, 2018, 12:14:33 AM *
News: Latest stable version of Bitcoin Core: 0.16.2  [Torrent].
 
   Home   Help Search Donate Login Register  
Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 [19]  All
  Print  
Author Topic: CKPOOL - Open source pool/proxy/passthrough/redirector/library in c for Linux  (Read 103069 times)
andyjh12322
Newbie
*
Offline Offline

Activity: 1
Merit: 0


View Profile
July 12, 2018, 12:30:28 AM
 #361

Hi ck,

I'm getting a strange json error in my logs.

Looks like connector.c is not stripping HTTP from the json before it submits to json_load

Code:
Connector created new client instance
[2018-07-11 14:59:53.478] Connected new client 0 on socket 12 to 0 active clients from 192.168.x.x:59482
[2018-07-11 14:59:53.478] Client sendbufsize detected as 374400
[2018-07-11 14:59:53.478] Client id 2 sent invalid json message POST / HTTP/1.1
Host: 192.168.xx.xx:3333
Authorization: Basic xxxxxxxxxob2FoMTxxxxxIzNDU
Accept: */*
Accept-Encoding: deflate, gzip
Content-type: application/json
X-Mining-Extensions: longpoll midstate rollntime submitold
Content-Length: 116
User-Agent: sgminer 5.1.1

{"id": 0, "method": "getblocktemplate", "params": [{"capabilities": ["coinbasetxn", "workid", "coinbase/append"]}]}

this is on latest bitbucket update from 2018-6-14.

thanks!
 Andrew
1534637673
Hero Member
*
Offline Offline

Posts: 1534637673

View Profile Personal Message (Offline)

Ignore
1534637673
Reply with quote  #2

1534637673
Report to moderator
1534637673
Hero Member
*
Offline Offline

Posts: 1534637673

View Profile Personal Message (Offline)

Ignore
1534637673
Reply with quote  #2

1534637673
Report to moderator
1534637673
Hero Member
*
Offline Offline

Posts: 1534637673

View Profile Personal Message (Offline)

Ignore
1534637673
Reply with quote  #2

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

Posts: 1534637673

View Profile Personal Message (Offline)

Ignore
1534637673
Reply with quote  #2

1534637673
Report to moderator
1534637673
Hero Member
*
Offline Offline

Posts: 1534637673

View Profile Personal Message (Offline)

Ignore
1534637673
Reply with quote  #2

1534637673
Report to moderator
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2618
Merit: 1123


Ruu \o/


View Profile WWW
July 12, 2018, 12:46:47 AM
 #362

Hi ck,

I'm getting a strange json error in my logs.

Looks like connector.c is not stripping HTTP from the json before it submits to json_load

Code:
Connector created new client instance
[2018-07-11 14:59:53.478] Connected new client 0 on socket 12 to 0 active clients from 192.168.x.x:59482
[2018-07-11 14:59:53.478] Client sendbufsize detected as 374400
[2018-07-11 14:59:53.478] Client id 2 sent invalid json message POST / HTTP/1.1
Host: 192.168.xx.xx:3333
Authorization: Basic xxxxxxxxxob2FoMTxxxxxIzNDU
Accept: */*
Accept-Encoding: deflate, gzip
Content-type: application/json
X-Mining-Extensions: longpoll midstate rollntime submitold
Content-Length: 116
User-Agent: sgminer 5.1.1

{"id": 0, "method": "getblocktemplate", "params": [{"capabilities": ["coinbasetxn", "workid", "coinbase/append"]}]}

this is on latest bitbucket update from 2018-6-14.

thanks!
 Andrew

Hmm, nope, it looks like your client is sending a http encapsulated request for getblocktemplate instead of a json message and ckpool is simply dumping the entire message as is, rightly saying it's not valid json. Looks like the client is trying to mine with the defunct getblocktemplate mining protocol instead of stratum. It's also a shitcoin miner based on the mining software id it's giving you.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
huglester
Jr. Member
*
Offline Offline

Activity: 48
Merit: 0


View Profile
August 11, 2018, 10:40:08 PM
 #363

Hello,

on some VPSes I cna't change this value. is there way so that the passthrough would be working?
so it show only notice, that those values needs to changed (or recommended) ?
Code:
[2018-08-12 01:23:25.541] ckpassthrough generator starting
[2018-08-12 01:23:25.541] ckpassthrough stratifier starting
[2018-08-12 01:23:25.541] ckpassthrough connector starting
[2018-08-12 01:23:25.541] ckpassthrough connector ready
[2018-08-12 01:23:25.542] ckpassthrough stratifier ready
[2018-08-12 01:23:25.554] Failed to increase rcvbufsiz to 1048576, increase rmem_max or start ckpassthrough privileged
[2018-08-12 01:23:25.554] Failed to increase sendbufsize to 1048576, increase wmem_max or start ckpassthrough privileged
Segmentation fault

I also don't quite understand, user and password. can we skip it in the passthough mode?
Since I want my rigs to set the username/password themseved?

(btw it should work on algos, for example x17, lyra2z etc?)
thank you
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2618
Merit: 1123


Ruu \o/


View Profile WWW
August 11, 2018, 10:43:10 PM
 #364

Hello,

on some VPSes I cna't change this value. is there way so that the passthrough would be working?
so it show only notice, that those values needs to changed (or recommended) ?
Code:
[2018-08-12 01:23:25.541] ckpassthrough generator starting
[2018-08-12 01:23:25.541] ckpassthrough stratifier starting
[2018-08-12 01:23:25.541] ckpassthrough connector starting
[2018-08-12 01:23:25.541] ckpassthrough connector ready
[2018-08-12 01:23:25.542] ckpassthrough stratifier ready
[2018-08-12 01:23:25.554] Failed to increase rcvbufsiz to 1048576, increase rmem_max or start ckpassthrough privileged
[2018-08-12 01:23:25.554] Failed to increase sendbufsize to 1048576, increase wmem_max or start ckpassthrough privileged
Segmentation fault

I also don't quite understand, user and password. can we skip it in the passthough mode?
Since I want my rigs to set the username/password themseved?

thank you
Username and password is ignored in passthrough mode. The segfault is actually a recent bug and nothing to do with those privileges. I haven't had time to go and fix it so you could check out an earlier commit and use that for passthrough instead. A known good commit was 64961e4091b053935e57eabe346f59964c1bbb70

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
huglester
Jr. Member
*
Offline Offline

Activity: 48
Merit: 0


View Profile
August 11, 2018, 11:48:29 PM
 #365

Hello,

on some VPSes I cna't change this value. is there way so that the passthrough would be working?
so it show only notice, that those values needs to changed (or recommended) ?
Code:
[2018-08-12 01:23:25.541] ckpassthrough generator starting
[2018-08-12 01:23:25.541] ckpassthrough stratifier starting
[2018-08-12 01:23:25.541] ckpassthrough connector starting
[2018-08-12 01:23:25.541] ckpassthrough connector ready
[2018-08-12 01:23:25.542] ckpassthrough stratifier ready
[2018-08-12 01:23:25.554] Failed to increase rcvbufsiz to 1048576, increase rmem_max or start ckpassthrough privileged
[2018-08-12 01:23:25.554] Failed to increase sendbufsize to 1048576, increase wmem_max or start ckpassthrough privileged
Segmentation fault

I also don't quite understand, user and password. can we skip it in the passthough mode?
Since I want my rigs to set the username/password themseved?

thank you
Username and password is ignored in passthrough mode. The segfault is actually a recent bug and nothing to do with those privileges. I haven't had time to go and fix it so you could check out an earlier commit and use that for passthrough instead. A known good commit was 64961e4091b053935e57eabe346f59964c1bbb70

just recompiled at commit you specified
Code:
    commit 64961e4091b053935e57eabe346f59964c1bbb70
    Propagate transactions that have reappeared after having been missing for a while to minimise risk of lost transctions in remote work.

not getting error about sysctl value, but still segfault. should I go with even earlier commit?

[2018-08-12 02:45:57.565] ckpassthrough generator starting
[2018-08-12 02:45:57.565] ckpassthrough stratifier starting
[2018-08-12 02:45:57.565] ckpassthrough connector starting
[2018-08-12 02:45:57.566] ckpassthrough connector ready
[2018-08-12 02:45:57.566] ckpassthrough stratifier ready
Segmentation fault
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2618
Merit: 1123


Ruu \o/


View Profile WWW
August 11, 2018, 11:49:51 PM
 #366

Hello,

on some VPSes I cna't change this value. is there way so that the passthrough would be working?
so it show only notice, that those values needs to changed (or recommended) ?
Code:
[2018-08-12 01:23:25.541] ckpassthrough generator starting
[2018-08-12 01:23:25.541] ckpassthrough stratifier starting
[2018-08-12 01:23:25.541] ckpassthrough connector starting
[2018-08-12 01:23:25.541] ckpassthrough connector ready
[2018-08-12 01:23:25.542] ckpassthrough stratifier ready
[2018-08-12 01:23:25.554] Failed to increase rcvbufsiz to 1048576, increase rmem_max or start ckpassthrough privileged
[2018-08-12 01:23:25.554] Failed to increase sendbufsize to 1048576, increase wmem_max or start ckpassthrough privileged
Segmentation fault

I also don't quite understand, user and password. can we skip it in the passthough mode?
Since I want my rigs to set the username/password themseved?

thank you
Username and password is ignored in passthrough mode. The segfault is actually a recent bug and nothing to do with those privileges. I haven't had time to go and fix it so you could check out an earlier commit and use that for passthrough instead. A known good commit was 64961e4091b053935e57eabe346f59964c1bbb70

just recompiled at commit you specified
Code:
   commit 64961e4091b053935e57eabe346f59964c1bbb70
    Propagate transactions that have reappeared after having been missing for a while to minimise risk of lost transctions in remote work.

not getting error about sysctl value, but still segfault. should I go with even earlier commit?

[2018-08-12 02:45:57.565] ckpassthrough generator starting
[2018-08-12 02:45:57.565] ckpassthrough stratifier starting
[2018-08-12 02:45:57.565] ckpassthrough connector starting
[2018-08-12 02:45:57.566] ckpassthrough connector ready
[2018-08-12 02:45:57.566] ckpassthrough stratifier ready
Segmentation fault

Probably. The passthrough has received virtually no attention since I abandoned helping Kano's pool so it's in a sorry state I'm afraid to say since I've had no use or need for it, and no one has funded work on it.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
huglester
Jr. Member
*
Offline Offline

Activity: 48
Merit: 0


View Profile
August 12, 2018, 12:13:47 AM
 #367

Probably. The passthrough has received virtually no attention since I abandoned helping Kano's pool so it's in a sorry state I'm afraid to say since I've had no use or need for it, and no one has funded work on it.

I see. I manged to compile your commit, seems problem was with missing user, pass in proxy config.
but now different error:
[2018-08-12 03:09:51.633] ckpassthrough generator starting
[2018-08-12 03:09:51.633] ckpassthrough stratifier starting
[2018-08-12 03:09:51.633] ckpassthrough connector starting
[2018-08-12 03:09:51.634] ckpassthrough connector ready
[2018-08-12 03:09:51.634] ckpassthrough stratifier ready
[2018-08-12 03:09:51.647] Failed to increase rcvbufsiz to 1048576, increase rmem_max or start ckpassthrough privileged
[2018-08-12 03:09:51.647] Failed to increase sendbufsize to 1048576, increase wmem_max or start ckpassthrough privileged
[2018-08-12 03:09:51.649] Denied passthrough for stratum
[2018-08-12 03:09:51.649] Failed initial passthrough to localhost:3737 !
[2018-08-12 03:09:51.654] Denied passthrough for stratum
[2018-08-12 03:09:51.654] Failed initial passthrough to localhost:3737 !

---
with ./ckpool -u  - similar error with auth
[2018-08-12 03:09:19.705] Proxy 0:0 localhost:3737 failed to authorise in auth_stratum, got: {"id":42,"result":false,"error":null}
[2018-08-12 03:09:19.705] Failed initial authorise to localhost:3737 with user:pass !

--
seems that ckpool binary tries to athorize rigth away, but it should probably do it on first user connect?
I try to configure some shitcoin algo Smiley maybe it's not suitable for this?

btw, can't simple proxy written it work? I mean if I only need to 'bridge' traffic?
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2618
Merit: 1123


Ruu \o/


View Profile WWW
August 12, 2018, 12:38:20 AM
 #368

I try to configure some shitcoin algo Smiley
You're on your own now.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
kano
Legendary
*
Online Online

Activity: 2548
Merit: 1052


Linux since 1997 RedHat 4


View Profile
August 15, 2018, 02:30:27 AM
 #369

...
Probably. The passthrough has received virtually no attention since I abandoned helping Kano's pool so it's in a sorry state I'm afraid to say since I've had no use or need for it, and no one has funded work on it.
Well you have succeeded in breaking it with 100% guaranteed failures ... and your competition was affected in each case.

3 times I can remember I've had to fix:
1) there's a deadlock that occurs 100% of the time for a 'real' pool, in the stratifier that I reported to Lightsword
2) the passthrough crashes 100% of the time on startup
3) the passthrough fails to submit ALL blocks that have an asicboost version mask

Though I'm not sure why you think that someone will pay you to fix the breakages you added ...

Please remove it - since you make claims about how good it is in all material describing your minor subset of the ckpool code ... yet never bothered to point out how dangerous it is for anyone to use due to your regular breakage of it.

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 [19]  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!