[avahi] multiple network interfaces

Lennart Poettering lennart at poettering.net
Tue Nov 6 10:53:09 PST 2007

On Mon, 05.11.07 16:09, Jeff Koftinoff (jeffk at jdkoftinoff.com) wrote:

> Is it possible to have avahi work on multiple ethernet ports?
> I'd like to be able to have redundant physical connections between a  
> system and a switch - each ethernet port would have its own zeroconf  
> ip address, and avahi would respond on all ports with the same
> name...

That's the default behaviour of Avahi.

> So someone doing a gethostbyname() would get multiple A records for  
> the same name, and be able to connect() to any of them. If one  
> connection goes down, a reconnect would go to one of the other ip  
> addresses.

If you do a gethostbyname() right now it's not deterministic which A
you would get, but you'd get exactly one.

Please note however, that mDNS/DNS-SD is not a reliable protocol. It's
not intended do be used for HA solutions.

Also, RRs take quite a time to timeout by default in Avahi. So if you
just pull a cable it might take a while until Avahi removes old
entries from its cache.


Lennart Poettering                        Red Hat, Inc.
lennart [at] poettering [dot] net         ICQ# 11060553
http://0pointer.net/lennart/           GnuPG 0x1A015CC4

More information about the avahi mailing list