Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
use cost model to limit new account creation #21369
use cost model to limit new account creation #21369
Changes from all commits
4e296db
221f42d
9b0d789
1845d82
b19880f
7b274d6
9838d86
e8e25b8
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If max account data len is 100 MB, then getting to 1 TB would only take a bit over 1 hour, is that right? I don't know what the right number should be here though... If a DoS was happening, would 1 hour be long enough to prevent/handle it?
Math used:
10^12 B / 10^8 B * 0.4 s per slot / 60 s per min / 60 min per hour
(double check in case I made dumb mistakes)There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@carllin ran these calculations in his head about 15 times last night.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this comment was my invitation for him to comment ;-)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah about an hour. I think if we want to survive longer, we'll have to require validators have a lot more disk. Maybe 10TB minimum. How much space does it take to store 1 billion 10 MB accounts 😄 , 10 petabytes?
Also each account costs about $40, so if we factor that in, we could set the disk requirements based on the maximum economic attack we want to handle. 1 billion account would be 40 bil
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We would want more like a week. How does this max compare with the current mainnet-beta account data average written per slot?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've added the data len to the metrics. I'm waiting on the ability to start a validator with this to get the metrics of mnb. Keep in mind the current metrics ONLY measure the data size of account creation; not updates.