title: InetAddress.getByName works for unknown host
body: <p>I want to create a java program for reverse DNS check. </p>
  
  <p>When i am using below code to get ip address for a hostname, it displays an ip address but there is no such host machine in my network. Recently i have removed that machine from the network. </p>
  
  <pre><code>InetAddress.getByName("deskmachin2558").getHostAddress()
  </code></pre>
  
  <p>Actually it should throws UnknownHostException but instead it displays an ip. Using the ip or host name, i cannot ping that machine. </p>
  
  <p>How it works actually? Is there any cache stored in the server which returns the ip address for this machine. </p>
  
  <p>Can anyone provide reverse DNS program in Java?</p>
  
  <p>Thanks</p>