You are not logged in.

#1 2009-07-26 17:03:06

t4k1t
Member
Registered: 2009-07-19
Posts: 123

mpd can't create database

Hi

I just tried to install mpd but when I get to the point where I should make mpd --create-db I get:

failed to stat music directory "/home/user/music" (config line 1): Permission denied

Here my mpd.conf:

music_directory "/home/kag/music"
playlist_directory "/var/lib/mpd/playlists"
db_file "/var/lib/mpd/db"
log_file "/var/log/mpd/mpd.log"
error_file "/var/log/mpd/mpd.error"
pid_file "/var/run/mpd/mpd.pid"
state_file "/var/lib/mpd/mpdstate"
user "mpd"

I guess I simply overlooked smth. but just can't get it working.

Thanks


Who we are is but a stepping stone to what we can become.

Offline

#2 2009-07-26 17:18:21

thayer
Fellow
From: Vancouver, BC
Registered: 2007-05-20
Posts: 1,560
Website

Re: mpd can't create database

Sounds like a user permissions issue with your music_directory.  I believe it must be world-readable if you're using this kind of setup.


thayer williams ~ cinderwick.ca

Offline

#3 2009-07-26 17:19:27

Bob_Sheep
Member
From: Scotland
Registered: 2008-10-06
Posts: 27

Re: mpd can't create database

the user "mpd" doesnt have permission to view that folder

Offline

#4 2009-07-26 18:08:35

t4k1t
Member
Registered: 2009-07-19
Posts: 123

Re: mpd can't create database

But music has permissions 755 so everyone should be able to read it.


Who we are is but a stepping stone to what we can become.

Offline

#5 2009-07-26 19:45:15

brisbin33
Member
From: boston, ma
Registered: 2008-07-24
Posts: 1,796
Website

Re: mpd can't create database

your ~ is probably 700 meaning mpd cannot traverse it to get to ~/music

i find running mpd as myself is an easier setup.  if you go that way though, redefine all the log/pid/db file locations to be inside ~/.mpd/ so you don't have premission problems the other way.

Offline

#6 2009-07-26 20:46:50

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: mpd can't create database

I'm also running mpd as user...it's just simpler...
Instead of /etc/mpd.conf just make a ~/.mpdconf and mpd will read that.


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#7 2009-07-26 20:50:49

lifeafter2am
Member
From: 127.0.0.1
Registered: 2009-06-10
Posts: 1,332

Re: mpd can't create database

Running as a user here as well, here is my .mpdconf if it helps:

port            "6600"
music_directory         "~/music"
playlist_directory      "~/.mpd/playlists"
db_file                 "~/.mpd/mpd.db"
log_file                "~/.mpd/mpd.log"
error_file              "~/.mpd/mpd.error"

mixer_type        "alsa"
mixer_device        "default"
mixer_control        "PCM"

#binarii @ irc.binarii.net
Matrix Server: https://matrix.binarii.net
-------------
Allan -> ArchBang is not supported because it is stupid.

Offline

#8 2009-07-26 20:51:18

Rasi
Member
From: Germany
Registered: 2007-08-14
Posts: 1,914
Website

Re: mpd can't create database

as mentioned before the parent directory needs proper permissions too... in your case that is /home/kag


He hoped and prayed that there wasn't an afterlife. Then he realized there was a contradiction involved here and merely hoped that there wasn't an afterlife.

Douglas Adams

Offline

#9 2009-07-27 10:48:17

t4k1t
Member
Registered: 2009-07-19
Posts: 123

Re: mpd can't create database

Ok, first of all thanks for the quick response.

I tried to run it as user and now the mpd --create-db worked but when I start sonata it doesn't show any files.


Who we are is but a stepping stone to what we can become.

Offline

#10 2009-07-27 11:08:27

nesrecar
Member
From: Germany/Munich
Registered: 2004-06-06
Posts: 79

Re: mpd can't create database

Have a look at the library tab, you must add songs into your playlist.


Public Key 0x24685E35 available from any key server you trust.

IRC: ssimon/Nesrecar

Offline

#11 2009-07-27 11:46:23

t4k1t
Member
Registered: 2009-07-19
Posts: 123

Re: mpd can't create database

Sorry I didn't write this, but I actually meant the library.


Who we are is but a stepping stone to what we can become.

Offline

#12 2009-07-27 11:54:15

.:B:.
Forum Fellow
Registered: 2006-11-26
Posts: 5,819
Website

Re: mpd can't create database

I bind my music dir to /var/lib/mpd and run MPD as its own user. Permission problem solved wink.


Got Leenucks? :: Arch: Power in simplicity :: Get Counted! Registered Linux User #392717 :: Blog thingy

Offline

Board footer

Powered by FluxBB