Load Win98 Registry File: User.dat or System.dat

Posted on 2009-04-15
Last Modified: 2013-12-14

I have some ancient Win98, WinMe, and WinNT registry hive files that I want to examine.  When I tried to load them in regedit on a Vista computer, it failed saying "Cannot load c:\temp\win98\system.dat: Error while loading hive".  System.dat should be okay since I've just built the Win98 system, exported its registry tree, and copied these files to a USB drive using alternative boot disk (WinPE).  Magic Jelly Bean could not load this hive file...  So...  A really basic question...  I assume that I can load an old registry format file in regedit on a Vista or WinXP computer.  Is that right?  I tried to get more information, so I wrote a quick C++ CLI program.  When I used RegLoadFile on this registry file, it reported "Failed with error 1017.  The system has attempted to load or restore a flie into the registry, but the specified file is not in a registry file format."  Assuming that the files are not corrupted, I am at a loss as to what is going on...  Help, Please! :)  Ultimately, I need to write a program that will open any offline version of registry files on Vista or WinXp computers and need to figure out if there are any special procedures when working with older registry files on newer versions of Windows...

Thanks for your help,

Question by:mjgardne
  • 4
  • 3

Author Comment

ID: 24145751
An error message generated by Registry Tool.
LVL 44

Expert Comment

ID: 24150269
Win98/Me is ASCII based, VIsta is UNICODE based.
That might be part of your problem.

I guess Microsoft has also changed the format of the registry files - so basically you would need to convert the old registry hive into the new format.

Author Comment

ID: 24150790
Hi Andy,

Hmmmmm...  I did some more research and I found something that mentioned that the system.dat file is a pure branch from the registry and as such it cannot be mounted in the normal way under a key that I create...  Have you heard anything about this?  At MSDN, they say that there are two registry formats, but they said/implied (been a few days) that things were backwardly compatible.  This is why I expected RegLoadFile to work.  I know that W9x is no longer supported, but I would expect that whatever functionality existed in the past would have been kept in place...  I would love to learn how people accessed SYSTEM.DAT in the past before WinNT.  I wonder if I call RegLoadFile without a mount point, what would happen....
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

LVL 44

Expert Comment

ID: 24151356
Sorry, I don't know the registry in such detail.

I think for loading into another op system one should use the functionality to export a branch to a .reg file and then import that (textual) file.

Author Comment

ID: 24151574
...  Yeah, I thought about that but it does not meet our requirements.  We repair and upgrade computers and often receive old, dead machines... So, it is not possible to use import and export on them.  I've tried to remove the old hard drive and place it into our WinXP shop computer, but it will not permit us to load the old Win9X/Me system.dat files via regedit.  Argggg... There must be some way to accomplish this feat!  :)   I suspect  that RegLoadFile() could be used, but with a special mounting point or something.
LVL 12

Accepted Solution

Gideon7 earned 300 total points
ID: 24153146
The Win9x registry format is completely different from the NT/W2K/XP format.   There is no supported way of reading a Win9x registry hive on NT/W2K/XP.  RegLoadFile will not work.
LVL 44

Assisted Solution

AndyAinscow earned 200 total points
ID: 24154761
Have a functional PC on your side with Win 98 - use that to import the registry hive

Author Closing Comment

ID: 31570317
I am dumbfounded that there are no Microsoft system calls to load old registry hives, but what it, is...  I did find technical details on the internal structure of the old .DAT files, so it is feasible to write code to process them, but the cost of implementation just isn't justified.  The answer that both contributors gave about not being able to access .DAT files from new versions of the OS is correct and accepted.  Andy's work-around is also what we have done...  We've built a WinMe machine and made an image of it.  If we desperately need to access or export an old .DAT file, it will be possible through the image file.  It still is amazing that there are not any system libraries that could be used...  Oh, well... Live and learn! :)

Thanks for the help, gang!  :)


Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction: The undo support, implementing a stack. Continuing from the eigth article about sudoku.   We need a mechanism to keep track of the digits entered so as to implement an undo mechanism.  This should be a ‘Last In First Out’ collec…
Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
The viewer will learn how to use and create new code templates in NetBeans IDE 8.0 for Windows.

679 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question