Hive-Based Registry Settings



Hello All,

I am working on ARM based processor. I want to add hive-based registry
to my platform. I want to store registry hives on compact flash.

This is what i have done.

1) Added "Hive-Based Registry to platform"

The following entries were added in my common.reg file

; @CESYSGEN IF FILESYS_FSREGHIVE
; HIVE BOOT SECTION

; Valid Bits for Flags registry value
; If no flags are set, the hive will be stored in the object store.
;
; 0x00000001 Start storage manager in boot phase 1 for hive-based
registry
; 0x00000002 Start device manager in boot phase 1 for hive-based
registry
; 0x00000004 Start storage manager in boot phase 1 for registry in
; external ROM (such as BINFS)
; 0x00000008 Start device manager in boot phase 1 for registry in
; external ROM (such as BINFS)

[HKEY_LOCAL_MACHINE\init\BootVars]
"SystemHive"="Documents and Settings\\system.hv"
"ProfileDir"="Documents and Settings"
"Flags"=dword:0
; END HIVE BOOT SECTION
; @CESYSGEN ENDIF FILESYS_FSREGHIVE

; HIVE BOOT SECTION
; This key allows untrusted processes (when using 2 tier trust model)
to access system files for read.
[HKEY_LOCAL_MACHINE\System\ObjectStore]
"AllowSystemAccess"=dword:1
; END HIVE BOOT SECTION


; Valid Bits for Flags registry value under
[HKEY_LOCAL_MACHINE\init\BootVars]
; 0x00000001 Start storage manager in boot phase 1 for hive-based
registry
; 0x00000002 Start device manager in boot phase 1 for hive-based
registry

IF PRJ_ENABLE_FSMOUNTASROOT
; @CESYSGEN IF FILESYS_FSROMRAM
#error PRJ_ENABLE_FSMOUNTASROOT specified without specifying
SYSGEN_FSROMONLY. Add SYSGEN_FSROMONLY to your configuration
; @CESYSGEN ELSE
; HIVE BOOT SECTION
IF PRJ_BOOTDEVICE_ATAPI
[HKEY_LOCAL_MACHINE\init\BootVars]
"Flags"=dword:3
[HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\HDProfile]
"MountAsRoot"=dword:1
ENDIF

IF PRJ_BOOTDEVICE_MSFLASH
[HKEY_LOCAL_MACHINE\init\BootVars]
"Flags"=dword:1
[HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\MSFlash\FATFS]
"MountAsRoot"=dword:1
ENDIF
; END HIVE BOOT SECTION
; @CESYSGEN ENDIF FILESYS_FSROMRAM
ENDIF


IF PRJ_ENABLE_FSREGHIVE
; @CESYSGEN IF FILESYS_FSREGHIVE
; HIVE BOOT SECTION
IF PRJ_BOOTDEVICE_MSFLASH
[HKEY_LOCAL_MACHINE\init\BootVars]
"Flags"=dword:1
[HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\MSFlash]
"MountAsBootable"=dword:1
ELSE
[HKEY_LOCAL_MACHINE\init\BootVars]
"Flags"=dword:3
[HKEY_LOCAL_MACHINE\System\StorageManager\Profiles\HDProfile]
"MountAsBootable"=dword:1
ENDIF
; @CESYSGEN ELSE
#error PRJ_ENABLE_FSREGHIVE defined without including HIVE based
component. Add SYSGEN_FSREGHIVE to your configuration
; @CESYSGEN ENDIF FILESYS_FSREGHIVE
; END HIVE BOOT SECTION
ENDIF


; @CESYSGEN IF CE_MODULES_FSDMGR

; HIVE BOOT SECTION

IF PRJ_ENABLE_REGFLUSH_THREAD
[HKEY_LOCAL_MACHINE\System\ObjectStore\RegFlush]
; To monitor the flushing from an external process add "ActivityName"
registry value.
; The activity name is a global named event that filesystem will signal
on Registry Activity.
; "ActivityName"=""
; Create an thread in filesys to perform flushing
"SpawnThread"=dword:1
; Make the thread IDLE priority
"FlushPriority256"=dword:FF
; ActivityThreshold specifies the # of reg activity before we force a
flush
"ActivityThreshold"=dword:100
; Timeout period for a flush (flush occurs if there have been some
changes during this period)
"FlushPeriod"=dword:3E8
ENDIF


IF PRJ_ENABLE_DBFLUSH_THREAD
[HKEY_LOCAL_MACHINE\System\ObjectStore\DBFlush]
; To monitor the flushing from an external process add "ActivityName"
registry value.
; The activity name is a global named event that filesystem will signal
on database Activity.
; "ActivityName"=""
; Create an thread in filesys to perform flushing
"SpawnThread"=dword:1
; Make the thread IDLE priority
"FlushPriority256"=dword:FF
; ActivityThreshold specifies the # of db activity before we force a
flush
"ActivityThreshold"=dword:100
; Timeout period for a flush (flush occurs if there have been some
changes during this period)
"FlushPeriod"=dword:3E8
ENDIF


; Registry value that can be queried to determine the type of registry
subsystem that is in use
; 0 - RAM/ObjectStore based registry
; 1 - Hive based registry
; @CESYSGEN IF FILESYS_FSREGHIVE
[HKEY_LOCAL_MACHINE\System\ObjectStore]
"RegistryType"=dword:1
; @CESYSGEN ELSE
[HKEY_LOCAL_MACHINE\System\ObjectStore]
"RegistryType"=dword:0
; @CESYSGEN ENDIF

I have set the following variables to one in my
platform->settings->environment variables

PRJ_ENABLE_FSMOUNTASROOT = 1
PRJ_BOOTDEVICE_ATAPI = 1
PRJ_ENABLE_FSREGHIVE = 1

2) I have added the following to platform.reg file

[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\ATAPI]
"Dll"="atapi.dll"
"Prefix"="DSK"
"DeviceId"=dword:0
"DMAEnable"=dword:1
"FSD"="fatfsd.dll"
"Flags"=dword:1000

[HKEY_LOCAL_MACHINE\init\BootV­ars]
"SystemHive"="Documents and Settings\\system.hv"
"ProfileDir"="Documents and Settings"
"Start DevMgr"=dword:0

When i download the image to my target board, the screen appears blank.
The image is never loaded. Can any one suggest if i am missing any
settings? Do i need to make any other changes?

Thanks in Advance.

Best Regards,
Sush.

.



Relevant Pages

  • Re: TFAT stability
    ... Yes, the flash modifying is the issue here, but why? ... the registry hives from the flash to RAM and now my filesystem crushes, ... Do I have some registry settings wrong for the TFAT or is it something else? ... >>; END HIVE BOOT SECTION ...
    (microsoft.public.windowsce.platbuilder)
  • Re: WinCE 5.0 IDE CF card enumeration
    ... I'd start with RAM based registry first. ... ;END HIVE BOOT SECTION ... It hangs in the boot and the hives don't get created. ... Due to hardware design I cannot switch the connections but need to have the reverse naming, i.e. CF card = "Hard Disk" and harddrive = "Hard Disk2". ...
    (microsoft.public.windowsce.platbuilder)
  • Hive registry not working with Release build
    ... I have setup my hive registry to be on MMC card. ... Everything works fine in a debug build, hives are mounted ... ; END HIVE BOOT SECTION ...
    (microsoft.public.windowsce.platbuilder)
  • Re: Hive-Based Registry Settings
    ... I want to store registry hives on compact flash. ... >; HIVE BOOT SECTION ... >; @CESYSGEN ENDIF FILESYS_FSREGHIVE ... Timeout period for a flush (flush occurs if there have been some ...
    (microsoft.public.windowsce.platbuilder)
  • Re: Hive-Based Registry Settings
    ... I want to store registry hives on compact flash. ... ; HIVE BOOT SECTION ... ; @CESYSGEN ENDIF FILESYS_FSREGHIVE ... Timeout period for a flush (flush occurs if there have been some ...
    (microsoft.public.windowsce.platbuilder)