shermand100 / PiNodeXMR

Monero Node for Single Board Computers with Web Interface and additional tools pre-configured. Self Installing.
GNU General Public License v3.0
213 stars 41 forks source link

Monero Block Fetching During Sync too large #19

Closed ChiefGyk3D closed 2 years ago

ChiefGyk3D commented 3 years ago

A few people were complaining of Monero hanging and being slow to sync. I think it may be due to the number of blocks being fetched at a time. Monero apparently defaults to 20
adding a --block-sync-size=10 and halving it may aid people including myself with the occasional hung block, also check the documentation here as well if anything helps https://www.monero.how/how-to-run-monero-node

ChiefGyk3D commented 3 years ago

I will work on a code change and make a pull request soon as an opportunity to learn git

shermand100 commented 3 years ago

Sorry, but I think we'll have to compromise on this.

For this project I don't think it's our place to mess with and deviate from default Monero values and push out our settings, unless absolutely necessary. However I have no issue whatsoever with giving people a choice and making this an option .

The block-sync-size debate has been going on for years as to what batch size is faster and where the transition between sync modes fast/safe should be and I don't think we're in a place to overrule the research that has contributed to where that bar is set now.

You may have seen the name HYC around the Monero community, he is the inventor of the LMDB protocol which Monero uses. So LMDB wasn't something that was just pulled off the shelf, so understandably he knows everything about it. He made some basic examples around a year ago when this question was asked by someone else:

https://github.com/monero-project/monero/issues/5596#issuecomment-498407484

And it shows very little difference for the hardware he's using ( which is significantly more powerful that what we are using ).

And in resource terms we're talking about a batch of 20 blocks with an average size of 57KBytes so at it's historical largest should be more than manageable:

https://bitinfocharts.com/comparison/monero-size.html

I'd propose instead this is added as an additional dropdown selection as a global setting option, allowing people to mess with it if they want to. I imagine if someone were trying to force this to work on a Pi2 this may me a necessity but we can't force optimal settings for an Odroid XU4 across all devices.

ChiefGyk3D commented 3 years ago

Sorry, but I think we'll have to compromise on this.

For this project I don't think it's our place to mess with and deviate from default Monero values and push out our settings, unless absolutely necessary. However I have no issue whatsoever with giving people a choice and making this an option .

The block-sync-size debate has been going on for years as to what batch size is faster and where the transition between sync modes fast/safe should be and I don't think we're in a place to overrule the research that has contributed to where that bar is set now.

You may have seen the name HYC around the Monero community, he is the inventor of the LMDB protocol which Monero uses. So LMDB wasn't something that was just pulled off the shelf, so understandably he knows everything about it. He made some basic examples around a year ago when this question was asked by someone else:

https://github.com/monero-project/monero/issues/5596#issuecomment-498407484

And it shows very little difference for the hardware he's using ( which is significantly more powerful that what we are using ).

And in resource terms we're talking about a batch of 20 blocks with an average size of 57KBytes so at it's historical largest should be more than manageable:

https://bitinfocharts.com/comparison/monero-size.html

I'd propose instead this is added as an additional dropdown selection as a global setting option, allowing people to mess with it if they want to. I imagine if someone were trying to force this to work on a Pi2 this may me a necessity but we can't force optimal settings for an Odroid XU4 across all devices.

Drop down makes sense to me. I just am not familiar with PHP and HTML issuing system commands. I'll reference your structure and see if I can make sense of it

ChiefGyk3D commented 3 years ago

@shermand100 I have written some proposed changes, though it will need some testing from you and me both. I am not an HTML and PHP guy so I am sure I messed up something as this was a learning experience for me and I was working by deciphering how you had it structured. See Pull request #20

ChiefGyk3D commented 3 years ago

I did some testing and it works as intended, I even shared pictures to the Telegram group. Definitely recommend fast tracking this one

shermand100 commented 2 years ago

https://github.com/monero-ecosystem/PiNode-XMR/pull/20

Closing this for reasons specified in the merge request. Can re-visit if needed.