Code Yarns ‍👨‍💻
Tech Blog ❖ Personal Blog

Find hostname from IP address

📅 2012-Jul-28 ⬩ ✍️ Ashwin Nanjappa ⬩ 🏷️ hostname, ip address, ping ⬩ 📚 Archive

Problem

You know the IP address of a computer. You want to find out the name of the computer or its hostname.

Solution

The humble ping command can resolve the hostname from a IP address. Use the ping -a 172.20.30.40 command to find the hostname of the computer with IP address 172.20.30.40.

Tried with: Windows 7