MPD's volume level does not persist despite being saved in the statefile

Each time I start mpd the volume has reset to 100%, which is far too loud for me. From what I understand defining a statefile in mpd’s config is supposed to keep this from happening, however, it continues to do so even with a statefile which contains sw_volume: 30.

I have tried setting the volume with mpc and ncmpcpp, neither persist.
I have tried starting mpd as a service, and via the terminal.
I have removed the configuration I store in home for both mpd and ncmpcpp, doing so made no difference.
Last but not least I have also tried both PulseAudio and PipeWire as outputs.

I have rw access to, and own the statefile, and since it restores the queue and mode it seems to read the file, but not the volume state.


sw_volume: 30
audio_device_state:1:pulse audio
state: pause
current: 0
time: 38.232000
random: 0
repeat: 0
single: 0
consume: 0
crossfade: 0
mixrampdb: 0.000000
mixrampdelay: -1.000000

Current mpd config

bind_to_address     ""
port                "6600"
auto_update         "yes"
restore_paused      "yes"

music_directory     "/mnt/D1/MEDIA/MUSIC/MPD/MUSIC/"
playlist_directory  "~/.mpd/playlists"
db_file             "~/.mpd/mpd.db"
log_file            "~/.mpd/mpd.log"
pid_file            "~/.mpd/"
state_file          "~/.mpd/mpdstate"

audio_output {
        type            "pulse"
        name            "pulse audio"

audio_output {
    type            "fifo"
    name            "Visualizer"
    path            "/tmp/mpd.fifo"
    format          "44100:16:2"

It may be a bug.
This sounds like it.

I suggest you discuss it upstream and add more info or create a new bug report.

I don’t believe the this is it, as volume is persistent across songs and only resets when the server is killed.

I did not say that.


A couple of months later I have found a solution to this infuriating problem. Should someone else come across the same issue, replacing Pipewire-media-session with Wireplumber resolves this issue if you also have a Pulse output in your mpd.conf instead of Pipewire. For some reason Pipewire as an mpd output is still troublesome.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.