Quantcast
Channel: Microsoft – JeffOps
Viewing all articles
Browse latest Browse all 120

PowerShell – Is my NIC configured to register in DNS?

$
0
0

Some time ago I got asked how one could find if a network interface card (NIC) is configured to register itself in DNS.
In the GUI it’s a checkbox, a little hidden and you have to click a bit to find it.
The intention was to do an inventory of the environment to see which servers were properly configured.

So, PowerShell to the resque yet again :-)

$NIC = Get-WmiObject Win32_NetworkAdapterConfiguration | Where-Object {$_.IPEnabled -eq "True"}
$NIC.FullDNSRegistrationEnabled

This works for PowerShell v1 and v2 but in v3 you can do this with a simple oneliner:

(Get-WmiObject Win32_NetworkAdapterConfiguration | Where-Object {$_.IPEnabled -eq "True"}).FullDNSRegistrationEnabled

Post to Twitter


Viewing all articles
Browse latest Browse all 120

Trending Articles