PoshCode Archive  Artifact [78d42bf940]

Artifact 78d42bf940478c4e6b77ed5da58a60c2603f6e8899596d51d27b98ed06cec826:

  • File Set-DNSServersToOpenDNS.ps1 — part of check-in [e3ae34a7a9] at 2018-06-10 13:30:48 on branch trunk — [One-liner] Sets all the local adapters to point to OpenDns.org’s DNS Servers (user: CrazyDave size: 493)

# encoding: ascii
# api: powershell
# title: Set-DNSServersToOpenDNS
# description: [One-liner] Sets all the local adapters to point to OpenDns.org’s DNS Servers
# version: 0.1
# author: CrazyDave
# license: CC0
# x-poshcode-id: 3769
# x-archived: 2017-03-18T07:48:15
# x-published: 2013-11-16T11:40:00
#
#
Get-WmiObject win32_networkadapterconfiguration -filter "ipenabled = 'true'" | ForEach-Object { 
    $_.SetDNSServerSearchOrder(@("208.67.222.222","208.67.220.220"));
}