[Pkg-mpd-maintainers] Bug#738831: mpd: Mpd does not start: mpdsocket: Failed to bind to '[::]:6600': Address already in use
Niccolo Rigacci
niccolo at rigacci.org
Thu Feb 13 10:16:37 UTC 2014
Package: mpd
Version: 0.18.7-1
Severity: normal
Tags: ipv6
Dear Maintainer,
Mpd does not start properly when bind_to_address option is "any" and
you have support for both ipv4 and ipv6.
This bug seems related to #563125, but it is not a problem of the resolver,
because if you specify the following in /etc/mpd.conf:
bind_to_address "0.0.0.0"
bind_to_address "::"
the daemon fails to start with the error:
mpdsocket: Failed to bind to '[::]:6600': Address already in use
Instead if you start the daemon with either one of the lines, the daemon starts
binding as expected on ipv4 only
tcp 0 0 0.0.0.0:6600 0.0.0.0:* LISTEN
or on ipv6 only:
tcp6 0 0 :::6600 :::* LISTEN
So it is impossible to listen on both ipv4 and ipv6 addresses.
Here it is an strace excerpt of the fail:
socket(PF_INET, SOCK_STREAM|SOCK_CLOEXEC|SOCK_NONBLOCK, IPPROTO_IP) = 7
setsockopt(7, SOL_SOCKET, SO_REUSEADDR, [1], 4) = 0
bind(7, {sa_family=AF_INET, sin_port=htons(6600), sin_addr=inet_addr("0.0.0.0")}, 16) = 0
listen(7, 5) = 0
setsockopt(7, SOL_SOCKET, SO_PASSCRED, [1], 4) = 0
socket(PF_INET6, SOCK_STREAM|SOCK_CLOEXEC|SOCK_NONBLOCK, IPPROTO_IP) = 8
setsockopt(8, SOL_SOCKET, SO_REUSEADDR, [1], 4) = 0
bind(8, {sa_family=AF_INET6, sin6_port=htons(6600), inet_pton(AF_INET6, "::", &sin6_addr), sin6_flowinfo=0, sin6_scope_id=0}, 28) = -1 EADDRINUSE (Address already in use)
-- System Information:
Debian Release: jessie/sid
APT prefers testing
APT policy: (500, 'testing')
Architecture: armel (armv5tel)
Kernel: Linux 3.12-1-kirkwood
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages mpd depends on:
ii adduser 3.113+nmu3
ii init-system-helpers 1.14
ii libadplug-2.2.1-0 2.2.1+dfsg3-0.1
ii libao4 1.1.0-2
ii libasound2 1.0.27.2-3
ii libaudiofile1 0.3.6-2
ii libavahi-client3 0.6.31-4
ii libavahi-common3 0.6.31-4
ii libavcodec54 6:9.10-2
ii libavformat54 6:9.10-2
ii libavutil52 6:9.10-2
ii libbz2-1.0 1.0.6-5
ii libc6 2.17-97
ii libcdio-cdda1 0.83-4.1
ii libcdio-paranoia1 0.83-4.1
ii libcdio13 0.83-4.1
ii libcurl3-gnutls 7.35.0-1
ii libfaad2 2.7-8
ii libflac8 1.3.0-2
ii libfluidsynth1 1.1.6-2
ii libgcc1 1:4.8.2-14
ii libglib2.0-0 2.36.4-1
ii libgme0 0.5.5-2
ii libid3tag0 0.15.1b-10
ii libiso9660-8 0.83-4.1
ii libjack-jackd2-0 [libjack-0.116] 1.9.9.5+20130622git7de15e7a-1
ii libmad0 0.15.1b-8
ii libmikmod2 3.1.16-1
ii libmms0 0.6.2-3
ii libmodplug1 1:0.8.8.4-4
ii libmp3lame0 3.99.5+repack1-3
ii libmpcdec6 2:0.1~r459-4
ii libmpdclient2 2.9-1
ii libmpg123-0 1.16.0-1
ii libogg0 1.3.1-1
ii libopenal1 1:1.14-4
ii libopus0 1.1-1
ii libpulse0 4.0-6+b1
ii libresid-builder0c2a 2.1.1-14
ii libroar2 1.0~beta11-1
ii libsamplerate0 0.1.8-7
ii libshout3 2.3.1-3
ii libsidplay2 2.1.1-14
ii libsidutils0 2.1.1-14
ii libsndfile1 1.0.25-9
ii libsqlite3-0 3.8.2-1
ii libstdc++6 4.8.2-14
ii libsystemd-daemon0 204-6
ii libvorbis0a 1.3.2-1.3
ii libvorbisenc2 1.3.2-1.3
ii libvorbisidec1 1.0.2+svn18153-0.2
ii libwavpack1 4.70.0-1
ii libwildmidi1 0.2.3.4-2.1
ii libwrap0 7.6.q-25
ii libyajl2 2.0.4-4
ii libzzip-0-13 0.13.62-2
ii lsb-base 4.1+Debian12
mpd recommends no packages.
Versions of packages mpd suggests:
pn avahi-daemon <none>
pn icecast2 <none>
ii mpc [mpd-client] 0.25-1
pn pulseaudio <none>
-- Configuration Files:
/etc/mpd.conf changed:
music_directory "/home/share/media/musica"
playlist_directory "/var/lib/mpd/playlists"
db_file "/var/lib/mpd/tag_cache"
log_file "/var/log/mpd/mpd.log"
pid_file "/run/mpd/pid"
state_file "/var/lib/mpd/state"
sticker_file "/var/lib/mpd/sticker.sql"
user "mpd"
bind_to_address "0.0.0.0"
input {
plugin "curl"
}
audio_output {
type "alsa"
name "My ALSA Device"
}
filesystem_charset "UTF-8"
id3v1_encoding "UTF-8"
-- no debconf information
More information about the Pkg-mpd-maintainers
mailing list