How to change registry in mounted image?
#21
Posted 02 August 2011 - 09:23 AM
Ad HKCU - I realized it's just a subkey of HKLM in offline image, so I am just using HKEY_LOCAL_MACHINE\WIM_Software\Classes. That is right, hm?
#22
Posted 03 August 2011 - 12:15 AM
http://social.techne...dc-9617d5fe3347
Other example: Edit the registry on a mounted WIM.
http://blogs.technet...ounted-wim.aspx
About Windows Registry:
http://en.wikipedia....indows_Registry
#23
Posted 03 August 2011 - 12:21 AM
dencorso, on 31 July 2011 - 07:40 PM, said:
While I wrote that with unmounted hives from other profiles in the same system, it of course applies to any unmounted hives, so certainly a mounted WIM image qualifies, too.
#24
Posted 03 August 2011 - 12:36 AM
dencorso, on 03 August 2011 - 12:21 AM, said:
dencorso, on 31 July 2011 - 07:40 PM, said:
While I wrote that with unmounted hives from other profiles in the same system, it of course applies to any unmounted hives, so certainly a mounted WIM image qualifies, too.
With all due respect
- RAWREG is unfinished (and severely bugged
) work - The already mentioned Offline Registry uses a MS freely available Library and is command line, i.e. an exact correspondent to what was asked (command line editing).
Whether a command line app is less friendly than a GUI app is of course well debatable.
jaclaz
This post has been edited by jaclaz: 03 August 2011 - 12:36 AM
#25
Posted 03 August 2011 - 01:06 AM
jaclaz, on 03 August 2011 - 12:36 AM, said:
I know... but it's handy, all the same, provided it's used just to peruse the hives, not to edit them.
jaclaz, on 03 August 2011 - 12:36 AM, said:
Well... that's the problem with quoting, instead of writing from scratch: some things get out of context. That comment was addressed to Dave-H, in the thread that quote originated from, not to the OP of the present thread, who asked for a command-line tool. My, bad. Sorry!
#26
Posted 03 August 2011 - 02:58 AM
edit: the /s switch does nothing, I am not getting any splash screens at all anyway...
This post has been edited by TheWalrus: 03 August 2011 - 03:08 AM
#27
Posted 03 August 2011 - 11:47 AM
You need first to create a folder (Example: C:\DISM_Temp) and place your reg files inside!
Example (adapt the name and paths to your needs):
Walrus.cmd
@echo off & color 1F "C:\Program Files\Windows AIK\Tools\x86\Servicing\Dism.exe" /Mount-Wim /Wimfile:"C:\Win7\sources\install.wim" /index:1 /MountDir:"C:\zMount" >nul timeout /t 3 reg.exe load HKLM\WIM_Default "C:\zMount\Users\Default\NTUSER.DAT" reg.exe load HKLM\WIM_Software "C:\zMount\Windows\System32\config\SOFTWARE" reg.exe load HKLM\WIM_System "C:\zMount\Windows\System32\config\SYSTEM" >nul timeout /t 3 reg.exe import "C:\DISM_Temp\User.reg" reg.exe import "C:\DISM_Temp\Perso.reg" reg.exe import "C:\DISM_Temp\Context_Menu.reg" reg.exe import "C:\DISM_Temp\System.reg" pause to see the result inside the mounted hives >nul timeout /t 3 echo. reg.exe unload HKLM\WIM_Default reg.exe unload HKLM\WIM_Software reg.exe unload HKLM\WIM_System echo. "C:\Program Files\Windows AIK\Tools\x86\Servicing\Dism.exe" /Unmount-Wim /MountDir:"C:\zMount" /Commit echo. echo ==Appuyez sur n'importe qu'elle touche pour quitter==&pause>nul
Inside C:\DISM_Temp place all you reg files (Example):
User.reg
Perso.reg
Context_Menu.reg
System.reg
Output command window Result.txt
Image Mounted Hives
One error corrected inside your reg file.
Your reg files attached!
This post has been edited by myselfidem: 03 August 2011 - 11:57 AM
#28
Posted 03 August 2011 - 03:07 PM
This is what I have in my batch file:
@echo off Color 0A echo mounting the image dism /mount-wim /wimfile:e:\Win7\sources\install.wim /index:1 /mountdir:e:\mount\ echo removing some minor s*** files rd "e:\mount\Users\Administrator\Favorites\Links" /s /q rd "e:\mount\Users\Administrator\Favorites\Microsoft Websites" /s /q rd "e:\mount\Users\Administrator\Favorites\MSN Websites" /s /q rd "e:\mount\Users\Administrator\Favorites\Windows Live" /s /q rd "e:\mount\Users\Public\Music\Sample Music" /s /q rd "e:\mount\Users\Public\Pictures\Sample Pictures" /s /q rd "e:\mount\Users\Public\Recorded TV\Sample Media" /s /q rd "e:\mount\Users\Public\Videos\Sample Videos" /s /q echo loading registry from the image reg.exe load HKLM\WIM_Default "e:\mount\Users\Administrator\NTUSER.DAT" reg.exe load HKLM\WIM_Software "e:\mount\Windows\System32\config\SOFTWARE" reg.exe load HKLM\WIM_System "e:\mount\Windows\System32\config\SYSTEM" echo importing registry tweaks reg.exe import "e:\tweaks.reg" echo unloading the registry reg.exe unload HKLM\WIM_Default reg.exe unload HKLM\WIM_Software reg.exe unload HKLM\WIM_System echo unmounting and saving the image dism.exe /Unmount-Wim /MountDir:"e:\mount" /Commit pause
edit: what did you change please? I don't know of any simple way of checking the changes.
edit2: why did you break the tweaks into different files, or rather - by what logic?
This post has been edited by TheWalrus: 03 August 2011 - 03:23 PM
#29
Posted 03 August 2011 - 04:03 PM
One stupid key typed slightly wrong. Jeez I'm dumblind... But then again, I've been trying to get this part working for 2 days pretty much nonstop and 3 hours a day worth of sleep is BAD.
I still have one question though: do I really need to use REG_EXPAND_CZ type for those keys that contain variables like for example %systemroot% which I am very fond of lately?
This post has been edited by TheWalrus: 04 August 2011 - 08:29 AM
#30
Posted 04 August 2011 - 07:24 AM
TheWalrus, on 03 August 2011 - 04:03 PM, said:
Yep!
Image Tweaks on mounted hives
*Edit: About switch /s and mmc.exe:
http://www.msfn.org/...post__p__108801
This post has been edited by myselfidem: 04 August 2011 - 03:49 PM
#31
Posted 04 August 2011 - 08:50 AM
(solved now, but still have a question)
#32
Posted 05 August 2011 - 10:17 AM
TheWalrus, on 03 August 2011 - 04:03 PM, said:
One stupid key typed slightly wrong. Jeez I'm dumblind... But then again, I've been trying to get this part working for 2 days pretty much nonstop and 3 hours a day worth of sleep is BAD.
I corrected your error key and I gave you a new reg files inside DISM_Temp.zip!!!!!!
*Edit: Error was CurrentControlSet corrected to ControlSet001 inside one key!
This post has been edited by myselfidem: 05 August 2011 - 10:23 AM
#33
Posted 05 August 2011 - 12:53 PM
Btw I also tried to use a tweak to disable Windows Defender, but that totally screwed the installation process up! No OOBE screen, up to like 15 mins of waiting and then just login window. Weird.
#34
Posted 05 August 2011 - 01:04 PM
<settings pass="specialize">
<DisableAntiSpyware>true</DisableAntiSpyware> (Disables Windows Defender)
This post has been edited by myselfidem: 05 August 2011 - 01:09 PM
#35
Posted 07 August 2011 - 06:09 AM
Apply regtweaks (also HKCU) and install apps for ALL users
http://www.msfn.org/...post__p__955400
#36
Posted 07 August 2011 - 06:50 AM



Help

Back to top









