Comments (1)
@marcelo-gonzalez I drafted a fix for starting split storage from genesis in this branch master...split-storage-on-genesis and I want you to test it in mocknet.
As it is a prod fix, I was focusing on a real-life scenario of starting split storage node from scratch.
So, for mocknet usage we still need to perform (some) extra steps. I tested this configuration as follows:
- Created a node with big cold db
- Pointed hot db (
.store.path
in config.json) to a new directory - Ran special tool to de-initialise cold db (while preserving data)
neard cold-store -w make-cold-garbage
(yes, we can technically change the name of this tool, but you will have to really convince me) - Ran neard
neard run
After that I saw that everything is ok
- Hot db was created and given DBKind Hot
- Genesis was loaded to hot db
- Cold loop started as a background process
- Cold loop looked at cold db and decided it needed initialisation
- Cold loop started copying all data from hot db to cold db
- Cold loop set cold height to genesis height
As I didn't invest much effort into creating good testing environment, I couldn't test that both node and cold loop will work without problems when in sync.
For mocknet it shouldn't matter which db you attach as cold. These tools do not look at cold db past some keys in BlockMisc column. And those keys are deleted right away via neard cold-store -w make-cold-garbage
.
So, I suggest
- adding any cold disk to some mocknet nodes
- modifying config on those nodes https://near-nodes.io/archival/split-storage-archival#config
- running
neard cold-store -w make-cold-garbage
on them - starting mocknet test as usual (from genesis)
We then want to see those nodes fail to create a snapshot for resharding.
Any cold migration is a background process. During usual mocknet flow we will stop the node once it loaded genesis and make a copy of db for fast future restart. We need to add backup for cold db as well. It will probably not be initialised at that point, but the node from backup will still start ok. Background loop will just begin copying everything from hot to cold as a first step after a reset.
from nearcore.
Related Issues (20)
- [stateless_validation] Solve 2x Latency Problem
- [stateless_validation] test_chunk_forwarding_optimization fails with --features statelessnet_protocol HOT 2
- Neard 1.37.0-rc.2 Process Crash - Stack overflow HOT 1
- Recent node; Lots of errors gc stop height.
- estimator: I/O estimation does not count syscall failures
- Consider adding validator rewards to RPC /validators
- Remove MockEpochManager HOT 1
- Improve split archival node migration
- Remove `is_chunk_producer_for_epoch` from EpochManagerAdapter
- Lychee lints CI check failing HOT 1
- [Forknet] Pre-release testing of resharding
- Remove pieces of code which index slices by shard id
- Remove witnesses which are no longer needed from OrphanStateWitnessPool
- Make size limit of orphan witnesses configurable
- Guidelines for handling unexpected errors HOT 4
- Statelessnet validator crashed because of `Option::unwrap()` on a `None` value HOT 7
- Make ChunkStateWitness a Tier1 network message HOT 4
- bugger
- Remove KeyValueRuntime
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from nearcore.