This afternoon I quickly setup enough infrastructure on my test server to enable it to use Multicast DNS to resolve local names and answer local queries. Multicast DNS is part of the Zeroconf specification, which Apple has implemented and refers to as Rendezvous.
In order for this to work, your system needs to both answer and perform multicast DNS queries. The two pieces you need for this are:
- mDNSResponder: From Apple, and covered under the APSL, but included in [Porchdog Software]‘s Howl package.
- nss-mdns: Written by Lennart Poettering, provides a plugin for the GNU Name Service Switch (NSS) functionality of the GNU C Library (glibc) providing host name resolution via Multicast DNS
0.3, nss-mdns is already Debian-ready, simply build a package executing
fakeroot dpkg-buildpackage from the unpacked tarball. There is an mDNSResponder package in Sarge which is rumored to be removed shortly due to license problems with APSL, so grab a copy soon.
Once these are installed, simply add
mdns to the
hosts line of
/etc/nsswitch.conf and you’re done.
You will now be able to resolve “.local” hosts from your Debian system and also resolve this system’s hostname on other local hosts. By editing
/etc/mdnsresponder/mDNSResponder.conf, you can advertise any service you want.