pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: mpd not coming up when booting



On Sun, Mar 13, 2011 at 11:08:53AM +0100, Thomas Klausner wrote:
> I've installed the mpd rc.d script and added "mpd=YES" to rc.conf.
> 
> During boot, I get:
> Starting mpd.
> music directory is not a directory: "/archive/music/music"
> playlist directory is not a directory: "/archive/music/music/playlists"
> Failed to load database: Failed to open database file 
> "/archive/music/music/.mpddb": Permission denied
> database: Couldn't stat parent directory of db file 
> "/archive/music/music/.mpddb": Permission denied
> /etc/rc.d/mpd exited with code 1
> 
> # ls -ald /archive 
> drwxr-xr-x  5 root  wheel  512 Jan 11 17:59 /archive
> # ls -ald /archive/music 
> lrwxrwxr-x  1 root  wheel  21 Jul 27  2009 /archive/music -> 
> /disk/3/archive/music
> # ls -ald /archive/music/
> drwxr-xr-x  13 wiz  archive  512 Feb 28 20:01 /archive/music/
> # ls -ald /archive/music/music 
> drwxr-xr-x  294 wiz  archive  7168 Mar  1 11:27 /archive/music/music
> 
> When I start the script manually after the boot, it works fine.
> I thought it might be some mounting issue, so I added "mountall" to
> REQUIRE in /etc/rc.d/mpd, but that didn't change a thing.

I've further replaced the command in rc.d/mpd with:

command="id; ls -ald /archive/; ls -ald /archive/music/; ls -ald 
/archive/music/music/; ktrace -di /usr/pkg/bin/${name}; id"

This gives me:
[running /etc/rc.d/mpd]
[: ls: unexpected operator
Starting mpd.
uid=0(root) gid=0(wheel)
drwxr-xr-x  5 root  wheel  512 Jan 11 17:59 /archive/
drwxr-xr-x  13 wiz  archive  512 Feb 28 20:01 /archive/music/
drwxr-xr-x  295 wiz  archive  7168 Mar 19 02:42 /archive/music/music/
music directory is not a directory: "/archive/music/music"
playlist directory is not a directory: "/archive/music/music/playlists"
Failed to load database: Failed to open database file 
"/archive/music/music/.mpddb": Permission denied
database: Couldn't stat parent directory of db file 
"/archive/music/music/.mpddb": Permission denied
uid=0(root) gid=0(wheel)

Weirdly, I get an entry in the /archive/music/music/mpd.log:
        Mar 23 00:28 : bonjour: Failed to register zeroconf service.
So it can actually write there.

Looking at the kdump output, I see strange stuff like:

   591      1 mpd      CALL  __stat50(0x7f7ff7b01220,0x7f7fffffdc80)
   591      1 mpd      NAMI  "/archive/music/music"
   591      1 mpd      RET   __stat50 -1 errno 13 Permission denied

Why would __stat50 do that, given the permissions from above?

Btw, I can't find the source for __stat50, where is it?
 Thomas

(all on amd64/5.99.48)


Home | Main Index | Thread Index | Old Index