-
Notifications
You must be signed in to change notification settings - Fork 33
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
Database BackupManager #1711
base: nightly
Are you sure you want to change the base?
Database BackupManager #1711
Conversation
@@ -761,6 +766,7 @@ where | |||
missed_da_blocks_count = 0; | |||
} | |||
|
|||
let _l2_lock = backup_manager.start_l2_processing().await; |
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.
does this mean taking backups would lock us here and we won't be able to produce blocks?
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.
from my understanding coupled with WAL rocksdb::backup::BackupEngine
doesn't really need you to lock the database.
once concern here maybe would be the state_db and native_db are expected to always be in the same version so we have to guarantee somehow they are backed up at the same point in time -- which is not really possible.
is that the case?
if so, we'll soon be working on fixing this incompatibility problem.
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 is to err on the safe side and guarantee that all databases are at an initial l2 block state.
The lock is held to access l2 block height and spawn the backup tasks in this safe state and then released. Block production should tick along while backup is on-going
Description
BackupManager
to backup all databases required by a citrea node.backup_create <path>
to create a node backup atpath
backup_validate <path>
to validate a node backup atpath
backup_info <path>
to get info about backup atpath
--restore-db <path>
arg to restore a node from a backup atpath
. TBDLinked Issues
Depends on #1714