InetAddress.getLocalHost() throws UnknownHostException
In good tradition, I can answer my own question once again: It seems that InetAddress.getLocalHost() ignores the /etc/resolv.conf, but only looks at the /etc/hosts file (where I hadn’t specified anything besides localhost). Adding the IP and hostname to this file solves the problem and the exception is gone. Another answer is almost correct and I … Read more