There is simpler and safer way to do this.
1st
We move all mpd' files to ~/.mpd. Create this directory if, it's not there.
2nd
Now edit properly
Find and edit this part.
Code:
# An example configuration file for MPD
# See the mpd.conf man page for a more detailed description of each parameter.
######################## REQUIRED PATHS ########################
# You can put symlinks in here, if you like. Make sure that
# the user that mpd runs as (see the 'user' config parameter)
# can read the files in this directory.
music_directory "/[your_mp3_dir]"
playlist_directory "/home/[user]/.mpd/playlists"
db_file "/home/[user]/.mpd/tag_cache"
log_file "/home/[user]/.mpd/mpd.log"
error_file "/home/[user]/.mpd/errors.log"
################################################################
3rd
Find and modify this
Code:
######################## DAEMON OPTIONS ########################
#
# If started as root, MPD will drop root privileges and run as
# this user instead. Otherwise, MPD will run as the user it was
# started by. If left unspecified, MPD will not drop root
# privileges at all (not recommended).
#
user "[user]"
Since we run mpd as "ourself", go find and edit this.
Code:
######################## OPTIONAL PATHS ########################
#
# If you wish to use mpd --kill to stop MPD, then you must
# specify a file here in which to store MPD's process ID.
#
pid_file "/home/[user]/.mpd/pid"
#
# If specified, MPD will save its current state (playlist,
# current song, playing/paused, etc.) at exit. This will be
# used to restore the session the next time it is run.
#
state_file "/var/lib/mpd/state"
#
################################################################
Run
For finish touches just restart mpd and create collection.
Ofcourse you can do same with state file. Since I'm not using it, I didn't.
Cheers.
Bookmarks