Forum Discussion
chohman595
Aug 26, 2020Copper Contributor
A Strange DNS Result
Trying to collect some DNS information for some maintenance work, I ran into this: Get-DnsServerResourceRecord -computername myDC -ZoneName contoso.com -rrtype A
gives
HostName RecordTy...
Sep 07, 2020
Hi chohman595
IPv4Address isn't a string value in RecordData. That's the what you are missing.
Could you try that way?
Get-DnsServerResourceRecord -ComputerName myDC -ZoneName "contoso.com" -RRType A | Select-Object Hostname,@{Name="IPv4Address";Expression={$_.RecordData.IPv4Address.IPAddressToString }}
Thanks.