When there is a need for retrieve dhcp server info this cmd line can be used.

The method will collect Last logon date and OS version so it can be used for dhcp server migration.

Get-DhcpServerInDC | % { Get-ADComputer -Identity ($_.dnsname).Substring(0, ($_.dnsname).IndexOf(‘.’)-0) -Properties LastLogonDate,OperatingSystem | Select-Object Name,LastLogonDate,OperatingSystem }