You are not logged in.

#1 2009-03-27 21:33:08

Exershio
Member
Registered: 2008-04-14
Posts: 17

[SOLVED] MPD won't work on system startup

I have just installed and configured mpd today, and it works fine if I start it up manually using "/etc/rc.d/mpd start", however, it fails to start up automatically when I put it in the daemons list in my rc.conf. I have full rights to the ~/.mpd/ directory (since it's in my home folder) and the Music directory. My music database built fine, and everything works fine if I start it up manually. I don't get why it fails to start on system boot.

Here's my daemons list:

DAEMONS=(@syslog-ng @network !netfs @crond @alsa @hal @fam @mpd)

Here's my /etc/mpd.conf:

music_directory         "/home/joey/Music"
playlist_directory      "/home/joey/.mpd/playlists"
db_file                 "/home/joey/.mpd/db"
log_file                "/home/joey/.mpd/log"
error_file              "/home/joey/.mpd/error"
pid_file                "/home/joey/.mpd/pid"
state_file              "/home/joey/.mpd/mpdstate"
user                    "joey"
bind_to_address         "localhost"
port                    "6600"

audio_output {
        type            "alsa"
        name            "My ALSA Device"
}

Last edited by Exershio (2009-03-27 23:26:20)

Offline

#2 2009-03-27 23:03:09

Exershio
Member
Registered: 2008-04-14
Posts: 17

Re: [SOLVED] MPD won't work on system startup

Hmm. I believe I found the problem. I removed the @ in front of all the daemons to let them start up in order instead of in the background, and everything starts up perfect.

I wonder which daemon MPD relies on that's causing it to fail. Network maybe? Anyone have any ideas?

DAEMONS=(syslog-ng network !netfs crond alsa hal fam mpd)

Last edited by Exershio (2009-03-27 23:03:42)

Offline

#3 2009-03-27 23:05:46

Inxsible
Forum Fellow
From: Chicago
Registered: 2008-06-09
Posts: 9,183

Re: [SOLVED] MPD won't work on system startup

Well that would slow down your boot. I just tend to have a keybinding that will start up mpd. Mod4 + m -- simple enough and it starts only when I want to listen to music. That way, it doesn't take up memory unless you want it too.


Forum Rules

There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !

Offline

#4 2009-03-27 23:05:56

X/ax
Member
From: Oost vlaanderen, Belgium
Registered: 2008-01-13
Posts: 275
Website

Re: [SOLVED] MPD won't work on system startup

I would think it relies on network. Since that one daemon might cause some time to load, it's probably the reason your mpd didn't load...


My coding blog (or an attempt at it)
Archer start page (or an attempt at it)

Offline

#5 2009-03-27 23:26:00

Exershio
Member
Registered: 2008-04-14
Posts: 17

Re: [SOLVED] MPD won't work on system startup

I was right, network was indeed the culprit. I backgrounded everything except network and everything works perfectly now. big_smile 5 seconds added to my startup doesn't bother me that much. I don't reboot too often anyway.

So if anyone else is having the same problem as me, mpd needs to start up AFTER network is done loading, otherwise it fails.

Offline

Board footer

Powered by FluxBB