PowerShell for Windows Admins:

DNS

1

October 30, 2015  11:37 AM

Creating DNS records

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
DNS, Powershell

Following on from my previous post about creating a reverse lookup zone in DNS here’s a function to create records in that zone. The function takes an IP address and name (of host) and uses Add-DnsServerResourceRecordA  to add the record to the forward lookup zone – I use my default AD...

October 30, 2015  11:36 AM

Create a reverse lookup zone

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
DNS, Powershell

I needed to create a DNS reverse lookup zone for my test environment. With Windows Server 2012 R2 I’ve got cmdlets available for managing DNS servers – the DnsServer module. You need to install the DNS role or the DNS RSAT tools to get access to the module.   To create a new reverse...


October 13, 2015  10:38 AM

NSlookup in PowerShell

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
DNS, Powershell

nslookup.exe is a command line executable that is used to discover the IP address of a remote machine from its FQDN. The results look something like this: PS> nslookup powershell.org DNS request timed out. timeout was 2 seconds. Server:  UnKnown Address: ...


September 29, 2015  5:32 AM

Error handling for DNS lookups

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
DNS, Powershell

Interesting question on the forum regarding the Resolve-DNSname cmdlet. This is part of the DNSclient module introduced with Windows 8. If the DNS record is found everything is good £> Resolve-DnsName W12R2DSC -Server server02 | ft -a 0 Comments     RSS Feed     Email a friend


June 29, 2015  9:12 AM

Parsing ipconfig /displaydns with regular expressions

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
DNS, Powershell

In yesterdays post I used a series of split operations to parse the strings produced by ipconfig /displaydns   Regular expressions should give a more power full way to perform this task. Not being a big fan of regular expressions I tend not to use them but for the sake of experimentation...


June 28, 2015  1:53 PM

Parsing ipconfig /displaydns

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
DNS, Powershell

  A recent question on the forum asked how you could get the contents on Windows 7 machines and earlier. On later machines – Windows 8 and above -  its easy because you can use Get-DnsClientCache from the DnsClient module. This module is based on CIM classes that aren’t present...


August 18, 2014  12:53 PM

DNS client settings

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
DNS

Following yesterdays post there are a couple of other cmdlets worth looking at if you want to dig into the DNS settings on your client machines. Get-DnsClient wil show you the DNS relsted settings for all of your network interfaces by default.  To investigate a single...


August 17, 2014  1:02 PM

Have you been talking to strangers?

Richard Siddaway Richard Siddaway Profile: Richard Siddaway
DNS

Want to know the machines to which your machine has been connecting?   Try looking in the client DNS cache:   Get-DnsClientCache   will show a wealth of useful data.  All in the form: £> Get-DnsClientCache | where Entry -like '*www.intelliweather.net*' | fl...


1

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to: