Skip to content

Commit 7645714

Browse files
authored
Fix fast-reboot DB migration (#2734)
Fix DB migrator logic for migrating fast-reboot table, fixing #2621 db_migrator. How I did it Checking if fast-reboot table exists in DB. How to verify it Verified manually, migrating after fast-reboot and after cold/warm reboot.
1 parent f7f783b commit 7645714

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

scripts/db_migrator.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -874,8 +874,8 @@ def version_4_0_0(self):
874874
# reading FAST_REBOOT table can't be done with stateDB.get as it uses hget behind the scenes and the table structure is
875875
# not using hash and won't work.
876876
# FAST_REBOOT table exists only if fast-reboot was triggered.
877-
keys = self.stateDB.keys(self.stateDB.STATE_DB, "FAST_REBOOT")
878-
if keys is not None:
877+
keys = self.stateDB.keys(self.stateDB.STATE_DB, "FAST_REBOOT|system")
878+
if keys:
879879
enable_state = 'true'
880880
else:
881881
enable_state = 'false'

0 commit comments

Comments
 (0)