Skip to main content

PowerShell command to get the fully-qualified local machine's DNS name.

[System.Net.DNS]::GetHostByName('').HostName