-
parazyd
Hey I'm having some trouble understanding xmrig's difficulty logic. Currently on Monero mainnet the difficulty is 284746624460, but when I connect xmrig to a pool in connection info xmrig tells me the difficulty is 60000
-
parazyd
What does this mean?
-
moneromooo
A pool needs to estimate your hash rate without you being able to hookwink it. So it makes you solve PoW at a lower difficulty.
-
moneromooo
The pool will take care to submit to the chain only those solutions which match the chain difficulty.
-
parazyd
oh so after I submit a share I should see the real one?
-
moneromooo
I do not understand that question.
-
parazyd
ah maybe I'm misunderstanding the pool's logic
-
parazyd
I thought I would be mining at the actual network difficulty
-
moneromooo
The difficulty threshold is a filter. Your miner generates a lot of nonces. Each of these "gets hashed" to a hash.
-
moneromooo
In solo mining, the filter is "hash matches network difficulty".
-
moneromooo
In pool mining, the filter is "hash matches pool difficulty". The pool diff is low, so it's a coarse filter. The pool then filters more finely by itself.
-
parazyd
Right so for solo mining I'd get the target from 0xffffffffffffffffffffffffffffffff/$difficulty
-
parazyd
And in the pool it's different
-
moneromooo
So you'll be finding a lot more "blocks", most of which just won't be valid, but the pool will use those to decide how much of the block rewards you'll get.
-
parazyd
aha understood
-
moneromooo
No, same thing. Just with a different difficulty.
-
parazyd
okay. For solomining though, I'd have to do 0xffffffffffffffffffffffffffffffff/$difficulty , correct?
-
moneromooo
Sounds plausible.
-
parazyd
Since that's the only way to produce the valid PoW
-
parazyd
Thanks
-
Lyza
since we're talking about it I always wondered what stops miners in a pool from broadcasting a block they find while connected to the pool and claim the whole reward. would need some modified software of course... but surely there must be protection against this
-
Lyza
otherwise you can double dip and get pool rewards + any blocks you personally find
-
moneromooo
Nothing. If they mine on a block where the reward goes to them, that's fine. Of course, the pool will not accept a share for a block where the reward does not go to the pool. You get to choose, but you can do both at the same time.
-
moneromooo
Well, you cannot do both at the same time on the same block. You can of course mine on two blocks at the same time.
-
sech1
To claim block's reward, miner needs to change the block template, and it will invalidate the hash
-
sech1
Pool miners don't even have access to the full block template
-
sech1
They can generate their own, but poll will reject it because it's not what it sent to them
-
Lyza
oh yeah duh because the payout address is in the block
-
Lyza
thx for answering the dumb question heh