6/26/2023 0 Comments Find computer name by mac address![]() Select Name > C:\Users\(user)\Desktop\Computers. Last bit, this is the part I use to create a list of all computers in the Active Directory. $c > (Import-Csv -Delimiter "C:\Users\admin_stagiair\Desktop\online.txt") $Computers = Import-Csv C:\Users\admin_stagiair\Desktop\Computers.txt ![]() $result | Export-Csv C:\Users\admin_stagiair\Desktop\Computers.csv -Delimiter " " -NoTypeInformationĪnd this is the part that I tried to make search the list and filter out the online computers, which absolutely does not work and I can't figure out how to do it. $x = New-Object System.Object | select ComputerName, MAC Get-WmiObject Win32_NetworkAdapterConfiguration -Filter 'ipenabled = "true"' $Computers = Import-CSV C:\Users\admin_stagiair\Desktop\Computers.txt ![]() Click the Apple logo in the top left corner, and then select System Preferences from the Apple Menu. Just type hostname into the Command Prompt and hit Enter, you’ll see your computer name immediately. This is the part that searches the list I create with hostnames. Another way of finding computer name is using the Command Prompt. The point is that I have to make a list of hostnames, which I can do, but then the other script runs into a problem because some computers are not online.Ĭan anyone help me get a list with only the pc's that are online? That's why I already used a small script from someone else. I know that MAC addresses are not in the Activce Directory. I'm trying to get the hostname and the MAC address from all PCs in the Active Directory.
0 Comments
Leave a Reply. |