[Bug 624043] Re: Avahi needs to be restarted after boot to broadcast netatalk services
Jussi Sainio
624043 at bugs.launchpad.net
Tue Dec 18 03:42:44 UTC 2012
Ubuntu 12.04, a DHCP configured local network, and the same problem.
Putting lines to rc.local was not clean enough solution for me, so I
investigated this a little bit further. I had following symptoms:
/var/log/boot.log:
* Starting mDNS/DNS-SD daemon [OK]
* Stopping mDNS/DNS-SD daemon [OK]
[...]
* Starting configure network device [OK]
/var/log/syslog:
Dec 17 14:01:03 riesling avahi: Avahi detected that your currently configured local DNS server serves a domain .local. This is inherently incompatible with Avahi and thus Avahi disabled itself. If you want to use Avahi in this network, please contact your administrator and convince him to use a different DNS domain, since .local should be used exclusively for Zeroconf technology. For more information, see http://avahi.org/wiki/AvahiAndUnicastDotLocal
Dec 17 14:01:03 riesling dhclient: bound to 192.168.3.130 -- renewal in 40304 seconds.
/var/log/upstart/avahi-daemon.log:
Process 857 died: No such process; trying to remove PID file. (/var/run/avahi-daemon//pid)
(Side note: I hate the lack of timestamps in the two log files. Does
anybody know a solution to this?)
While this can be mitigated by disabling the "detect .local" check in /etc/default/avahi-daemon ...:
AVAHI_DAEMON_DETECT_LOCAL=0
...this is a "wrong" (but working) fix, since my network DNS does not
serve .local domain as far as I know. Note that in the logs, the network
device is brought up after trying starting Avahi. This means that the
"detect .local" check is not even done on the actual LAN device, maybe
just on the loopback device or on no network devices at all. If we want
this "detect .local" feature to work (sounds like a good idea on e.g.
mobile zeroconf daemons such as laptops), Avahi daemon must be started
after bringing up the network devices.
One a little bit more kosher way to accomplish this, by patching
/etc/init/avahi-daemon.conf:
start on (filesystem
and started dbus and net-device-up IFACE!=lo)
Now, the avahi-daemon starts only after the first non-loopback network
device has been brought up and the "detect .local" check should be done
there correctly without failing every time.
(Note: I do not know how avahi-daemon works in a changing network
scenario, e.g. if it runs on a laptop and the laptop changes network
without rebooting. Somebody maybe can test this scenario out and make
the avahi-daemon restart on each net-device-up/down event, if avahi-
daemon does not handle this internally. My setup is a server on a home
network.)
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to avahi in Ubuntu.
https://bugs.launchpad.net/bugs/624043
Title:
Avahi needs to be restarted after boot to broadcast netatalk services
Status in “avahi” package in Ubuntu:
Confirmed
Bug description:
When I boot my server, it doesn't broadcast netatalk services. I have to manually restart avahi with:
restart avahi-daemon
Once I do this, the server shows up instantly in the Finder of my Mac.
The problem is pretty much exactly the same as reported by the person here:
http://ubuntuforums.org/showthread.php?t=1482573
The only difference is that the person here fixed it by installing packages from Debian Testing, which is something I'm wary of.
I added a file /etc/avahi/services/afpd.service, with the following contents:
<?xml version="1.0" standalone='no'?><!--*-nxml-*-->
<!DOCTYPE service-group SYSTEM "avahi-service.dtd">
<service-group>
<name replace-wildcards="yes">%h</name>
<service>
<type>_afpovertcp._tcp</type>
<port>548</port>
</service>
<service>
<type>_device-info._tcp</type>
<port>0</port>
<txt-record>model=Xserve</txt-record>
</service>
</service-group>
And there is no .local domain on my network that is causing problems
with avahi starting.
ProblemType: Bug
DistroRelease: Ubuntu 10.04
Package: avahi-daemon 0.6.25-1ubuntu6
ProcVersionSignature: Ubuntu 2.6.32-24.41-generic 2.6.32.15+drm33.5
Uname: Linux 2.6.32-24-generic x86_64
Architecture: amd64
Date: Wed Aug 25 09:42:25 2010
ProcEnviron:
LANG=en_US.UTF-8
SHELL=/bin/bash
SourcePackage: avahi
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/avahi/+bug/624043/+subscriptions
More information about the foundations-bugs
mailing list