Sometime it is very hard to register a computer account to the WSUS. Use the following script to make sure a computer is registered to WSUS:
net stop wuauserv
REG DELETE "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v NextDetectionTime /f
REG DELETE "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate" /v SusClientId /f
REG DELETE "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate" /v SusClientIdValidation /f
net start wuauserv
wuauclt /resetauthorization /detectnow
Note: you can also use this script to your ESX VI customization template to make sure your new VMs deployed from that template has a unique SusClientId
Wednesday, January 28, 2009
Tuesday, January 13, 2009
NTVDM.EXE
For the last 2 weeks, I was stuck with trying to run old MS-DOS application on Windows 2003. It was previously ran on Windows 2000 fine, no problem at all. Suddenly when we migrated this app to Windows 2003, users start complaining that the application randomly freezes on them...
We tried everything we could think of, like setting up the compatibility layer on the batch file before running the app, e.g.
set __COMPAT_LAYER=Win2000 DisableThemes
it did not work...
Finally, we found the solution, it appears that the ntvdm.exe process is running on multiprocessors - which does not work for this particular MS-DOS app. So we need to tell the ntvdm.exe process to run only on uni-processor. To do that:
- backup your original ntvdm.exe file (c:\windows\system32)
- find and download imagecfg.exe (google it)
- copy the ntvdm.exe from the location above to a temp folder
- run: imagecfg.exe -u ntvdm.exe in the temp folder
- copy this new ntvdm.exe to system32, dllcache, servicepack\i386 folders, otherwise the Windows File Protection will replace your modified ntvdm.exe file with the original one
- test it, you will see only a single processor will be used to run ntvdm.exe
We tried everything we could think of, like setting up the compatibility layer on the batch file before running the app, e.g.
set __COMPAT_LAYER=Win2000 DisableThemes
it did not work...
Finally, we found the solution, it appears that the ntvdm.exe process is running on multiprocessors - which does not work for this particular MS-DOS app. So we need to tell the ntvdm.exe process to run only on uni-processor. To do that:
- backup your original ntvdm.exe file (c:\windows\system32)
- find and download imagecfg.exe (google it)
- copy the ntvdm.exe from the location above to a temp folder
- run: imagecfg.exe -u ntvdm.exe in the temp folder
- copy this new ntvdm.exe to system32, dllcache, servicepack\i386 folders, otherwise the Windows File Protection will replace your modified ntvdm.exe file with the original one
- test it, you will see only a single processor will be used to run ntvdm.exe