title: Trying to get IP Address of network device using hostname
body: <p>I'm trying to resolve the IP Address of a BeagleBone Black device which is on the same network of the Android device running my app. The hostname of my device is <code>"tovremgw.local"</code>. If I try to ping from my windows pc commandline it will successfully return the IPv6 address.</p>
  
  <p>When using the following code:</p>
  
  <pre><code>new Thread(new Runnable(){
          public void run(){
              Inet6Address addr = null;
              try {
                  addr = (Inet6Address) Inet6Address.getByName("tovremgw.local");
              } catch (UnknownHostException e) {
                  e.printStackTrace();
              }
              System.out.println(addr);
          }
      }).start();
  </code></pre>
  
  <p>It will return Exception :</p>
  
  <blockquote>
    <p>"java.net.UnknownHostException: Unable to resolve host
    "tovremgw.local": No address associated with hostname"</p>
  </blockquote>
  
  <p>I'm running the app in an emulator on the same pc i'm pinging the BeagleBone with.</p>