Jump to content


  • 0
roshanbhavsar04

How can I change a HKCU setting within Windows during an OSD deployment

Question

Recommended Posts

  • 0

the reg file with Defuser references will only work as part of the workaround i provided.

when you manually run your file it works because you are a user and it's running it in user context,

when you run it as a package it's running in system context and therefore failing.

Share this post


Link to post
Share on other sites

  • 0

Hi, great thread on loading hte user hive. While the first two steps seem to work right (load the hive, apply the userpref.reg file) I'm running into a problem on the third step. My smsts.log file shows this error:

 

Executing command line: smsswd.exe /run: cmd.exe /c reg.exe unload HKEY_LOCAL_MACHINE\defuser c:\users\default\ntuser.dat TSManager 3/13/2014 2:47:58 PM 2768 (0x0AD0)
[ smsswd.exe ] InstallSoftware 3/13/2014 2:47:58 PM 1712 (0x06B0)
PackageID = '' InstallSoftware 3/13/2014 2:47:58 PM 1712 (0x06B0)
BaseVar = '', ContinueOnError='' InstallSoftware 3/13/2014 2:47:58 PM 1712 (0x06B0)
ProgramName = 'cmd.exe /c reg.exe unload HKEY_LOCAL_MACHINE\defuser c:\users\default\ntuser.dat' InstallSoftware 3/13/2014 2:47:58 PM 1712 (0x06B0)
SwdAction = '0001' InstallSoftware 3/13/2014 2:47:58 PM 1712 (0x06B0)
Command line for extension .exe is "%1" %* InstallSoftware 3/13/2014 2:47:58 PM 1712 (0x06B0)
Set command line: Run command line InstallSoftware 3/13/2014 2:47:58 PM 1712 (0x06B0)
Working dir 'not set' InstallSoftware 3/13/2014 2:47:58 PM 1712 (0x06B0)
Executing command line: Run command line InstallSoftware 3/13/2014 2:47:58 PM 1712 (0x06B0)
Process completed with exit code 1 InstallSoftware 3/13/2014 2:47:58 PM 1712 (0x06B0)
ERROR: Invalid syntax. InstallSoftware 3/13/2014 2:47:58 PM 1712 (0x06B0)
Type "REG UNLOAD /?" for usage. InstallSoftware 3/13/2014 2:47:58 PM 1712 (0x06B0)
Command line returned 1 InstallSoftware 3/13/2014 2:47:58 PM 1712 (0x06B0)
Process completed with exit code 1 TSManager 3/13/2014 2:47:58 PM 2768 (0x0AD0)
!--------------------------------------------------------------------------------------------! TSManager 3/13/2014 2:47:58 PM 2768 (0x0AD0)
Failed to run the action: Run Command Line - Unload Default User Hive.
Incorrect function. (Error: 00000001; Source: Windows) TSManager 3/13/2014 2:47:58 PM 2768 (0x0AD0)

 

That invalid syntax is throwing me. I've looked up Reg.exe unload and it seems to be the proper syntax, but it's getting that error. Any thoughts?

 

Thanks!

Share this post


Link to post
Share on other sites

  • 0

This step for me did not work with that command line, I kept on getting the 0x0000001 task sequence error.

 

"in the next step we import the Registry file in another Run Command Line step this Registry file can be a file in a package.

 

cmd.exe /c reg.exe import "Userprefs.reg"

 

but what is now working is:

 

regedit /s "NameOfYourRegFile.reg"

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...



×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.