I'm using K2000 to deploy an image, and part of the postinstallation is to execute "Winpe.exe" file, but I found out that Windows 7 needs to run it as admin. So if anybody has a script that allowing me to do this. Thank you so Much!!

0 Comments   [ + ] Show Comments

Comments

Please log in to comment

Answers

0

Add autologon to your sysprep for admin and then have the task run as a post task.

  <AutoLogon>
                <Password>
                    <Value>*****************</Value>
                    <PlainText>false</PlainText>
                </Password>
                <Enabled>true</Enabled>
                <LogonCount>1</LogonCount>
                <Username>administrator</Username>
            </AutoLogon>

or add it to your post task to autologin and run the task or poke to runonce to run it after reboot.

start /wait reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\WinLogon" /v AutoAdminLogon /d 1  /f
start /wait reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\WinLogon" /v AutoLogonCount /t REG_DWORD /d 2  /f
start /wait reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\WinLogon" /v DefaultUserName /d administrator  /f
start /wait reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\WinLogon" /v DefaultPassWord /d *****  /f

start /wait winpe

or

start /wait reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\WinLogon" /v AutoAdminLogon /d 1 /f
start /wait reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\WinLogon" /v AutoLogonCount /t REG_DWORD /d 1  /f
start /wait reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\WinLogon" /v DefaultUserName /d administrator /f
start /wait reg.exe add "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\WinLogon" /v DefaultPassWord /d ***** /f

start /wait reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce" /v Runwinpe /d winpe.exe

 

Answered 08/06/2012 by: SMal.tmcc
Red Belt

  • Isn't ever post install task on the K2 ran as admin already?
  • I think in windows 7 unless you set an autologin for someone else it runs as the secondary admin account you created during install.
  • never ran winpe as post, are you repacking the install for VAR/OEM distribution?
Please log in to comment
Answer this question or Comment on this question for clarity