mirror of
https://github.com/reactos/reactos.git
synced 2025-08-03 04:26:00 +00:00
[NTOS:CM] Implement support for alternate registry hives
Sometimes repairing a broken hive with a hive log does not always guarantee the hive in question has fully recovered. In worst cases it could happen the LOG itself is even corrupt too and that would certainly lead to a total unbootable system. This is most likely if the victim hive is the SYSTEM hive. This can be anyhow solved by the help of a mirror hive, or also called an "alternate hive". Alternate hives serve the purpose as backup hives for primary hives of which there is still a risk that is not worth taking. For now only the SYSTEM hive is granted the right to have a backup alternate hive. === NOTE === Currently the SYSTEM hive can only base upon the alternate SYSTEM.ALT hive, which means the corresponding LOG file never gets updated. When time comes the existing code must be adapted to allow the possibility to use .ALT and .LOG hives simultaneously.
This commit is contained in:
parent
279f8f8864
commit
f3141fb29e
8 changed files with 239 additions and 39 deletions
|
@ -120,6 +120,10 @@
|
|||
IN ULONG StartingIndex,
|
||||
IN ULONG NumberToSet);
|
||||
|
||||
VOID NTAPI
|
||||
RtlSetAllBits(
|
||||
IN PRTL_BITMAP BitMapHeader);
|
||||
|
||||
VOID NTAPI
|
||||
RtlClearAllBits(
|
||||
IN PRTL_BITMAP BitMapHeader);
|
||||
|
@ -509,6 +513,11 @@ BOOLEAN CMAPI
|
|||
HvWriteHive(
|
||||
PHHIVE RegistryHive);
|
||||
|
||||
BOOLEAN
|
||||
CMAPI
|
||||
HvWriteAlternateHive(
|
||||
_In_ PHHIVE RegistryHive);
|
||||
|
||||
BOOLEAN
|
||||
CMAPI
|
||||
HvSyncHiveFromRecover(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue