how to fix the decoders plugin error

Need help with MPD?
Post Reply
grayguest
Posts: 3
Joined: February 26th, 2021, 5:50 am

how to fix the decoders plugin error

Post by grayguest »

  • Describe the problem
Some songs cannot be played, for example some songs on https://github.com/grayguest/music
  • Expected Behavior
All songs can be playded, for example all four songs on https://github.com/grayguest/music
  • Actual Behavior
some songs cannot be played, skipped. for example Aloha Heja He.mp3 on https://github.com/grayguest/music
perhaps it's decoder problema, for example mad/mpeg123/ffmpeg plugins, but i don't know how to fix the decoders or add some other decoders?
i have upgraded ffmpeg plugin version to newest.
  • Version
mpd version

Code: Select all

$ mpd --version
Music Player Daemon 0.22.6 (0.22.6)
Copyright 2003-2007 Warren Dukes <warren.dukes@gmail.com>
Copyright 2008-2018 Max Kellermann <max.kellermann@gmail.com>
This is free software; see the source for copying conditions.  There is NO
warranty; not even MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Database plugins:
 simple proxy

Storage plugins:
 local udisks nfs curl

Neighbor plugins:
 udisks

Decoders plugins:
 [mad] mp3 mp2
 [mpg123] mp3
 [vorbis] ogg oga
 [oggflac] ogg oga
 [flac] flac
 [opus] opus ogg oga
 [sndfile] wav aiff aif au snd paf iff svx sf voc w64 pvf xi htk caf sd2
 [audiofile] wav au aiff aif
 [dsdiff] dff
 [dsf] dsf
 [hybrid_dsd] m4a
 [faad] aac
 [mpcdec] mpc
 [wavpack] wv
 [modplug] 669 amf ams dbm dfm dsm far it med mdl mod mtm mt2 okt s3m stm ult umx xm
 [mikmod] amf dsm far gdm imf it med mod mtm s3m stm stx ult uni xm
 [sidplay] sid mus str prg P00
 [wildmidi] mid
 [fluidsynth] mid
 [adplug] amd d00 hsc laa rad raw sa2
 [ffmpeg] 16sv 3g2 3gp 4xm 8svx aa3 aac ac3 adx afc aif aifc aiff al alaw amr anim apc ape asf atrac au aud avi avm2 avs bap bfi c93 cak cin cmv cpk daud dct divx dts dv dvd dxa eac3 film flac flc fli fll flx flv g726 gsm gxf iss m1v m2v m2t m2ts m4a m4b m4v mad mj2 mjpeg mjpg mka mkv mlp mm mmf mov mp+ mp1 mp2 mp3 mp4 mpc mpeg mpg mpga mpp mpu mve mvi mxf nc nsv nut nuv oga ogm ogv ogx oma ogg omg opus psp pva qcp qt r3d ra ram rl2 rm rmvb roq rpl rvc shn smk snd sol son spx str swf tak tgi tgq tgv thp ts tsp tta xa xvid uv uv2 vb vid vob voc vp6 vmd wav webm wma wmv wsaud wsvga wv wve rtp:// rtsp:// rtsps://
 [gme] ay gbs gym hes kss nsf nsfe sap spc vgm vgz
 [pcm]

Filters:
 libsamplerate soxr

Tag plugins:
 id3tag

Output plugins:
 shout null fifo sndio pipe alsa ao openal pulse jack httpd recorder

Encoder plugins:
 null vorbis opus lame twolame wave flac shine

Archive plugins:
 [bz2] bz2
 [zzip] zip
 [iso] iso

Input plugins:
 file archive alsa tidal qobuz curl ffmpeg nfs mms cdio_paranoia

Playlist plugins:
 extm3u m3u pls xspf asx rss soundcloud flac cue embcue

Protocols:
 file:// alsa:// cdda:// ftp:// ftps:// gopher:// hls+http:// hls+https:// http:// https:// mms:// mmsh:// mmst:// mmsu:// nfs:// qobuz:// rtmp:// rtmps:// rtmpt:// rtmpts:// rtp:// rtsp:// rtsps:// sftp:// smb:// srtp:// tidal://

Other features:
 avahi dbus udisks epoll icu inotify ipv6 systemd tcp un

mpc version

Code: Select all

$ mpc version
mpd version: 0.22.4

ffmpeg version
I has upgraded ffmpeg to newest.

Code: Select all

$ ffmpeg
ffmpeg version 4.3.2-0york0~18.04 Copyright (c) 2000-2021 the FFmpeg developers
  built with gcc 7 (Ubuntu 7.5.0-3ubuntu1~18.04)
  configuration: --prefix=/usr --extra-version='0york0~18.04' --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --arch=amd64 --enable-gpl --disable-stripping --enable-avresample --disable-filter=resample --enable-gnutls --enable-ladspa --enable-libaom --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libcodec2 --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libjack --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librabbitmq --enable-librsvg --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libsrt --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzmq --enable-libzvbi --enable-lv2 --enable-omx --enable-openal --enable-opencl --enable-opengl --enable-sdl2 --enable-libzimg --enable-pocketsphinx --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libx264 --enable-shared
  libavutil      56. 51.100 / 56. 51.100
  libavcodec     58. 91.100 / 58. 91.100
  libavformat    58. 45.100 / 58. 45.100
  libavdevice    58. 10.100 / 58. 10.100
  libavfilter     7. 85.100 /  7. 85.100
  libavresample   4.  0.  0 /  4.  0.  0
  libswscale      5.  7.100 /  5.  7.100
  libswresample   3.  7.100 /  3.  7.100
  libpostproc    55.  7.100 / 55.  7.100
Hyper fast Audio and Video encoder
usage: ffmpeg [options] [[infile options] -i infile]... {[outfile options] outfile}...

Use -h to get full help or, even better, run 'man ffmpeg'

  • Log
<!-- Paste relevant portions of the log file here (--verbose) -->

Code: Select all

$ tail -f /var/log/mpd/mpd.log
Feb 25 11:19 : avahi: Service 'Music Player @ mint64-VirtualBox' successfully established.
Feb 25 11:20 : player: played "Aloha Heja He.mp3"
Feb 25 11:20 : mad: input does not appear to be a mp3 bit stream
[src/libmpg123/parse.c:1185] error: Giving up searching valid MPEG header after 65536 bytes of junk.
Feb 25 11:20 : mpg123: mpg123_getformat() failed: Message: I am done with this track.
Feb 25 11:20 : ffmpeg/opus: Could not update timestamps for skipped samples.

Code: Select all

$ sudo mpd --stderr --no-daemon --verbose /etc/mpd.conf
config_file: loading file /etc/mpd.conf
path: SetFSCharset: fs charset is:
libsamplerate: libsamplerate converter 'Fastest Sinc Interpolator'
vorbis: Xiph.Org libVorbis 1.3.5
opus: libopus 1.1.2
sndfile: libsndfile-1.0.28
hybrid_dsd: The Hybrid DSD decoder is disabled because it was not explicitly enabled
adplug: adplug 2.2.1
simple_db: reading DB
exception: Input plugin 'tidal' is not configured: No Tidal application token configured
exception: Input plugin 'qobuz' is not configured: No Qobuz app_id configured
curl: version 7.58.0
curl: with GnuTLS/3.5.18
avahi: Initializing interface
exception: RTIOThread could not get realtime scheduling, continuing anyway: sched_setscheduler failed: Operation not permitted
avahi: Client changed to state 2
avahi: Client is RUNNING
avahi: Registering service _mpd._tcp/Music Player @ mint64-VirtualBox
avahi: Service group changed to state 0
avahi: Service group is UNCOMMITED
state_file: Loading state file /var/lib/mpd/state
decoder_thread: probing plugin mad
playlist: queue song 2:"The Next Episode.mp3"
exception: OutputThread could not get realtime scheduling, continuing anyway: sched_setscheduler failed: Operation not permitted
avahi: Service group changed to state 1
avahi: Service group is REGISTERING
decoder: audio_format=12000:24:1, seekable=true
alsa_output: opened default type=PLUG
alsa_output: buffer: size=512..4096 time=42666..341334
alsa_output: period: size=255..257 time=21333..21334
alsa_output: default period_time = buffer_time/4 = 341333/4 = 85333
alsa_output: format=S24_LE (Signed 24 bit Little Endian)
alsa_output: buffer_size=4096 period_size=256
output: opened "I82801AAICH" (alsa) audio_format=12000:24:1
decoder_thread: probing plugin mad
mad: input does not appear to be a mp3 bit stream
decoder_thread: probing plugin mpg123
player: played "Counting Stars.mp3"
playlist: queue song 3:"Victory.mp3"
[src/libmpg123/parse.c:1185] error: Giving up searching valid MPEG header after 65536 bytes of junk.
mpg123: mpg123_getformat() failed: Message: I am done with this track.
decoder_thread: probing plugin ffmpeg
ffmpeg/matroska,webm: Format matroska,webm probed with size=2048 and score=100
ffmpeg: detected input format 'matroska,webm' (Matroska / WebM)
ffmpeg/matroska,webm: Before avformat_find_stream_info() pos: 599 bytes read:8192 seeks:0 nb_streams:1
ffmpeg/matroska,webm: All info found
ffmpeg/matroska,webm: stream 0: start_time: -0.007 duration: NOPTS
ffmpeg/matroska,webm: format: start_time: -0.007 duration: 199.861 (estimate from stream) bitrate=50 kb/s
ffmpeg/matroska,webm: After avformat_find_stream_info() pos: 614 bytes read:8192 seeks:0 frames:1
ffmpeg: codec 'opus'
decoder: audio_format=48000:f:2, seekable=true
ffmpeg/opus: Could not update timestamps for skipped samples.
ffmpeg/opus: skip 312/960 samples
alsa_output: opened default type=PLUG
alsa_output: buffer: size=2048..16384 time=42666..341334
alsa_output: period: size=1024..1024 time=21333..21334
alsa_output: default period_time = buffer_time/4 = 341333/4 = 85333
alsa_output: format=FLOAT_LE (Float 32 bit Little Endian)
alsa_output: buffer_size=16384 period_size=1024
output: opened "I82801AAICH" (alsa) audio_format=48000:f:2
avahi: Service group changed to state 2
avahi: Service 'Music Player @ mint64-VirtualBox' successfully established.
max
Forum team
Posts: 1254
Joined: January 15th, 2013, 3:43 pm

Re: how to fix the decoders plugin error

Post by max »

What makes you believe that MPD should be able to play those files?
grayguest
Posts: 3
Joined: February 26th, 2021, 5:50 am

Re: how to fix the decoders plugin error

Post by grayguest »

max wrote: February 26th, 2021, 7:34 am What makes you believe that MPD should be able to play those files?
Actually, I don’t know which songs MPD can play. I think MPD can play all the songs, just like the built-in player of the system can play all the songs on https://github.com/grayguest/music

If it does not support playing a certain song, is there any way to add decoding or other way?

i like MPD, so want to use it as my default music player.
max
Forum team
Posts: 1254
Joined: January 15th, 2013, 3:43 pm

Re: how to fix the decoders plugin error

Post by max »

Maybe my question wasn't phrased well. The decode libraries MPD uses say that those files are broken. I did not check, that's not my expertise. MPD doesn't decode anything, it relies on many external libraries for the job. And those libraries say the files are broken.
Do you believe those files are ok?
grayguest
Posts: 3
Joined: February 26th, 2021, 5:50 am

Re: how to fix the decoders plugin error

Post by grayguest »

solved~

decoder {
plugin "mad"
enalbed "no"
}
decoder {
plugin "mpg123"
enalbed "no"
}
Post Reply