Tag Archives: dns

A little while ago we have some issues with one of our Exchange environments. The symptoms was that basically everything was slow, opening address books, owa, sending mails and so on. After some digging it occurred to me that this may be DNS related, so I used a one-liner in powershell to see how fast our DNS servers responded: Measure-Command {Resolve-DnsName google.com -DnsOnly -Type A -NoHostsFile -server x.x.x.x} And sure enough, we were seeing response times in the range of 5-7 seconds. Way more than enough to cause our problems. After rebooting the DNS servers ours problems disappeared. But, as always, I had to play around with created a powershell function. The function resolves a few records from locally defined DNS servers and some publicly available DNS servers (or a custom list if you want) and measures the average latency (in milliseconds). The results are put in a list and…

Read more

I don’t know how useful this will be for others, but in our case we had a need to check a few public dns records on some of our domains. Doing so by using a web portal will be time consuming and straight out boring. Luckily you can use Powershell for such things: First we need to to save our domains in an array: $domains = @(“domainA.com”, “domainB.com”, “domainC.com”) Then we send that array into a foreach loop: foreach ($element in $domains) { Resolve-DnsName -server record.$($element) } You might notice that I use Google’s public dns servere here, but you can use whatever dns server you want, or just leave the -server part out. The example above is pretty basic and only checks for an A record. In our case we needed to check several SRV records for each of the domains, so I had to extend the script…

Read more

SmtpDiag is a nifty little tool for diagnosing any smtp or dns issues on your mailserver. Usage: smtpdiag <sender emailaddress> <recipient emailaddress> SmtpDiag