@@ -336,9 +336,14 @@ pub fn process_blockstore_from_root(
|
||||
}
|
||||
}
|
||||
|
||||
blockstore
|
||||
.set_roots(&[start_slot])
|
||||
.expect("Couldn't set root slot on startup");
|
||||
// ensure start_slot is rooted for correct replay
|
||||
if blockstore.is_primary_access() {
|
||||
blockstore
|
||||
.set_roots(&[start_slot])
|
||||
.expect("Couldn't set root slot on startup");
|
||||
} else if !blockstore.is_root(start_slot) {
|
||||
panic!("starting slot isn't root and can't update due to being secondary blockstore access: {}", start_slot);
|
||||
}
|
||||
|
||||
if let Ok(metas) = blockstore.slot_meta_iterator(start_slot) {
|
||||
if let Some((slot, _meta)) = metas.last() {
|
||||
@@ -786,10 +791,14 @@ fn process_single_slot(
|
||||
// see DuplicateSignature errors later in ReplayStage
|
||||
confirm_full_slot(blockstore, bank, opts, recyclers, progress).map_err(|err| {
|
||||
let slot = bank.slot();
|
||||
blockstore
|
||||
.set_dead_slot(slot)
|
||||
.expect("Failed to mark slot as dead in blockstore");
|
||||
warn!("slot {} failed to verify: {}", slot, err);
|
||||
if blockstore.is_primary_access() {
|
||||
blockstore
|
||||
.set_dead_slot(slot)
|
||||
.expect("Failed to mark slot as dead in blockstore");
|
||||
} else if !blockstore.is_dead(slot) {
|
||||
panic!("Failed slot isn't dead and can't update due to being secondary blockstore access: {}", slot);
|
||||
}
|
||||
err
|
||||
})?;
|
||||
|
||||
|
Reference in New Issue
Block a user