FIX: volumio.local / Airplay / MPD client detect not working

It turns out that avahi-daemon is not running, and shairport won’t start for me (using Volumio 1.4). Here’s why, and how to fix it.

As I found that volumio.local was not working, and there was no Airplay alternatives available, I logged into my little Raspberry Pi to check it out. I also noticed that the Android client MPDroid was unable to detect Volumio automatically.

What I found was that avahi-daemon was not running. The command ‘sudo /etc/init.d/avahi-daemon start’ gave this error message: “avahi-daemon disabled because there is a unicast .local domain”.

When I tried to start shairport with the command ‘sudo /etc/init.d/shairport start’, it complained that avahi-daemon wasn’t running.

Looking at avahi-daemon’s init-script, it is doing a test to see if there already is a .local domain. Some ISPs do (unfortunately) have such a domain, which makes the avahi-daemon bow out.

If you’re experiencing the same problems, you can check if your ISP is the culprit right from Volumio’s command line like this:

sudo host -t SOA local

If it says “local has SOA record…”, then you can fix the problem like I did below.

I haven’t ruled out that this is a bug in Volumio, because on other computers in my network this test tells me: “Host local not found: 3(NXDOMAIN)”. Either way, I have tested this solution and it works. It also works between reboots.

To get avahi-daemon running, I commented out that test in /etc/init.d/avahi-daemon (Please note that this is not the entire file, just the part that shows my alteration. You will need to actually edit the file, using an editor like nano or vi):



Provides: avahi

Required-Start: $remote_fs dbus

Required-Stop: $remote_fs dbus

Should-Start: $syslog

Should-Stop: $syslog

Default-Start: 2 3 4 5

Default-Stop: 0 1 6

Short-Description: Avahi mDNS/DNS-SD Daemon

Description: Zeroconf daemon for configuring your network



DESC=“Avahi mDNS/DNS-SD Daemon”

Gracefully exit if the package has been removed.

test -x $DAEMON || exit 0

. /lib/lsb/init-functions

Include avahi-daemon defaults if available.

test -f /etc/default/avahi-daemon && . /etc/default/avahi-daemon


Function that starts the daemon/service.

d_start() {
$DAEMON -c && return 0

if [ -e $DISABLE_TAG -a “$AVAHI_DAEMON_DETECT_LOCAL” != “0” ]; then

# Disabled because of the existance of an unicast .local domain

log_warning_msg “avahi-daemon disabled because there is a unicast .local domain”

exit 0;


$DAEMON -D[/code]

The part that I commented out is the five lines above the “$DAEMON -D”.

Now you can either reboot, or issue the following commands:

sudo /etc/init.d/avahi-daemon start sudo /etc/init.d/shairport start

If volumio.local is not working for you is because you don’t have bonjour service installed. See here:

So, download this

Reboot and http://volumio.local will be working

Then, shairport is not invoked by the init script. It is launched from worker.php, allowing it to output to your preferred output device.

Hope this was helpful, this has been changed on last version (1.4).

Hi Michelangelo, and thanks for the great work you’re doing on Volumio. The audio quality has improved drastically from v. 1.2.

The thing is, avahi-daemon is a Linux implementation of the same functions that Bonjour is providing. With some stuff added and others not implemented. A separate Bonjour service on the network is not needed when avahi-daemon is running.

Avahi-daemon, at least, is started from the init-scripts. The change to /etc/init.d/avahi-daemon makes avahi-daemon start successfully on boot. You are absolutely right, the shairport init-script is not run on boot. (I just checked with ‘chkconfig --list’)

On a different note, everytime I’m on the phone (BlackBerry Z30) the music pauses. Nice! How did you do that?

I am unable to see volumio shairport on my network since installing 1.4. Any advice?

Check if it is activated in webUi /setting