filmov
tv
Automate Network Interface Prioritization in Windows 10 11 with PowerShell
Показать описание
Learn how to automate network interface prioritization in Windows 10/11 using PowerShell. Follow this guide to configure interface metrics for optimal network traffic management with a single script.
# Open PowerShell as Administrator and run the following script
# List all network interfaces (Optional, for reference)
Get-NetIPInterface
# Set the metric for Interface1 (Preferred Interface)
Set-NetIPInterface -InterfaceAlias "Interface1" -InterfaceMetric 10
# Set the metric for Interface2 (Secondary Interface)
Set-NetIPInterface -InterfaceAlias "Interface2" -InterfaceMetric 20
# Verify the metrics to ensure the changes have been applied
Get-NetIPInterface | Select-Object InterfaceAlias, InterfaceMetric
# Open PowerShell as Administrator and run the following script
# List all network interfaces (Optional, for reference)
Get-NetIPInterface
# Set the metric for Interface1 (Preferred Interface)
Set-NetIPInterface -InterfaceAlias "Interface1" -InterfaceMetric 10
# Set the metric for Interface2 (Secondary Interface)
Set-NetIPInterface -InterfaceAlias "Interface2" -InterfaceMetric 20
# Verify the metrics to ensure the changes have been applied
Get-NetIPInterface | Select-Object InterfaceAlias, InterfaceMetric