Subject: bug#63082: mpd defaul configuration does not work ('No database' error)

From: Maxim Cournoyer <[email-masked]>
Date: Tue, 25 Apr 2023 23:11:04 -0400

Hello,

Maxim Cournoyer <[email-masked]> writes:

> Hello,
>
> Our MPD service does not work out of the box.  Running under its default
> 'mpd' user, clients would get the following error attempting to update
> its database, e.g. by running 'mpc update':
>
> MPD error: database
>
>
> This particular problem was solved by adding the following field to my
> mpd-configuration record (thanks to Bruno):
>
>                 (database (mpd-plugin
>                            (plugin "simple")
>                            (extra-options
>                             '((path . "/var/lib/mpd/database")
>                               (cache-directory . "/var/cache/mpd")))))
>
>
> and running
>
> mkdir /var/cache/mpd && chown mpd:users /var/cache/mpd

The cache-directory configuration doesn't seem to be useful so far;
nothing was being populated under /var/cache/mpd.

in /var/log/messages, pulseaudio throws a couple errors:

--8<---------------cut here---------------start------------->8---
Apr 25 23:06:52 localhost pulseaudio[10356]: [pulseaudio] module-jackdbus-detect.c: Unable to contact D-Bus session bus: org.freedesktop.DBus.Error.NotSupported: Unable to autolaunch a dbus-daemon without a $DISPLAY for X11
Apr 25 23:06:52 localhost pulseaudio[10356]: [pulseaudio] module.c: Failed to load module "module-jackdbus-detect" (argument: "channels=2"): initialization failed.
Apr 25 23:06:52 localhost pulseaudio[10356]: [pulseaudio] cli-command.c: stat('/gnu/store/5ahapvp7rnd2ymakyjv1pwwdav7w9wdc-pulseaudio-16.1/etc/pulse/default.pa.d'): No such file or directory
Apr 25 23:06:52 localhost pulseaudio[10356]: [pulseaudio] main.c: No card found by this name or index.
Apr 25 23:06:52 localhost pulseaudio[10356]: [pulseaudio] main.c: Source alsa_input.pci-0000_01_01.0.analog-mono does not exist.
Apr 25 23:06:52 localhost pulseaudio[10356]: [pulseaudio] main.c: Sink alsa_output.pci-0000_01_01.0.analog-surround-40 does not exist.
Apr 25 23:06:52 localhost pulseaudio[10356]: [pulseaudio] server-lookup.c: Unable to contact D-Bus: org.freedesktop.DBus.Error.NotSupported: Unable to autolaunch a dbus-daemon without a $DISPLAY for X11
Apr 25 23:06:52 localhost pulseaudio[10356]: [pulseaudio] main.c: Unable to contact D-Bus: org.freedesktop.DBus.Error.NotSupported: Unable to autolaunch a dbus-daemon without a $DISPLAY for X11
--8<---------------cut here---------------end--------------->8---

-- 
Thanks,
Maxim