Zero Configuration Networking

From Funtoo Linux
Revision as of 08:15, 6 November 2010 by Drobbins (Talk)

Jump to: navigation, search

Apple Technical Q&A QA1357

Zero Configuration Networking, also called ZeroConf or Bonjour (Apple's trademark for their Zero Configuration Networking implementation) is


Contents

Link-local Addresses

To use link-local addressing, first set up the proper routes:

route add default dev eth0 metric 99
route add -net 169.254.0.0 netmask 255.255.0.0 dev eth0 metric 99

Then, use avahi-autoipd to discover a valid link-local IP address:

/usr/sbin/avahi-autoipd --daemonize --syslog --wait eth0

mDNS

receiving mDNS

emerge nss-mdns

Set up multicast route:

route add -net 224.0.0.0 netmask 240.0.0.0 dev eth0

/etc/nsswitch.conf:

hosts:       files mdns_minimal [NOTFOUND=return] dns mdns

Test:

ninja1 ~ # ping daniel-pc.local
PING daniel-pc.local (10.0.1.11) 56(84) bytes of data.
64 bytes from Daniel-PC.local (10.0.1.11): icmp_req=1 ttl=128 time=3.73 ms
64 bytes from Daniel-PC.local (10.0.1.11): icmp_req=2 ttl=128 time=0.905 ms
64 bytes from Daniel-PC.local (10.0.1.11): icmp_req=3 ttl=128 time=0.922 ms
64 bytes from Daniel-PC.local (10.0.1.11): icmp_req=4 ttl=128 time=0.827 ms

Sending mDNS/DNS-sd

rc-update add avahi-daemon default
rc

Service Discovery

Get a list of services on the LAN:

ninja1 ~ # avahi-browse -ac
Personal tools
Namespaces

Variants
Actions
Categories
Toolbox
Stuff