[Pkg-utopia-maintainers] Bug#652620: avahi-daemon: I have two IP addresses on eth0, and avahi chooses to use the secondary one instead of the main one

Nick Tait nick_karin at hotmail.com
Mon Dec 19 10:14:55 UTC 2011


Package: avahi-daemon
Version: 0.6.27-2+squeeze1
Severity: normal

I have configured two IPv4 addresses on my eth0 network interface, so that I
can easily differentiate inbound connections coming from the Internet. Running
"ip addr" shows the following:

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP
qlen 1000
    link/ether 00:20:ed:31:16:f2 brd ff:ff:ff:ff:ff:ff
    inet 192.168.20.10/25 brd 192.168.20.127 scope global eth0
    inet 192.168.20.25/25 brd 192.168.20.127 scope global secondary eth0
    inet6 fe80::220:edff:fe31:16f2/64 scope link
       valid_lft forever preferred_lft forever
3: tun0: <POINTOPOINT,MULTICAST,NOARP,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast
state UNKNOWN qlen 100
    link/none
    inet 192.168.90.10 peer 192.168.90.9/32 scope global tun0
4: tun1: <POINTOPOINT,MULTICAST,NOARP,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast
state UNKNOWN qlen 100
    link/none
    inet 192.168.20.129/27 brd 192.168.20.159 scope global tun1

Notice eth0 has 192.168.20.10 as the main address and 192.168.20.25 as a
secondary address. I would like avahi to only use the main address, but it
seems to be always choosing the secondary address (except if I get rid of the
secondary one, then it uses the main one). I have attempted to use the "allow-
interfaces" option in the config file, but it appears that you can't specify an
IP address here.

Here is what I see in my syslog when I start the avahi-daemon service:

Dec 19 22:50:32 freddo avahi-daemon[15559]: Found user 'avahi' (UID 104) and
group 'avahi' (GID 107).
Dec 19 22:50:32 freddo avahi-daemon[15559]: Successfully dropped root
privileges.
Dec 19 22:50:32 freddo avahi-daemon[15559]: avahi-daemon 0.6.27 starting up.
Dec 19 22:50:32 freddo avahi-daemon[15559]: Successfully called chroot().
Dec 19 22:50:32 freddo avahi-daemon[15559]: Successfully dropped remaining
capabilities.
Dec 19 22:50:32 freddo avahi-daemon[15559]: No service file found in
/etc/avahi/services.
Dec 19 22:50:32 freddo avahi-daemon[15559]: Joining mDNS multicast group on
interface eth0.IPv6 with address fe80::220:edff:fe31:16f2.
Dec 19 22:50:32 freddo avahi-daemon[15559]: New relevant interface eth0.IPv6
for mDNS.
Dec 19 22:50:32 freddo avahi-daemon[15559]: Joining mDNS multicast group on
interface eth0.IPv4 with address 192.168.20.25.
Dec 19 22:50:32 freddo avahi-daemon[15559]: New relevant interface eth0.IPv4
for mDNS.
Dec 19 22:50:32 freddo avahi-daemon[15559]: Network interface enumeration
completed.
Dec 19 22:50:32 freddo avahi-daemon[15559]: Registering new address record for
fe80::220:edff:fe31:16f2 on eth0.*.
Dec 19 22:50:32 freddo avahi-daemon[15559]: Registering new address record for
192.168.20.25 on eth0.IPv4.
Dec 19 22:50:32 freddo avahi-daemon[15559]: Registering new address record for
192.168.20.10 on eth0.IPv4.
Dec 19 22:50:32 freddo avahi-daemon[15559]: Registering HINFO record with
values 'I686'/'LINUX'.
Dec 19 22:50:32 freddo kernel: [951518.445181] [UFW BLOCK] IN= OUT=eth0
SRC=192.168.20.25 DST=224.0.0.251 LEN=298 TOS=0x00 PREC=0x00 TTL=255 ID=0 DF
PROTO=UDP SPT=5353 DPT=5353 LEN=278
Dec 19 22:50:33 freddo kernel: [951518.695137] [UFW BLOCK] IN= OUT=eth0
SRC=192.168.20.25 DST=224.0.0.251 LEN=298 TOS=0x00 PREC=0x00 TTL=255 ID=0 DF
PROTO=UDP SPT=5353 DPT=5353 LEN=278
Dec 19 22:50:33 freddo kernel: [951518.946176] [UFW BLOCK] IN= OUT=eth0
SRC=192.168.20.25 DST=224.0.0.251 LEN=298 TOS=0x00 PREC=0x00 TTL=255 ID=0 DF
PROTO=UDP SPT=5353 DPT=5353 LEN=278
Dec 19 22:50:33 freddo avahi-daemon[15559]: Server startup complete. Host name
is freddo.local. Local service cookie is 3500664120.
Dec 19 22:50:34 freddo kernel: [951519.552272] [UFW BLOCK] IN= OUT=eth0
SRC=192.168.20.25 DST=224.0.0.251 LEN=136 TOS=0x00 PREC=0x00 TTL=255 ID=0 DF
PROTO=UDP SPT=5353 DPT=5353 LEN=116

Notice the line saying "Joining mDNS multicast group on interface eth0.IPv4
with address 192.168.20.25" - and there is no line for 192.168.20.10. (NB. The
UFW BLOCK stuff is my workaround to prevent this interface being used.)

Thanks for your time. (I apologise in advance if I am doing something really
stupid. Please let me know if the 'solution' to my problem should be to disable
the avahi-daemon service, as I don't think I actually need it for anything - I
just wasn't sure of the implications.)

Nick.



-- System Information:
Debian Release: 6.0.3
  APT prefers stable-updates
  APT policy: (500, 'stable-updates'), (500, 'stable')
Architecture: i386 (i686)

Kernel: Linux 2.6.32-5-686 (SMP w/1 CPU core)
Locale: LANG=en_NZ.utf8, LC_CTYPE=en_NZ.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages avahi-daemon depends on:
ii  adduser          3.112+nmu2              add and remove users and groups
ii  bind9-host [host 1:9.7.3.dfsg-1~squeeze4 Version of 'host' bundled with BIN
ii  dbus             1.2.24-4+squeeze1       simple interprocess messaging syst
ii  host             1:9.7.3.dfsg-1~squeeze4 Transitional package
ii  libavahi-common3 0.6.27-2+squeeze1       Avahi common library
ii  libavahi-core7   0.6.27-2+squeeze1       Avahi's embeddable mDNS/DNS-SD lib
ii  libc6            2.11.2-10               Embedded GNU C Library: Shared lib
ii  libcap2          1:2.19-3                support for getting/setting POSIX.
ii  libdaemon0       0.14-2                  lightweight C library for daemons 
ii  libdbus-1-3      1.2.24-4+squeeze1       simple interprocess messaging syst
ii  libexpat1        2.0.1-7                 XML parsing C library - runtime li
ii  lsb-base         3.2-23.2squeeze1        Linux Standard Base 3.2 init scrip

Versions of packages avahi-daemon recommends:
ii  libnss-mdns                   0.10-3.1   NSS module for Multicast DNS name 

Versions of packages avahi-daemon suggests:
pn  avahi-autoipd                 <none>     (no description available)

-- no debconf information





More information about the Pkg-utopia-maintainers mailing list