Resolve multiple IPv4 addresses by a hostname

438 views Asked by At

I have different hosts in a network and want their IP addresses. (They are known by their hostname address, i.e. foo.local) I found several tools und programs which find one IPv4 address, which is "the first one found" and this can also be a link locale address, which doesn't fit to my implementation. Since I need this for a program, a library or a program with parseable output would be necessary.

Why am I not using the default DNS module? It doesn't seem to work with .local hostnames and the network doesn't necessarily have a DNS server / router.

OS is Ubuntu, platform is node.js.

Multicast DNS might be the answer here, but haven't found a reliable module or other implementation yet. All my devices with hostname to resolve are supporting multicast DNS.

0

There are 0 answers