我的问题是这个。我一直在配置mpd和ncmpcpp。这是我的mpd配置:
music_directory "/media/dylan-roman/Acer/Users/Dylan/Music"
playlist_directory "/media/dylan-roman/Acer/Users/Dylan/Music"
db_file "/home/dylan-roman/.mpd/mpd.db"
log_file "/home/dylan-roman/.mpd/mpd.log"
pid_file "/home/dylan-roman/.mpd/mpd.pid"
state_file "/home/dylan-roman/.mpd/mpdstate"
user "mpd"
bind_to_address "localhost"
port "6600"
#audio_output {
#type "alsa"
#name "alsa for audio soundcard"
#mixer_type "software"
#}
audio_output {
type "pulse"
name "pulse audio"
}
audio_output {
type "fifo"
name "my_fifo"
path "/tmp/mpd.fifo"
format "44100:16:2"
}
这是我的 ncmpcpp 配置:
[mpd]
mpd_music_dir = "/media/dylan-roman/Acer/Users/Dylan/Music"
mpd_host = "localhost"
#mpd_port = "6600"
mpd_crossfade_time = "2"
ncmpcpp_directory = /home/dylan-roman/.ncmpcpp
[visualizer]
visualizer_fifo_path = "/tmp/mpd.fifo"
visualizer_in_stereo = "no"
visualizer_type = "wave"
visualizer_output_name = "my_fifo"
visualizer_look = "│┃"
visualizer_color = "default"
[header]
header_visibility = "no"
header_window_color = "default"
volume_color = "default"
state_line_color = "black"
[playlist]
playlist_display_mode = "classic"
song_list_format = "{{%a - %t}|{%f}}{$R%l}"
now_playing_prefix = "$b$2"
now_playing_suffix = "$/b$9"
[statusbar]
progressbar_look = "─╼ "
progressbar_color = "black"
statusbar_visibility = "no"
statusbar_color = "default"
song_status_format = "{{%a{ - %t}}|{ - %f}{ - %b{ (%y)}}}"
[library]
song_library_format = "{{%a - %t}|{%f}}{$R%l}"
empty_tag_color = "black"
[global]
colors_enabled = "yes"
main_window_color = "default"
centered_cursor = "yes"
enable_window_title = "yes"
external_editor = "vim"
一切似乎都正常,但是当我播放歌曲时,它没有声音,出现以下消息:
MPD: no mixer
我已经用谷歌搜索了解决方案,但我没有设法修复问题
这是我在运行 systemctl --user status mpd 时得到的:
`● mpd.service - Music Player Daemon
Loaded: loaded (/usr/lib/systemd/user/mpd.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Wed 2020-06-10 08:33:13 -04; 18s ago
TriggeredBy: ● mpd.socket
Docs: man:mpd(1)
man:mpd.conf(5)
file:///usr/share/doc/mpd/html/user.html
Process: 4095 ExecStart=/usr/bin/mpd --no-daemon (code=exited, status=1/FAILURE)
Main PID: 4095 (code=exited, status=1/FAILURE)
jun 10 08:33:13 dylan systemd[1986]: Starting Music Player Daemon...
jun 10 08:33:13 dylan mpd[4095]: Jun 10 08:33 : exception: Failed to bind to '127.0.0.1:6600'
jun 10 08:33:13 dylan mpd[4095]: Jun 10 08:33 : exception: nested: Failed to bind socket: Address already in use
jun 10 08:33:13 dylan systemd[1986]: mpd.service: Main process exited, code=exited, status=1/FAILURE
jun 10 08:33:13 dylan systemd[1986]: mpd.service: Failed with result 'exit-code'.
jun 10 08:33:13 dylan systemd[1986]: Failed to start Music Player Daemon.
` 和执行 sudo systemctl status mpd 时的 this
● mpd.service - Music Player Daemon
Loaded: loaded (/lib/systemd/system/mpd.service; disabled; vendor preset: enabled)
Active: inactive (dead)
Docs: man:mpd(1)
man:mpd.conf(5)
file:///usr/share/doc/mpd/html/user.html