Help answer threads with 0 replies.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 05-10-2009, 10:35 AM   #1
LQ Newbie
Registered: May 2009
Posts: 18

Rep: Reputation: 5
MPC and can conky having problems with MPD


I installed mpd succesfully, but when I start up mpc i get the following error:

MPD_HOST and/or MPD_PORT environment variables are not set
error: problems getting a response from "localhost" on port 6600 : Connection refused

When I the following mpc will run but only for the time I leave the terminal open. (Does anyone know how to make this permanent?)
export MPD_HOST=
export MPD_PORT=6600
But then when i get mpc running, updated and added songs it won't play but just reports the volume: 61% repeat: off randomff
mpd –create-db
mpc update
mpc add /
mpc play
When I use conky to display mpd i get the error:
Conky: MPD error: problems getting a response from "localhost" on port 6600 : Connection refused

The strange thing is that when I use sonata I can play music.

I am confused and don't know what to do to get it working

This are the relevant parts of my mpd.conf

music_directory "/home/jens/Desktop/Music"
playlist_directory "/home/jens/.mpd/playlists"
db_file "/home/jens/.mpd/mpd.db"
log_file "/home/jens/.mpd/mpd.log"
error_file "/home/jens/.mpd/mpd.error"
pid_file "/home/jens/.mpd/pid"

user "jens"

#port "6600"
bind_to_address ""

And this is my /etc/hosts localhost DELL.WORKGROUP DELL

# The following lines are desirable for IPv6 capable hosts
::1 localhost ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
ff02::3 ip6-allhosts

netstat -nap
reports: tcp 0 0 ****** LISTEN

Thanks in advance!

I managed to solve myself by accident...
I only had to export the host and NOT the port. I don't know why, but it works.

Last edited by jens1245; 05-10-2009 at 11:45 AM. Reason: extra information
Old 10-26-2010, 04:52 AM   #2
Senior Member
Registered: Oct 2004
Location: Houston, TX (usa)
Distribution: MEPIS, Debian, Knoppix,
Posts: 4,727
Blog Entries: 15

Rep: Reputation: 234Reputation: 234Reputation: 234
Thanks for posting the solution, & points for finding it. That's the LQ spirit.

A suggestion for the future: If you answer your own question, put the solution in a separate post; this does 2 good things:
  • It generates e-mail to anyone who subscribed to either the thread or the forum.
  • In avoids the creation of oxymoronic 0-reply solved threads.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
mpd/mpc MPD_host and/or mpc_port not set jens1245 Linux - Newbie 2 05-14-2009 11:54 PM
Conky install problems C-Sniper Slackware 3 10-26-2007 02:21 PM
alsa problems with arts and mpd quarry_06 Linux - Software 1 05-28-2006 02:25 PM
Conky on Suse 10.0 - *** buffer overflow detected *** conky terminated Slidex Linux - Software 1 03-17-2006 12:50 PM
mpc to mp3? chup Linux - General 2 03-16-2004 09:18 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:13 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration