Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Windows 11 optimizations script #2

Open
sp1nkick opened this issue May 25, 2024 · 3 comments
Open

Windows 11 optimizations script #2

sp1nkick opened this issue May 25, 2024 · 3 comments

Comments

@sp1nkick
Copy link

sp1nkick commented May 25, 2024

Tony, thank you for this script, this appears to be exactly what we are struggling with on a few deployments, users specifically on latest windows 11 enterprise pooled session host note slow speed, back button issues and search issues with the new windows 11 explorer. When I try to use your script it appears the paths are not there. Does this create them? Or should we be using this alongside some other script , or only against the gold desktop image?

When ran as a scripted action:

6aa8241d-1566-4645-86dd-99a5c827af11.zip

Should it be ran as intune/GPO policy against each user instead?

@sp1nkick
Copy link
Author

I think this helps create the registry key if it doesn't exist. I will test if it makes a difference.

`# Function to set registry key value with error handling
function Set-RegistryValue {
param (
[string]$Path,
[string]$Name,
[Object]$Value,
[Microsoft.Win32.RegistryValueKind]$Type
)
try {
if (-not (Test-Path -Path $Path)) {
New-Item -Path $Path -Force | Out-Null
Write-Output "Created registry path: $Path"
}
Set-ItemProperty -Path $Path -Name $Name -Value $Value -Type $Type -ErrorAction Stop
Write-Output "Successfully set $Name to $Value in $Path"
}
catch {
Write-Error "Failed to set $Name in $Path. Error: $_"
}
}

Disabling web search on the start menu makes it so much faster and effective!

Set-RegistryValue -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Search" -Name "BingSearchEnabled" -Value 0 -Type DWord

Speed up File Explorer's slow folder scanning!

Set-RegistryValue -Path "HKCU:\Software\Classes\Local Settings\Software\Microsoft\Windows\Shell\Bags\AllFolders\Shell" -Name "FolderType" -Value "NotSpecified" -Type String
`

@pyasuda
Copy link

pyasuda commented Jul 2, 2024

Question about these and and HKCU in general: Can these settings be made on the image? Or run them at VM deployment?
Thanks!
I should have googled first. Looks like this is more useful with Intune than Scripted Actions. Sigh.

@tonycaidotcom
Copy link
Collaborator

Yes it will stick if you put it on a Golden Image.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants