How do I get a list of the active IP-addresses, MAC-addresses and NetBIOS names on the LAN?

前端 未结 5 1191
北恋
北恋 2021-01-06 09:42

How do I get a list of the active IP-addresses, MAC-addresses and NetBIOS names on the LAN?

I\'d like to get NetBIOS name, IP and MAC addresses for every host on the

5条回答
  •  半阙折子戏
    2021-01-06 10:27

    In PowerShell:

    function Explore-Net($subnet, [int[]]$range){
        $range | % { test-connection "$subnet.$_" -count 1 -erroraction silentlycontinue} | select -Property address | % {[net.dns]::gethostbyaddress($_.address)}
    }
    

    Example:

    Explore-Net 192.168.2 @(3..10)
    

提交回复
热议问题