Jump to content

Recommended Posts

Posted

For Windows 7 we have a script which speeds up logon times by deleting registry entries in the Active Setup section:

 

"HKEY_LOCAL_MACHINE\Software\Microsoft\Active Setup\Installed Components" & HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Active Setup\Installed Components

 

The script is:

 

echo Querying and deleting 32bit STUB paths...

setlocal EnableDelayedExpansion

:: Queries the registry and searches for specific strings. In this case 'STUBPATH'

set KEY="HKEY_LOCAL_MACHINE\Software\Microsoft\Active Setup\Installed Components"

set FND=find /i %KEY%

for /f "Tokens=*" %%a in ('reg query %KEY% /s^|%FND%') do (

set SP=N

for /f "tokens=*" %%b in ('reg query "%%a"^|find /i " STUBPATH"^|find "REG_"') do (

set SP=Y

)

:: Runs an if statement, stating that if a key matching 'STUBPATH' is true, it should be deleted.

if "!SP!" EQU "Y" reg delete "%%a" /V STUBPATH /F

)

echo Querying and deleting 64bit STUB paths...

endlocal

setlocal EnableDelayedExpansion

:: Queries the registry and searches for specific strings. In this case 'STUBPATH'

set KEY="HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Active Setup\Installed Components"

set FND=find /i %KEY%

for /f "Tokens=*" %%a in ('reg query %KEY% /s^|%FND%') do (

set SP=N

for /f "tokens=*" %%b in ('reg query "%%a"^|find /i " STUBPATH"^|find "REG_"') do (

set SP=Y

)

:: Runs an if statement, stating that if a key matching 'STUBPATH' is found, it should be deleted.

if "!SP!" EQU "Y" reg delete "%%a" /V STUBPATH /F

)

endlocal

 

 

Has anyone found any need to retain these registry keys in Windows 10 or can they be safely deleted to speed up Windows 10 logon times?

 

Cheers

  • 9 months later...
Posted
@kennysarmy I'm curious, did you find an anwser to this? Just looking to see if I can clear out some stubpaths myself.

 

We deleted them I think and found no issues in Windows 10 - though we're only at the testing stage still....no plans to roll out Windows 10 until next year.

 

Cheers

  • Thanks 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...