[solved] Having Tons of Trouble Setting up MPD

This is the second time I have tried setting up MPD, and I am having a circle of issues. If I fix one, I get another. And now I hit a wall.
I'm following the per-user configuration method from the wiki, and for now, I just set up the "required" variables in the config file (located in /home/(my_user)/.config/mpd/mpd.conf) which are the database and log files (and also pid).
Now, after getting that set up, and running
mpd
, I get this error:
socket: Failed to bind to '[::1]:6600': Address already in use
I have tried changing the network IP to 127.0.01, to 0.0.0.0, to localhost... I have tried uncommenting "user" and changing it to myself, I have tried adding the optional variables (music directory, pid, etc.) and nothing works.
If I run
mpd --kill
I get
fatal_error: unable to read the pid from file "/home/cyber/.config/mpd/pid"
And yes, I checked to make sure that the pid file is set up correctly.
Here is my mpd.conf file, again located in .../.conf/mpd/...:
# An example configuration file for MPD.
# Read the user manual for documentation: http://www.musicpd.org/doc/user/
# Files and directories #######################################################
# This setting controls the top directory which MPD will search to discover the
# available audio files and add them to the daemon's online database. This
# setting defaults to the XDG directory, otherwise the music directory will be
# be disabled and audio files will only be accepted over ipc socket (using
# file:// protocol) or streaming files over an accepted protocol.
#music_directory "~/music"
# This setting sets the MPD internal playlist directory. The purpose of this
# directory is storage for playlists created by MPD. The server will use
# playlist files not created by the server but only if they are in the MPD
# format. This setting defaults to playlist saving being disabled.
#playlist_directory "~/.mpd/playlists"
# This setting sets the location of the MPD database. This file is used to
# load the database at server start up and store the database while the
# server is not up. This setting defaults to disabled which will allow
# MPD to accept files over ipc socket (using file:// protocol) or streaming
# files over an accepted protocol.
db_file "/home/cyber/.config/mpd/database"
# These settings are the locations for the daemon log files for the daemon.
# These logs are great for troubleshooting, depending on your log_level
# settings.
# The special value "syslog" makes MPD use the local syslog daemon. This
# setting defaults to logging to syslog, otherwise logging is disabled.
log_file "/home/cyber/.config/mpd/log"
# This setting sets the location of the file which stores the process ID
# for use of mpd --kill and some init scripts. This setting is disabled by
# default and the pid file will not be stored.
pid_file "/home/cyber/.config/mpd/pid"
# This setting sets the location of the file which contains information about
# most variables to get MPD back into the same general shape it was in before
# it was brought down. This setting is disabled by default and the server
# state will be reset on server start up.
#state_file "~/.mpd/state"
# The location of the sticker database. This is a database which
# manages dynamic information attached to songs.
#sticker_file "~/.mpd/sticker.sql"
# General music daemon options ################################################
# This setting specifies the user that MPD will run as. MPD should never run as
# root and you may use this setting to make MPD change its user ID after
# initialization. This setting is disabled by default and MPD is run as the
# current user.
user "cyber"
# This setting specifies the group that MPD will run as. If not specified
# primary group of user specified with "user" setting will be used (if set).
# This is useful if MPD needs to be a member of group such as "audio" to
# have permission to use sound card.
#group "nogroup"
# This setting sets the address for the daemon to listen on. Careful attention
# should be paid if this is assigned to anything other then the default, any.
# This setting can deny access to control of the daemon.
# For network
bind_to_address "localhost"
# And for Unix Socket
#bind_to_address "~/.mpd/socket"
# This setting is the TCP port that is desired for the daemon to get assigned
# to.
#port "6600"
# This setting controls the type of information which is logged. Available
# setting arguments are "default", "secure" or "verbose". The "verbose" setting
# argument is recommended for troubleshooting, though can quickly stretch
# available resources on limited hardware storage.
#log_level "default"
# If you have a problem with your MP3s ending abruptly it is recommended that
# you set this argument to "no" to attempt to fix the problem. If this solves
# the problem, it is highly recommended to fix the MP3 files with vbrfix
# (available from <http://www.willwap.co.uk/Programs/vbrfix.php>), at which
# point gapless MP3 playback can be enabled.
#gapless_mp3_playback "yes"
# Setting "restore_paused" to "yes" puts MPD into pause mode instead
# of starting playback after startup.
#restore_paused "no"
# This setting enables MPD to create playlists in a format usable by other
# music players.
#save_absolute_paths_in_playlists "no"
# This setting defines a list of tag types that will be extracted during the
# audio file discovery process. The complete list of possible values can be
# found in the mpd.conf man page.
#metadata_to_use "artist,album,title,track,name,genre,date,composer,performer,disc"
# This setting enables automatic update of MPD's database when files in
# music_directory are changed.
#auto_update "yes"
# Limit the depth of the directories being watched, 0 means only watch
# the music directory itself. There is no limit by default.
#auto_update_depth "3"
# Symbolic link behavior ######################################################
# If this setting is set to "yes", MPD will discover audio files by following
# symbolic links outside of the configured music_directory.
#follow_outside_symlinks "yes"
# If this setting is set to "yes", MPD will discover audio files by following
# symbolic links inside of the configured music_directory.
#follow_inside_symlinks "yes"
# Zeroconf / Avahi Service Discovery ##########################################
# If this setting is set to "yes", service information will be published with
# Zeroconf / Avahi.
#zeroconf_enabled "yes"
# The argument to this setting will be the Zeroconf / Avahi unique name for
# this MPD server on the network.
#zeroconf_name "Music Player"
# Permissions #################################################################
# If this setting is set, MPD will require password authorization. The password
# can setting can be specified multiple times for different password profiles.
#password "password@read,add,control,admin"
# This setting specifies the permissions a user has who has not yet logged in.
#default_permissions "read,add,control,admin"
# Database #######################################################################
#database {
# plugin "proxy"
# host "other.mpd.host"
# port "6600"
# Input #######################################################################
input {
plugin "curl"
# proxy "proxy.isp.com:8080"
# proxy_user "user"
# proxy_password "password"
# Audio Output ################################################################
# MPD supports various audio output types, as well as playing through multiple
# audio outputs at the same time, through multiple audio_output settings
# blocks. Setting this block is optional, though the server will only attempt
# autodetection for one sound card.
# An example of an ALSA output:
audio_output {
type "alsa"
name "My Sound Card"
## device "hw:0,0" # optional
mixer_type "software" # optional
## mixer_device "default" # optional
## mixer_control "PCM" # optional
## mixer_index "0" # optional
# An example of an OSS output:
#audio_output {
# type "oss"
# name "My OSS Device"
## device "/dev/dsp" # optional
## mixer_type "hardware" # optional
## mixer_device "/dev/mixer" # optional
## mixer_control "PCM" # optional
# An example of a shout output (for streaming to Icecast):
#audio_output {
# type "shout"
# encoding "ogg" # optional
# name "My Shout Stream"
# host "localhost"
# port "8000"
# mount "/mpd.ogg"
# password "hackme"
# quality "5.0"
# bitrate "128"
# format "44100:16:1"
## protocol "icecast2" # optional
## user "source" # optional
## description "My Stream Description" # optional
## url "http://example.com" # optional
## genre "jazz" # optional
## public "no" # optional
## timeout "2" # optional
## mixer_type "software" # optional
# An example of a recorder output:
#audio_output {
# type "recorder"
# name "My recorder"
# encoder "vorbis" # optional, vorbis or lame
# path "/var/lib/mpd/recorder/mpd.ogg"
## quality "5.0" # do not define if bitrate is defined
# bitrate "128" # do not define if quality is defined
# format "44100:16:1"
# An example of a httpd output (built-in HTTP streaming server):
#audio_output {
# type "httpd"
# name "My HTTP Stream"
# encoder "vorbis" # optional, vorbis or lame
# port "8000"
# bind_to_address "0.0.0.0" # optional, IPv4 or IPv6
## quality "5.0" # do not define if bitrate is defined
# bitrate "128" # do not define if quality is defined
# format "44100:16:1"
# max_clients "0" # optional 0=no limit
# An example of a pulseaudio output (streaming to a remote pulseaudio server)
#audio_output {
# type "pulse"
# name "My Pulse Output"
## server "remote_server" # optional
## sink "remote_server_sink" # optional
# An example of a winmm output (Windows multimedia API).
#audio_output {
# type "winmm"
# name "My WinMM output"
## device "Digital Audio (S/PDIF) (High Definition Audio Device)" # optional
# or
## device "0" # optional
## mixer_type "hardware" # optional
# An example of an openal output.
#audio_output {
# type "openal"
# name "My OpenAL output"
## device "Digital Audio (S/PDIF) (High Definition Audio Device)" # optional
## Example "pipe" output:
#audio_output {
# type "pipe"
# name "my pipe"
# command "aplay -f cd 2>/dev/null"
## Or if you're want to use AudioCompress
# command "AudioCompress -m | aplay -f cd 2>/dev/null"
## Or to send raw PCM stream through PCM:
# command "nc example.org 8765"
# format "44100:16:2"
## An example of a null output (for no audio output):
#audio_output {
# type "null"
# name "My Null Output"
# mixer_type "none" # optional
# If MPD has been compiled with libsamplerate support, this setting specifies
# the sample rate converter to use. Possible values can be found in the
# mpd.conf man page or the libsamplerate documentation. By default, this is
# setting is disabled.
#samplerate_converter "Fastest Sinc Interpolator"
# Normalization automatic volume adjustments ##################################
# This setting specifies the type of ReplayGain to use. This setting can have
# the argument "off", "album", "track" or "auto". "auto" is a special mode that
# chooses between "track" and "album" depending on the current state of
# random playback. If random playback is enabled then "track" mode is used.
# See <http://www.replaygain.org> for more details about ReplayGain.
# This setting is off by default.
#replaygain "album"
# This setting sets the pre-amp used for files that have ReplayGain tags. By
# default this setting is disabled.
#replaygain_preamp "0"
# This setting sets the pre-amp used for files that do NOT have ReplayGain tags.
# By default this setting is disabled.
#replaygain_missing_preamp "0"
# This setting enables or disables ReplayGain limiting.
# MPD calculates actual amplification based on the ReplayGain tags
# and replaygain_preamp / replaygain_missing_preamp setting.
# If replaygain_limit is enabled MPD will never amplify audio signal
# above its original level. If replaygain_limit is disabled such amplification
# might occur. By default this setting is enabled.
#replaygain_limit "yes"
# This setting enables on-the-fly normalization volume adjustment. This will
# result in the volume of all playing audio to be adjusted so the output has
# equal "loudness". This setting is disabled by default.
#volume_normalization "no"
# Character Encoding ##########################################################
# If file or directory names do not display correctly for your locale then you
# may need to modify this setting.
#filesystem_charset "UTF-8"
# This setting controls the encoding that ID3v1 tags should be converted from.
#id3v1_encoding "ISO-8859-1"
# SIDPlay decoder #############################################################
# songlength_database:
# Location of your songlengths file, as distributed with the HVSC.
# The sidplay plugin checks this for matching MD5 fingerprints.
# See http://www.c64.org/HVSC/DOCUMENTS/Songlengths.faq
# default_songlength:
# This is the default playing time in seconds for songs not in the
# songlength database, or in case you're not using a database.
# A value of 0 means play indefinitely.
# filter:
# Turns the SID filter emulation on or off.
#decoder {
# plugin "sidplay"
# songlength_database "/media/C64Music/DOCUMENTS/Songlengths.txt"
# default_songlength "120"
# filter "true"
I have no idea what to do.
I am searching the Internet like mad to try and find a solution, because I really, really want to use MPD and not go back to MOC, but I figured a post would speed up the process.
Last edited by mindcrime (2014-11-17 02:29:24)

nixpunk wrote:
I'm not an MPD expert, but did you verify that the error isn't indeed valid?  You can check what is going on at port 6600 with (run as root):
# lsof -i :6600
I had to install lsof, but there was no output at all. Nothing.
I assume that's good?
Edit:
However............. After installing lsof and running the command you gave me, I ran mpd just for kicks and... it worked. (Of course, it spit out an "error" since I have no music directory defined yet) but it worked. Let me add some music and start up ncmpcpp and see if it works!
Edit2: AND, it's suddenly working!
All I did: install lsof, run your command, try running mpd for fun, installed ncmpcpp, and it works perfectly.
Thanks.
*solved!* That was silly.
Last edited by mindcrime (2014-11-17 02:29:02)

Similar Messages

  • Setting up MPD for every user on the machine

    I'm having a few problems setting up MPD. What I want to do is configure MPD such that it starts automatically at login using the current user config file (so that it uses the correct db) and stops playing and exit (to free port 6600) on logout. This way when a different user logs in MPD will use the correct database and playlists dir.
    So far I've created all the needed files (.mpd/{.conf,.pid,etc}) in the home dirs of every user and followed this (MPD/Autostart with systemd/Current Setup) then I followed these steps for user1 (created the needed files in user1's home) Using systemd to manage your session (Should I repeat them for user2?). I'm using this service for mpd:
    [Unit]
    Description=Music Player Daemon
    [Service]
    ExecStart=/usr/bin/mpd %h/.config/mpd/mpd.conf --no-daemon
    ExecStop= /usr/bin/mpd %h/.config/mpd/mpd.conf --kill  #I expected this to stop mpd on logout
    [Install]
    WantedBy=default.target
    The problem is that when I log out the music keeps playing which means mpd is still running. If I log in as user2 I can see users1 database (using ncmpc) but I can't control the playback e.g:If I want to skip the current track it stops playing.
    Any ideas?

    rodrigomb81 wrote:ExecStop= /usr/bin/mpd %h/.config/mpd/mpd.conf --kill  #I expected this to stop mpd on logout
    That will stop mpd when the service is stopped, which will happen when the user instance of systemd exits. So logout should do `systemctl --user exit`. (This might be mentioned on the wiki, but that systemd/user page is a big mess.)

  • Is anyone else having trouble setting up messages with the new mountain lion software? I keep getting a notification that i cant sign in and it is saying, check network connection and try again, but i have full wifi bars, thanks, Justin

    is anyone else having trouble setting up messages with the new mountain lion software? I keep getting a notification that i cant sign in and it is saying, check network connection and try again, but i have full wifi bars, thanks, Justin

    Install this to get X11 functionality back in 10.8
    http://xquartz.macosforge.org/landing/
    Worked great for me and others.
    Jerry

  • Having trouble setting up my website. It's probably a silly mistake.

    So I've registered a domain and hosting plan with A Simple Orange which had a pretty good deal since I had a coupon for 20% off. I've tried using Joomla to manage my website, but I couldn't get the hang of it. So I'm trying out iWeb 09' now and just having trouble setting it up. I've gone to me.com and added my website and added the CNAME correctly I hope. Here is a picture. http://imgur.com/XI8Lw.png
    Next I opened iWeb and setup MobileMe in the preferences panel. I've tried publishing the information from iWeb to my website, but my home page doesn't change. You can see here at RyanSchefer.com that it's just plan

    No. Your CNAME setting is not correct. The CNAME and web.me.com are correct with web.me.com being your host. However, your domain name is incorrect - don't understand why you have put mobileme before it? You just enter either your domain name on its own so domain.com or you need to set up two separate CNAME entries, one being for www, CNAME, web.me.com and then one being @, CNAME, web.me.com. The @ stands for your domain name and the www is your sub domain.
    Try altering this and it should work okay.

  • Having trouble setting up email accounts in the mail app?

    Hi Apple community,
         I am having trouble setting up my email accounts with the osX mail application. I have two accounts, an outlook and my college email through google. When I try to add the outlook account the prompt says that it cannot connect to the server and when I try my college mail i get the following prompt.
    "Trying to log in to the Exchange server “autodiscover-s.outlook.com” failed. Make sure the email address and password you entered are correct, then click Continue."
    Please note that my college account is run by gmail and ends in murraystate.edu
    Thanks, Will.

    Hey will,
    okay for your college email. Heres what you do.
    Try adding your email and wait for the message to come up
    Trying to log in to the Exchange server “autodiscover-s.outlook.com” failed. Make sure the email address and password you entered are correct, then click Continue."
    Once it does, you will notice 2 extra boxes One says username and the other password. You will notice that the username will not have @murraystate.edu
    Add this and continue and this should now be added as an email account and should be able to receive emails as normal.
    For your outlook emails, I would recommend using the following article to set it up. It is fairly straightforward.
    http://howto.cnet.com/8301-11310_39-57602775-285/how-to-set-up-mac-mail-to-use-i map-for-outlook.com/
    Hope that helps.

  • Having trouble setting up FaceTime.   keep giving me Apple ID password

    having trouble setting up FaceTime.  trouble at verifying use I'd.  I have my email setup with different password since I have tw setup email.   my Apple ID has different password.   same email name.

    Hello sangjaimepark,
    Thank you for the details of the issue you are experiencing with activating FaceTime.  I recommend reviewing the article below for FaceTime activation issues.  When trying to activate FaceTime, you will need to use the email address you use for your Apple ID and your Apple ID password and not your email password:
    iOS: Troubleshooting FaceTime and iMessage activation
    http://support.apple.com/kb/ts4268
    Thank you for using Apple Support Communities.
    Best,
    Sheila M.

  • Having trouble setting up network

    Hi guys,
    I just recently moved to a new house and am having trouble setting up the network with my airport extreme. There is a cable modem that is networked to the house so that every room has an outlet.
    I connected the airport to one of the outlets with my macbook and when I create network, I cannot connect to the internet wirelessly even though the macbook detects a network when I set it up with bridge mode. But hard wired through the router I can surf the web as I am doing right now.
    When I hit share an IP address, the internet does not work at all. It seems to work fine with my old netgear router, but would prefer using the airport.
    I've also reset the airport as well with still no luck. Any help would be appreciated. Thanks

    Have you tried powering down the modem for 5 min and then turning on with the ethernet connected to the WAN port of airport extreme?

  • Having trouble setting up e-mail on new iPhone 4s. I would like to sync with my outlook mail, contacts

    I am having trouble setting up my email and syncing my outlook calendar wiht my new iphone 4s.

    How do you connect to the internet?
    Most of the time, the problem lies here. You can try a couple of things. First, try only 3G or carrier data. Then, try only wifi. If that still doesn't work, your only other option is to try a different hotspot.
    I had the same problem before when I updated to iOS 4.3. I thought it was the update at first. I usually have the carrier data turned off because my plan doesn't have an unlimited provision for it. I forgot that I also switched ISPs from DSL to a visibility unit package - meaning I had to setup my laptop so that I could get wifi from it. I realized this when I visited a friends house that I knew I could connect properly before.
    My problem was with my laptop. It seems that Little Snitch blocks the ports being used for mail and push notifications. I haven't figured it out exactly since I still can't get email when I'm using my laptop connection. But, it works fine when I'm using ONLY 3G or both/wifi only if connected to a different hotspot.
    Hope that helps.

  • Having trouble setting up a linksys WRT54GS router with v...

    Having trouble setting up a linksys WRT54GS router with verizon DSL using a westell 6100F modem. the modem works fine by its self  but the router will not connect  to the internet when installed like the cd tells you to.
    online help and phone help has been less than helpful,  anyone have any Ideas?

    Ok I found " Installing the liksys wireless router with a westell 6100 modem" in the verizon troubleshooting guides. printed the instructions so I would'nt forget. step 1 open your web browser and enter http://192.168.1.1 in the address field.  PROBLEM it comes up with a login screen that I don't know how to sign into. tried the obvious stuff. cannot get past the login screen. I knew this sounded to easy to be true. anyone have any ideas? 

  • MSI X58 Pro - I'm having trouble setting up my first Raid 0 Array

    Hey guys!  I have an i7 920, X58 Pro, 3x2GB DDR3, Radeon 5850, 640GB WD Black (Windows 7 64 bit + applications) and 1TB Samsung F3 (backup) system and I'm having trouble setting up a raid 0 array.  I recently decided to purchase two additional 1TB Samsung F3 harddrives in order to create a raid 0 array, while still keeping my original two harddrives separate.  I installed the new harddrives today, installed the JMicron drivers that were on the drivers disk that came with my motherboard, went into the bios, and changed it from IDE to RAID.  I then went into the raid bios, selected the two new harddrives and selected raid 0, saved everything and tried to load Windows and Windows refuses to boot up.  I got an option to try fixing Windows but that didn't end up fixing anything.  Finally, I was forced to go back into the bios and switch it from RAID back to IDE just to get Windows to boot up again.  Does anyone know what I need to do in order to get this raid 0 to work?  Thanks a lot in advance for your help!

    Perhaps create a software RAID? You can do it in Windows through Control Panel --> Administrative Tools --> Computer Management --> Disk Management.
    A quick guide: http://www.softwaresecretweapons.com/jspwiki/windows-7-software-raid-disk-partition-and-volume-context-menus

  • I just got a new ipad 2 but I having trouble setting it up, can someone help me. thank yoy

    I just got a new ipad 2 but I'm having trouble setting it up, can someone help me?

    Please read Chapter 2.
    There have been some problems accessing pages on the Apple web site.  If the hyperlink gives you a "We're sorry" message, try again.

  • I'm having trouble setting up my new 5s. it won't connect to phone service and my old phone is still getting all my messages

    i'm having trouble setting up my new 5s. it won't connect to phone service and my old phone is still getting all my messages

    According to http://en.wikipedia.org/wiki/IPhone_5
    the iPhone5 has 1GB of RAM, and internal storage of 16, 32, or 64GB.
    It does not use SD cards.
    Fake iphones are really Android phones using the skin of iOS6.
    Click on the App Store icon. If it takes you to Apple's App Store, then it's a real iPhone.
    But if you are directed to Google Play, then I'm afraid you've gotten a copy.

  • HT201250 I am having trouble setting up my time capsule.  the amber light is flashing.  i have a Verizon FIOS network that i use for the internet (WiFi) and do not want to configure the Time Capsule to do that function.  I just want the Time Capsule to ba

    I am having trouble setting up my time capsule.  the amber light is flashing.  i have a Verizon FIOS network that i use for the internet (WiFi) and do not want to configure the Time Capsule to do that function.  I just want the Time Capsule to back up.

    Simple.. bridge the TC.. in the apple utility in the NAT and DHCP area.
    Plug it into the FIOS router.. you can turn off wireless in the TC if you want.. or use it.. it can work faster if you are nearby and can select 5ghz.. but up to you.

  • I am having trouble setting up my Yahoo! e-mail account on my phone...it asks for my Password and I type it in correctly and, carefully, but I get an error window, "MF Message Error Domain error 1032" -what does thi smean and how can I get around it?

    I am having trouble setting up my Yahoo! e-mail account on my phone...it asks for my Password and I type it in carefully and correctly, but I get an error window, "MF Message Error Domain error 1032" -what does this mean and how can I get around it? My password is long and convoluted, but it works when I type it in on my main Mac workstation, just fine.....what gives?

    try restarting the phone and try again

  • I am having trouble setting up an email account on my new ipad

    I am having trouble setting up a new email account on my ipad
    that I got today can anyone help me?

    Have a look here  >  http://www.apple.com/support/ipad/mail/

Maybe you are looking for