Snipa22 / nodejs-pool

Other
481 stars 422 forks source link

XMR/AEON POW changes #362

Open LegolasGChief opened 6 years ago

LegolasGChief commented 6 years ago

Hello, does anyone know what changes will need to be made to pool software once the POW changes are made?

Mainly for Aeon?

bobbieltd commented 6 years ago

Wait for Snipa coming back from Hawai trips 😂😂😂. By the way, anyone know where Snipa is. He seems silent these days.

Venthos commented 6 years ago

The changes are discussed in the PR here https://github.com/Snipa22/nodejs-pool/pull/307

Although as Snipa22 mentions it is not quite as simple as merging those two PRs as-is. Snipa22 forked node-multi-hashing to include some improvements, which includes changes to the cryptonight_hash() function of course. I am unable to reconcile how to include the new POW change into Snipa22's changes (I'm simply not that familiar/smart enough to do so).

If AEON is adopting the POW change, too, then they would need to clarify the changes needed to node-multi-hashing as well to the relevant cryptonight_light_hash() function and friends. Perhaps it's a near identical change, perhaps not. Again, not smart enough :)

Pool side it's not too bad, as shown by moneromooo's two line change. But, I would argue for those changes to be pushed off into lib/coins/.js, because as-is it would require that CN and CN-light be patched to support the new POW algo. If one was not patched, that coin would detonate on those changes. If the change was pushed into the coinFunc files, you could patch CN without CN-light or vice versa.

If I can ever figure out how to reconcile the node-multi-hashing changes with Snipa22's node-multi-hashing-aesni fork then this should be relatively simple from nodejs-pool's side of things.

bobbieltd commented 6 years ago

@Venthos Do you understand nonce stuffs ? What are the difference between old and new Monero algo (in simple words for dummies) ? There are many tertiary operators in C++ PR at Monero Github that make me uncomprehensible about their changes.

bobbieltd commented 6 years ago

It seems Snipa busy these days. I hope some devs will test new algo and make a PR for this repo.

shigutso commented 6 years ago

this seems critical... hopefully someone (@Snipa22) will update the pool to support the newest Monero and Aeon PoWs!

bobbieltd commented 6 years ago

Venthos are working on it ( I guess MoneroOcean and some others too ). I’ll run test with Venthos, keep follow Venthos’s repo when Snipa is busy.

shigutso commented 6 years ago

cryptonight_light.c from /home/pooldaemon/nodejs-pool/node_modules/multi-hashing needs patching for the new PoW... it seems that only cryptonight.c was updated by moneromooo

Struggling here to setup a testnet AEON pool with the new PoW, blocks are found but obviously not accepted by the network because of the new PoW validation.

Anyone knows if someone already patched that? Checked @Venthos repo but coldn't find anything...

Thanks!

Snipa22 commented 6 years ago

I was out of town for a couple of days, and I'll be doing core patches to multi-hashing this evening. Mostly been super-busy with work as well. Overall, the changes aren't intense, I just need to make sure to hard-lock specific versions of code bases to specific git commits, as the PoW change breaks standard integrations.

bobbieltd commented 6 years ago

I’m busy these days and have not put up the testnet pools. It seems Snipa very busy too. I saw MoneroOcean repo having the patch some days ago. Anyone want to try in advance can use MoneroOcean utils in packages.json

LegolasGChief commented 6 years ago

I think @Arqtras got it working

shigutso commented 6 years ago

eagerly waiting for @Snipa22's AEON patches...

bobbieltd commented 6 years ago

Anyone get v7 working, please make a Pull Request on Snipa’s repo to help him to avoid double work.

camthegeek commented 6 years ago

@vitorgatti @LegolasGChief @bobbieltd #375 is tested and working with AEON variant PoW. This applies minimal changes to the pool. There's a link in there that goes to a branch I have that uses Snipa's current pool code with the changes that you're more than welcome to test.

Monero should work as well with the same changes. Unfortunately, I have found no true way to test Monero's PoW change with the pool software so I have not released any changes. In theory, it's the same changes as I did on AEON rebase. I can push out these changes but I can not prove they work! :)

ArqTras commented 6 years ago

I make test both solutions using multi hashing from Camthegeek and Moneroocean. Both working. Camthegeek version is more universal due to name of module (less changes in coin code) Confirmed working with aeon rebase testnet. MO have for aeon and xmr. Test pool is on aeonrebase.supportcryptonight.com and sources at GitHub ArqTras. My pool code is a bit different but it is compatible backwards to @Snipa22

bladeFury commented 6 years ago

Any updates? I see the cn-variant branch but it's not merged

shigutso commented 6 years ago

@bladeFury not ready yet, https://github.com/Snipa22/node-multi-hashing-aesni needs to be updated by @Snipa22

hey @camthegeek , maybe you can make a PR on that repo as well?

camthegeek commented 6 years ago

@vitorgatti Good call. Created PR on https://github.com/Snipa22/node-multi-hashing-aesni for said changes.

From this point, only a couple lines will need to be changed in lib/coins/xmr.js to make Monero work with variant changes.

shigutso commented 6 years ago

awesome, thanks @camthegeek!

Venthos commented 6 years ago

While not a drop-in replacement for this original repo (you will need to add some new configuration values to the SQL config table, coinConfig, and the main config), https://github.com/Venthos/nodejs-pool/tree/cn-v1 is a branch of nodejs-pool that supports CryptoNight Variant 1 as well as Variant 0 (the original).

You should be able to run my branch of nodejs-pool on mainnet or testnet with XMR or AEON and have it do the right thing in all situations (old and new algorithm). I would welcome some testing on it. I intend to look at Cryptonight Heavy (Sumokoin's variant) later this week and potentially integrate that as well. I haven't merged it into master yet until I get multiple tests to confirm it works well.

BKdilse commented 6 years ago

Hey guys, need some help... my stellite pool is no longer finding blocks. I believe this is due to the hard fork.

Any advice on the best way to update this?

My guess is to update the bits @Venthos mentioned above.