Posted On March 31, 2019

ipToHostname

kimconnect 0 comments
blog.KimConnect.com >> Codes >> ipToHostname
Get-Content C:\Users\kimconnect\Desktop\ipList.txt | ForEach-Object {([system.net.dns]::GetHostByAddress($_)).hostname}

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Post

PowerShell: Get IP’s From Computer Names

Resolve from Names to IPs: $names=@( 'TESTVM001', 'TESTVM002', 'TESTVM003' ) foreach($name in $names){ $ips =…

Basic HTML and HTML5: Add a Submit Button to a Form

<h2>CatPhotoApp</h2><main><p>Click here to view more <a href="#">cat photos</a>.</p><a href="#"><img src="https://bit.ly/fcc-relaxing-cat" alt="A cute orange cat lying…

PowerShell: Discover Domain Controllers and Classify Each As VM or Physical

Current Version $dcObjects=Get-ADDomainController -Filter * | select Name,OperationMasterRolesforeach ($dc in $dcObjects){ $dcName=$dc.Name $dcRole=$dc.OperationMasterRoles try{ $machineModel=(Get-WmiObject…