Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # This is a tiny little script which disables power management on every NIC (Wired/Wireless)
- # The script is searching for "PCI" (to only match "real" NICs, not virtual ones like e.g. the ISATAP Adapter...) in
- # HKLM\SYSTEM\CurrentControlSet\Control\Class\{4D36E972-E325-11CE-BFC1-08002BE10318}
- # (which is the default location for NIC related settings) and adds the DWORD "PnPCapabilities" with the Value 56 (decimal) to disable the power management.
- #
- # Works on XP/Server 2003, Vista/Server 2008, Windows 7/Server 2008 R2, Windows 8/Server 2012/Server 2016 and Windows v.Next :-)
- # In order to run this script you might need to change the Powershell Script Execution Policy. Type "get-help about_signing" in a Powershell Window for more information.
- #
- # Version 1.0
- # USE TOTALLY AT YOUR OWN RISK!
- $SearchString = "PCI"
- dir 'HKLM:\SYSTEM\CurrentControlSet\Control\Class\{4D36E972-E325-11CE-BFC1-08002BE10318}' -rec -ea SilentlyContinue |
- ForEach-Object {
- if((get-itemproperty -Path $_.PsPath) -match $SearchString)
- {
- $_.PsPath
- Set-ItemProperty -path $_.PsPath -Type DWord -Name PnPCapabilities -Value 56
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement