Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re^2: registry dump to file output differs from DOS cli and system ?

by gepebril69 (Scribe)
on Mar 05, 2015 at 13:18 UTC ( [id://1118892]=note: print w/replies, xml ) Need Help??


in reply to Re: registry dump to file output differs from DOS cli and system ?
in thread registry dump to file output differs from DOS cli and system ?

Hi L*

Thanks for your reply. I based this /y option on info found on this webpage: https://technet.microsoft.com/en-us/library/cc742017.aspx

Unfortunately removing /y option gave the same result.

The reg command seems interesting. Unfortunately, it seems you can only export one key at the time, the sum of all 5 keys was 80Mb more that a regular registry dump

further on it seems that regedit /e only dumps two keys: HKEY_LOCAL_MACHINE and HKEY_USERS, not the other base keys. This is as CLI and in Perl. Will try to run a diff to see what is missing in Perl -> system......

Is it possible to see what call Perl sends to Windows to figure out why there are two different results....

  • Comment on Re^2: registry dump to file output differs from DOS cli and system ?

Replies are listed 'Best First'.
Re^3: registry dump to file output differs from DOS cli and system ?
by Discipulus (Canon) on Mar 06, 2015 at 08:25 UTC
    The link you provided is for REG command not REGEDIT
    y>reg export HKLM cmd.reg Operation completed succesfully. lt@MC-TAVIANI:y>perl -e "system qq(reg export HKLM perl.reg)" Operation completed succesfully. y>dir *.reg Directory y:\ 06/03/2015 08:54 191.906.582 cmd.reg 06/03/2015 08:54 191.906.582 perl.reg
    Anyway you can simply do something to dump all root keys:
    my @rootk = qw(HKLM HKCU HKU HKCR); foreach my $root ( @rootk ) { my $ile = $root.'.reg'; system qq(reg export $root $file); }
    That said untill now there is nothing about Perl in this thread.. So if we want something perlish as solution you can try Win32::TieRegistry: is stable, updated, and i use it since 10+ years to remotely create ODBC on winz systems. Looping all the keys with Win32::TieRegistry (or the name is Win32::TyeRegistry ? ;=) ) and write a Config::INI file, double quoting all strings, seems a feasible way

    HtH
    L*
    There are no rules, there are no thumbs..
    Reinvent the wheel, then learn The Wheel; may be one day you reinvent one of THE WHEELS.
      @L* Thank you for the suggestion. The registry dump is not for me but a third party which needs it for further investigation. So I prefer regedit /e, but maybe it's time for something new.... I think they only need one key I know the Win32::TieRegistry and start using it two months ago. Great module to extract all kind of data from M$

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1118892]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others lurking in the Monastery: (5)
As of 2024-04-23 07:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found