import full registry

Z

zirath

I have a backup of the full registry that I'm trying to import but I keep
getting the error message (in windows mode) that some of the keys are open
so the file can't be imported.

I saw several webpages that claim you can use "regedit" or reg.exe from the
(xp) dos mode but I get the error message that those programs can't be run
in dos mode.

Is there a program that can be run from (xp) dos mode to edit the registry?

Thanks.
 
D

DL

Is this because you created a reg backup, then edited your registry & are
tryng to undo the edit, or is there something else going on?
 
J

John John (MVP)

That is pretty well expected behaviour, you can't use Regedit's Export
function as a backup for the full registry, you will not be able to
import the full registry in that manner. To put it plain and simply you
used the wrong backup method and there isn't much you can do unless you
want to edit the export file and remove the entries that would be in
use. The message that you are getting when you try to import the file
is also not completely accurate, the message states that the registry
file cannot be imported but it is imported and the keys that are not
inuse will be restored, the second part of the error message; "Not all
data was successfully written to the registry", sort of lets you know
that "some" data was written to the registry.

Also, there is no DOS in Windows XP, what you see at the Command Prompt
(cmd.exe) isn't DOS at all. At the command prompt you can use the REG
command's import function to import the file:

reg import filename.reg

But you will pretty well run into the same wall when you use REG IMPORT,
except that the error message at the command prompt will be an Access
Denied one.

John
 
Z

zirath

John John (MVP) said:
That is pretty well expected behaviour, you can't use Regedit's Export
function as a backup for the full registry, you will not be able to import
the full registry in that manner. To put it plain and simply you used the
wrong backup method and there isn't much you can do unless you want to
edit the export file and remove the entries that would be in use. The
message that you are getting when you try to import the file is also not
completely accurate, the message states that the registry file cannot be
imported but it is imported and the keys that are not inuse will be
restored, the second part of the error message; "Not all data was
successfully written to the registry", sort of lets you know that "some"
data was written to the registry.

Also, there is no DOS in Windows XP, what you see at the Command Prompt
(cmd.exe) isn't DOS at all. At the command prompt you can use the REG
command's import function to import the file:

reg import filename.reg

But you will pretty well run into the same wall when you use REG IMPORT,
except that the error message at the command prompt will be an Access
Denied one.

John

I had created an xp floppy boot disk (using "create msdos startup disk" in
"format" a:) and tried using "reg import file" and it gave the error that
the program could not be run in dos mode.
 
Z

zirath

I had created an xp floppy boot disk (using "create msdos startup disk" in
"format" a:) and tried using "reg import file" and it gave the error that
the program could not be run in dos mode.

I now see part of the problem:

I had partitioned the hard drive and am using the 2nd partition as the boot
(active). The floppy, for some reason, is not recognizing the 2nd partition
and is using the 1st one as the c: drive. (It isn't seeing the 2nd partition
at all and there is no drive letter assigned to it.)
 
J

John John (MVP)

zirath said:
I had created an xp floppy boot disk (using "create msdos startup disk" in
"format" a:) and tried using "reg import file" and it gave the error that
the program could not be run in dos mode.

Of course not. The NT registry APIs are all 32-bit, MS-DOS wouldn't
have the foggiest notion what to do with this.

http://support.microsoft.com/kb/137378

John
 
J

John John (MVP)

zirath said:
I now see part of the problem:

I had partitioned the hard drive and am using the 2nd partition as the boot
(active). The floppy, for some reason, is not recognizing the 2nd partition
and is using the 1st one as the c: drive. (It isn't seeing the 2nd partition
at all and there is no drive letter assigned to it.)

The partition is most likely using the NTFS format, that is probably why
MS-DOS doesn't recognize it.

John
 
T

Twayne

I have a backup of the full registry that I'm trying to import but I
keep getting the error message (in windows mode) that some of the
keys are open so the file can't be imported.

I saw several webpages that claim you can use "regedit" or reg.exe
from the (xp) dos mode but I get the error message that those
programs can't be run in dos mode.

Is there a program that can be run from (xp) dos mode to edit the
registry?
Thanks.

Ouch! That's not the right thing to do. As you've found, you can not
export, then import, the whole registry. It's a long story why, so I'll
leave the research to you, but suffice to say that parts of the registry
probably ARE being imported, and what you are getting is multiple,
duplicate entries in your registry now. If you tried ti again, you got
3 set, then 4, and so on. You registry is most likely a real mess now.
If it's not causing you any problems, you might be able to just ignore
it and continue on using the computer that way; I'd guess you're not
seeing any real problems from your playing around with the import
feature; at least you didn't say you had any.
The registry is really meant to simply export and import single keys
or maybe groups of keys. You export what you're going to change, so if
you screw it up, you can import that part back and get back working
again.

The proper way to back up a registry is to save the "system state".
THAT can be restored.

I'm not sure what to tell you; AFAIK there are no apps to easily
straighten that out. The best way is going to be a clean reinstall and
rebuild of your boot drive I'm sorry to say.

You might try booting to the boot menu and choose the "last known good
configuation" and see if that takes care of any problems the importing
caused. If any.

You might also try a System Restore from Accessories, System Tools,
System Restore. Go back in time to 2 or more days before you made
changes to the registry and see if that helps straighten out any
problems you're having.

But if things are running OK and just as they always have, quit trying
to Import and read in Help about backing up the System State instead.
Also read about the registry while you're at it, just for your own
edification. Online research for "registry" would be advisable too if
you're at all interested.

HTH

Twayne
 
J

John John (MVP)

Twayne said:
Ouch! That's not the right thing to do. As you've found, you can not
export, then import, the whole registry. It's a long story why, so I'll
leave the research to you, but suffice to say that parts of the registry
probably ARE being imported, and what you are getting is multiple,
duplicate entries in your registry now. If you tried ti again, you got
3 set, then 4, and so on.

No, you will not, the registry cannot have duplicate entries. You can
import or merge a .reg file 154 times if you want but you will still not
have any duplicate entries in the registry.

John
 
B

Bill in Co.

John said:
No, you will not, the registry cannot have duplicate entries. You can
import or merge a .reg file 154 times if you want but you will still not
have any duplicate entries in the registry.

John

And *merging* a newer reg file (even a complete one) cannot restore the
registry fully to the prior version. It just merges the two, and any keys
that were already there from before will still be there now (except for
those keys which are overwritten (and they all won't be).
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top