[tool] regCompact.
#1
Posted 16 February 2008 - 01:21 PM
The hive files grow in steps of 256 kB.
That means, if you insert only one key into an empty hive the file becomes 256 kB sized.
Inside the hive file there are 4KB steps.
That means, if you insert only one key into an empty hive, the used space inside the hive grows from 8 kB to 12 kB.
The remaining 244 kB are unused and filled by zeroes.
The regCompact program decreases the size of the hive to the remaining used 4 kB blocks.
Attached the program (syntax: 'regCompact <full path to hive>) and a script using the program.
Using this script I could decrease the size of the nativeEx_puzzleXP ISO by 600 kB.
BTW: I would like to know whether it also works for Vista hives.
Peter
regCompact.zip 85.21KB 563 downloads
#2
Posted 16 February 2008 - 03:37 PM
I'm assuming this tool can be used stand alone.
I tried it on setupreg.hiv, default and software from pebuilder.
It appeared to do nothing with setupreg.hiv and default (no size change)
However, the software hive went from 3.44mb to 548kb.
Obviously this is a little too much compaction and the file is empty when opened with RegDatXP.
Is there any debugging that I can do to help with this or am I doing something wrong?
#3
Posted 16 February 2008 - 04:10 PM
I currently I have no idea what's happening with your pebuilder hives. Maybe (what I do not assume) that they are different from my WinBuilder hives. With those the tool works perfect.First I must confess that I'm still not using Winbuilder (just haven't had time yet)
I'm assuming this tool can be used stand alone.
I tried it on setupreg.hiv, default and software from pebuilder.
It appeared to do nothing with setupreg.hiv and default (no size change)
However, the software hive went from 3.44mb to 548kb.
Obviously this is a little too much compaction and the file is empty when opened with RegDatXP.
Is there any debugging that I can do to help with this or am I doing something wrong?
Can you PM me your hives that I can check them?
Thanks
Peter
BTW: I'll also check RegDatXP. Maybe an info needed by RegDatXP is lost, inspite the hives work well in my final (WinBuilder) PE.
Peter
#4
Posted 16 February 2008 - 04:30 PM
I only mentioned it in case there was some dependency needed by your util.
There is a lot of personal software registration information in that hive so I'm a little hesitant to send it.
RegDatXP is simply a registry file viewer, nothing special.
I also tried loading the hive into regedit and windows got very unhappy with me.
If time permits I'll try building from a fresh/generic pebuilder and see what happens.
#5
Posted 16 February 2008 - 04:46 PM
As far as the hives go, I'm sure winbuilder and pebuilder create the same things.
I only mentioned it in case there was some dependency needed by your util.
There is a lot of personal software registration information in that hive so I'm a little hesitant to send it.
RegDatXP is simply a registry file viewer, nothing special.
I also tried loading the hive into regedit and windows got very unhappy with me.
If time permits I'll try building from a fresh/generic pebuilder and see what happens.
I tried RegDatXP with 'my' hives: no problem.
attached the normal nativeEx_puzzleXP hives before regCompact.
Please try them.
You can check your hives, whether they follow 'my' rules:
With a hexeditor, check adresses 0x1000, 0x2000 ...
They all must have the 4 chars 'hbin'
When this sequence is ended there should be only zeroes upto the end of the file.
Peter
pscHives.zip 37.21KB 462 downloads
#6
Posted 16 February 2008 - 05:45 PM
I will try it on the hives of the XPCLI project.
jaclaz
#7
Posted 16 February 2008 - 05:57 PM
I have no problem believing it's still something in my file that's off
Edit:
Ok, I just had pebuilder (with no plugins as an experiment) build registry hives.
RegCompact did not break that software hive, but there was no size difference either.
It did change the timestamps so I have to think it did run on them.
The default hive was already 92kb as opposed to the one you posted that is 256.
I wonder if pebuilder already does this function.
Anyway, the problem is with my file.
#8
Posted 16 February 2008 - 06:38 PM
Maybe I cloned an until now unknown function of pebuilder?I wonder if pebuilder already does this function.
You can check it by hex editor, whether the last 4 kB are 'hbin'
Peter
#9
Posted 16 February 2008 - 07:21 PM
@d4vr0s (terrible to write your alias )Anyway, the problem is with my file.
I got some worries:
I think that I'm a serious developer, and as serious developer I do not like that in something written by me there may be the possibility of 'crash'
This seems to be actual with the software hive you mentioned in your first post.
I understand your concerns that you do not have any reason to trust me (we both do not know each other).
But there is a way that I get the data I need for debug:
You can
- xx all private data in your pebuilder project
(really xx, the size of data must not change) - rebuild the project
- send the resulting software hives
Agreed?
Peter
#10
Posted 16 February 2008 - 07:27 PM
While raw editing the registry hives I did noticed a lot of redundant space between keys.
d4vr0s:
Look on the header of your registry hive - it contains the overall number of hbin's and might need manual correction.
There is also a checksum - I use RegEdit to read back the hives and ensure they are Win32 API compatible.
Also look here for raw edit:
http://www.boot-land...?showtopic=1839
http://www.beginning...7BDBDE30F2A569E
The first topic also contains a small tool for raw hive read.
#11
Posted 16 February 2008 - 08:07 PM
I consider you a serious developer.
But, it is my responsibility to keep my information secure.
I've forgotten most of the stuff that I've done (and why) in plugins and post process scripting.
Any one of those might be doing something that causing this issue.
Since no one else has posted about issues, I have to assume it's something I've done (or even some wrong in my OS).
So what I need to do is go over my setup, probably disable plugins and bypass the post processing to see if it works correctly.
I'm having a love/hate relationship with computers lately, getting a little burned out.
@Nuno
Thanks, I'll look over this material.
#12
Posted 16 February 2008 - 08:13 PM
@psc
I consider you a serious developer.
But, it is my responsibility to keep my information secure.
I've forgotten most of the stuff that I've done (and why) in plugins and post process scripting.
Any one of those might be doing something that causing this issue.
Since no one else has posted about issues, I have to assume it's something I've done (or even some wrong in my OS).
So what I need to do is go over my setup, probably disable plugins and bypass the post processing to see if it works correctly.
I'm having a love/hate relationship with computers lately, getting a little burned out.
@Nuno
Thanks, I'll look over this material.
Peter
#13
Posted 09 June 2008 - 05:27 PM
In very rare cases it can happen that the compacted hive is corrupt.
(Statistically seen I estimate 1 of 10000 cases, in MedEvil's special constellation it has been 1 : 67500)
I fixed this in regCompact.Script version 3, stored on the nativeEx server.
@d4vr0s
Maybe this bug also caused the troubles you reported before.
You can download a new version of regCompact.exe here.
Peter
#14
Posted 10 June 2008 - 11:58 AM
It has to be something I'm doing, I'm lacking motivation on finding out why right now.
#15
Posted 10 June 2008 - 04:14 PM
Just did a quick test and it still corrupts the hive.
It has to be something I'm doing, I'm lacking motivation on finding out why right now.
I get Blue Screens when this script is activated. Using Winbuilder 075b2 and RegCompact v3.
niche99
#16
Posted 10 June 2008 - 04:25 PM
Please post your hives BEFORE RegCompact. If there are some private data inside, PM them to me.I get Blue Screens when this script is activated. Using Winbuilder 075b2 and RegCompact v3.
niche99
BTW: In my opinion, the issue is only depending on regCompact, and independent of WB version.
Peter
#17
Posted 11 June 2008 - 04:18 PM
Please post your hives BEFORE RegCompact. If there are some private data inside, PM them to me.
BTW: In my opinion, the issue is only depending on regCompact, and independent of WB version.
Peter
How do I do this exactly. Are the hives in the Target\Project folder? Is this setupreg.hiv? <- only .hiv file in Target\%ProgectDir%\i386\System32 folder.
How do I attach a .zip to a PM message, I don't see how to do this when I PM you.
niche99
#18
Posted 11 June 2008 - 05:04 PM
Target\%ProgectDir%\i386\System32\setupreg.hivHow do I do this exactly. Are the hives in the Target\Project folder? Is this setupreg.hiv? <- only .hiv file in Target\%ProgectDir%\i386\System32 folder.
How do I attach a .zip to a PM message, I don't see how to do this when I PM you.
niche99
Target\%ProgectDir%\i386\System32\config\software
Target\%ProgectDir%\i386\System32\config\deafult
Peter
#19
Posted 11 June 2008 - 05:35 PM
Target\%ProgectDir%\i386\System32\setupreg.hiv
Target\%ProgectDir%\i386\System32\config\software
Target\%ProgectDir%\i386\System32\config\deafult
Peter
Hi Peter,
Find attached a zip file 'No regCompact.zip'. This file contains the hives you requested plus log.html. These files are created with regCompact deactivated, if I rebuild with regCompact activated I get a Blue Screen. I am building a very minimal nativeEx using the available standard scripts. I add USB support and SATA support from the NativePE project <- reasonably sure these are not the problem as I can build without them and still get a Blue Screen.
niche99
#20
Posted 04 August 2008 - 02:34 PM
Exception EInOutError in module regCompact.exe at 00012F99. File not found.
#21
Posted 04 August 2008 - 02:43 PM
Do you use regCompact.Script version 3?The application always crashes for me.
Exception EInOutError in module regCompact.exe at 00012F99. File not found.
If no, please update and try again.
If yes, can you PM me the crashing hive?
Peter
#22
Posted 04 August 2008 - 02:49 PM
#23
Posted 04 August 2008 - 03:10 PM
Thanks, I got it.Here's the hive:
(SetupREG from WinRoot)
SETUPREG.zip 27.94KB 461 downloads
If you think that thzere meay be some confidential or copyrighted stuff inside, you should edit your post now and remove the attachement.
Peter
#24
Posted 04 August 2008 - 03:55 PM
Sorry, niche99!Hi Peter,
Find attached a zip file 'No regCompact.zip'. This file contains the hives you requested plus log.html. These files are created with regCompact deactivated, if I rebuild with regCompact activated I get a Blue Screen. I am building a very minimal nativeEx using the available standard scripts. I add USB support and SATA support from the NativePE project <- reasonably sure these are not the problem as I can build without them and still get a Blue Screen.
niche99
With the new post of AeroXP i saw your really forgotten post.
Your registries helped me at the time you posted, to fix a bug. >> regCompact.Script version 3
But I forgot to post success here
I hope that you already are using version 3.
Peter
#25
Posted 05 August 2008 - 01:07 PM
With this hive I could not reprocuce your troubles.Here's the hive:
(SetupREG from WinRoot)
SETUPREG.zip 27.94KB 461 downloads
The hive is compacted from 256 to 132 kb.
And it still can be mounted and looks nice in regedit.
If certain keys are lost or changed, please let me know.
Peter
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users