You run a Windows Server 2012 R2, what is the PowerShell command to set preferred dns server.
Note: Other config such as ip address should not be changed.
A.
Register-DnsClient
B.
Set-DnsClient
C.
Set-DnsPreferredClientServerAddress
D.
Set-DnsClientServerAddress
D is correct: https://technet.microsoft.com/en-us/library/jj590768(v=wps.630).aspx
From your link
Detailed Description
The Set-DnsClientServerAddress cmdlet sets one or more IP addresses for DNS servers associated with an interface. This cmdlet statically adds DNS server addresses to the interface. If this cmdlet is used to add DNS servers to the interface, then the DNS servers will override any DHCP configuration for that interface.
Doesn’t this override the settings?
why not RegisterDNS? https://technet.microsoft.com/en-us/library/jj553810.aspx