PowerTip: Use PowerShell to Get DNS Settings

PowerTip: Use PowerShell to Get DNS Settings

  • Comments 7
  • Likes

Summary: Use Windows PowerShell to retrieve local DNS server addresses.

Hey, Scripting Guy! Question With IPconfig, I used to pipe output to the FIND command to filter only DNS information.
          Is there a better way to do this in Windows Server 2012 R2?

Hey, Scripting Guy! Answer Use the Get-DnsClientServerAddress cmdlet:

Get-DnsClientServerAddress | Select-Object –ExpandProperty ServerAddresses

Your comment has been posted.   Close
Thank you, your comment requires moderation so it may take a while to appear.   Close
Leave a Comment